Chess game with AI ( implemented with minimax, with alpha-beta pruning ). This article helped me in creating the AI.
https://www.freecodecamp.org/news/simple-chess-ai-step-by-step-1d55a9266977/
For understanding minimax and alpha beta pruning this video was helpful for me.
Minimax & Alpha-beta pruning
The user could play either online by connecting to the server or with the AI.
To play the game, pygame is needed so install it, if you don't have it.
$ pip install pygame
Then simply run game.py.
$ python3 game.py
For Online mode you will have to change some code in "client.py"
- You have to host "server.py" on some server.
- Change self.host in client.py to the public IP of your server.
- Open two instances of the game, from anywhere and play.
- Stalemate
- Castling
- Pawn Promotion
- En Passant