A simple chess game made in C++ made for the programming exam at my university.
final result: 10/10
The project implements:
- A chess game with rules and special moves implemented, featuring 2 game modes -Computer vs Computer -Player vs Computer
- A replay mode, where logs of past matches saved in .txt file can:
- placed inside a different .txt file with all chessboard changes
- step by step replay of the match in the terminal
List of pieces (standard Italian pieces):
- A: Bishop
- D: Queen
- R: King
- T: Rook
- C: Knight
- P: Pawn
Note: CMake is required!
After cloning the project, open the folder and write:
$ cmake .
Now it is necessary to create the dependencies:
$ make
First you need to select the desired game mode
If you choose cc:
- insert the maximum rounds played by the bots
If you choose pc:
- insert the username
The layout of the chessboard is labeled according to the classic rules:
Note: white pieces are lower case, black pieces are upper case
To specify a move insert the start position and end position. The coordinates are in the format {letter}{number}, case insensitive. Allowed moves:
- Insert a move (e.g d2 d4)
- FF : ask to draw
There are 2 mode of view a replay
- Put replay in a .txt with all chessboard changes
- Step by step replay of the match