Command line application for playing chess implemented in ruby.
In order to run this project, you need to have ruby installed. I recommend using rbenv.
This branch of the project has been tested only on ruby version 2.7.1.
You will also need to install bundler with
gem install bundler
You can run this project in your browser here.
There are some performance improvements that can be made, so I recommend running this locally if you can.
Clone this repository and change your current working directory with
git clone git@github.com:rankoliang/chess.git && cd chess
Next, install the dependencies by running
bundle
Play the game by typing this into your command line. This will only work on systems with bash installed.
./chess
Alternatively, you can run
rake
Run the test suite with
bundle exec rspec
- Castling
- En Passants
- Promoting pawns to queens
- Undoing moves
- Enforcing (mostly) legal moves
- Saving and loading the game state (default directory:
saves/
)
There is no AI, but the moves are shuffled in a semi random order. You can keep on pressing enter to execute random moves.
This project is licensed under the MIT License.