You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

30 lines
1.2 KiB

11 months ago
Chess program
=============
This simple application allows the user to play chess. Moves can be made by human or computer.
GUI
===
11 months ago
The GUI shows a 2D chess board and whichever pieces are in play (it starts with a new game, ready to play).
Last move and currently selected square are highlighted in different colors.
List of all moves made so far in the game are listed on the side.
11 months ago
Text feedback is given for the game state (who's turn it is, and if it is checkmate or stalemate).
The user makes a move by clicking the source and destination square (for castling and en passant move the king or pawn to its natural destination square).
Any click (if it is one of your pieces) highlights that square
If some square highlighted, then:
if second click is legal move, do it and unhighlight
otherwise unhighlight with no move
else unhighlight without moving
An "AI move" button makes the computer move (choose a random move from those available).
An "Undo" button takes back the most recent move.
A "Reset" button puts the board in its correct configuration for the first turn of the game.
Game rules
==========
Standard chess rules apply. The 3-move-repetition, 50-move rule, and underpromotion are not implemented in this version.