Skip to content

Latest commit

 

History

History
50 lines (32 loc) · 2.23 KB

README.md

File metadata and controls

50 lines (32 loc) · 2.23 KB

README

This is a 2-player implementation of chess playable in a browser. It is a rework of a pure Ruby implementation of chess I did in partial fulfillment of The Odin Project. The driving motivation is to build a fully independent chess API consumable by a variety if client types. If you're interested in building a client to interact with this API, just fork submit a PR.

Game Modes

  • Play as a guest in hotseat mode with another guest account on the same computer (under construction)
  • Authenticated account allowing you to save and load games (coming soon)
  • Multiplayer over sockets with other authenticated users (coming soon)

Rationale

Game Logic:

  • The chess logic is self-contained in a module and housed in app/lib
  • It is called through a limited number of class methods for top-level tasks as listed below
  • It has no interactions with the database (which are handled by Rails models)

API interactions:

For a given game instance, the API provides a JSON dump that includes data for the game, white, and black players. It should also contains an array of available moves (expressed "a3") for each piece.

Endpoints:

Technical Description

Rails:

React/Redux:

Rails Chess Lib Methods (all accessed via call to Chess::Game):

  • .position_pieces: consumes

References: