This is a chess engine implemented in python.
Note: This is being rewritten in Java now
What you can do now:
- Import any game using a FEN string
- Move any piece
- Capture any piece
- Check the king
What you cannot do now:
- Checkmate the king
- Castle
- En passant capture
First, clone this repository and then run:
python main.py
If you want to overwrite default starting position, you can import a custom board by passing a fen string as an argument as follows:
python main.py "starting_fen"
By default game starts in GUI, if you want to debug and run in CLI use the -c flag like below:
python main.py -c
Just drag and drop a piece to move it.
Input is taken as follows, with space in between
<starting_square> <ending square>
A square is denoted by the following:
<rank><file> // algebraic notation
where ranks (horizontal rows) are from 1 to 8 (bottom to top), and files (vertical columns) from A to H (left to right).
For example if you want to move your pawn from e2 to e4 then:
e2 e4
The inputs are case insensitive.