noumxn / chess-python

Creating a chess engine with python

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

General

Chess is a board game played between two players. It is an abstract strategy game and involves no hidden information. It is played on a square chessboard with 64 squares arranged in an eight-by-eight grid. At the start, each player (one controlling the white pieces, the other controlling the black pieces) controls sixteen pieces: one king, one queen, two rooks, two bishops, two knights, and eight pawns. The object of the game is to checkmate the opponent's king, whereby the king is under immediate attack (in "check") and there is no way for it to escape. There are also several ways a game can end in a draw. The rules of how to play the game and how different pieces work can be found here: https://www.youtube.com/watch?v=NAIQyoPcjNM

Technologies

  • python 3.10.5
  • pygame 2.0.1

Installation

  • Clone the repository.
  • Run ChessMain.py.
  • Enjoy the game.

Sic

  • Press z to undo move.

  • Press r to restart game.

  • Set player_one and/or player_two in ChessMain.py to True to have a human play, and False to allow computer to play.

About

Creating a chess engine with python


Languages

Language:Python 100.0%