This is a fully functioning MVC Chess GUI written in Java. It leverages the Processing library for the graphical user interface, ControlP5 for buttons, and JUnit for testing.
The chess logic is implemented using bitboards with a little endian rank file mapping board representation. All chess rules are implemented including castling king and queenside, en passant, pawn promotions and draw by 75 move rule.
All the techniques used to implement this chess game are documented in the chess programming wiki.
The code is structured as a monorepo with the following projects and dependencies.
- jdk 21
- node
- pnpm
git clone https://github.com/clemenscodes/chess.git
cd chess
pnpm install
pnpm start
Using an IDE like IntelliJ will also build and start the project without additional configuration.
To test the model using the jshell, simply run the jshell script:
pnpm jshell
or manually:
jshell --class-path dist/api:dist/model --startup e2e/model.jshell
pnpm run docs