Skip to content

fredericojordan/fast-chess

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

fast-chess

Build Status CircleCI

fast-chess

Simple chess game intended to be faster than my (now abandoned) python version, hence the name.

Many thanks to Chess Programming Wiki and TSCP for some ideas and tuning values.

Features

  • Board Representation:
    • Bitboards
  • Search:
    • Iterative Deepening
    • Alpha-Beta Pruning
    • Parallel Processing
    • Quiescence Search
    • Static Exchange Evaluation
  • Evaluation:
    • Material Balance
    • Piece-Square Tables
    • Pawn Structure
  • Graphical User Interface:
    • Attack Heatmap
    • Edit Board Mode

Quickstart

  1. Download latest release
  2. Extract file contents
  3. Run chess.exe (Windows) or ./chess (macOS/Linux)
  4. ???
  5. Profit

GUI Hotkeys

Hotkey Usage
β–² / β–Ό Increase/decrease AI search depth
A Toggle [A]I opponent
I [I]nvert player's colors
H Toggle attack [H]eatmap
C Change board [c]olor scheme
R [R]andom board color
T Random [t]inted board color
E [E]dit mode (drag to move or click to cycle pieces)
P Export to [P]GN
D [D]ump game info to file
M List legal [M]oves (console mode only)
V Static board e[v]aluation (console mode only)
Q [Q]uit
U [U]ndo move

Screenshots

Chess Heatmap

Building the project

macOS/Linux

In order to successfully build the project we need a C++ compiler, CMake and also the SDL graphics libraries: SDL2, SDL2_image and SDL2_ttf.

In Debian/Ubuntu, this can be achieved by running the command:

apt-get install -y g++ cmake libsdl2-dev libsdl2-image-dev libsdl2-ttf-dev

In macOS, we can run:

brew install cmake sdl2 sdl2_image sdl2_ttf

Then we just download the code, build the project and run the program:

git clone https://github.com/fredericojordan/fast-chess.git
cd fast-chess
cmake .
make
./chess