{"id":15584315,"url":"https://github.com/chargrilledchook/chess","last_synced_at":"2025-10-23T15:50:09.029Z","repository":{"id":49777383,"uuid":"294039881","full_name":"ChargrilledChook/chess","owner":"ChargrilledChook","description":"Final assignment for the Ruby section of The Odin Project","archived":false,"fork":false,"pushed_at":"2020-11-08T00:32:46.000Z","size":650,"stargazers_count":5,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-30T06:41:18.881Z","etag":null,"topics":["chess","odin","ruby"],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ChargrilledChook.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-09-09T07:44:28.000Z","updated_at":"2024-01-11T03:16:54.000Z","dependencies_parsed_at":"2022-08-29T17:41:15.959Z","dependency_job_id":null,"html_url":"https://github.com/ChargrilledChook/chess","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChargrilledChook%2Fchess","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChargrilledChook%2Fchess/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChargrilledChook%2Fchess/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ChargrilledChook%2Fchess/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ChargrilledChook","download_url":"https://codeload.github.com/ChargrilledChook/chess/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250560033,"owners_count":21450170,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chess","odin","ruby"],"created_at":"2024-10-02T20:40:41.258Z","updated_at":"2025-10-23T15:50:08.946Z","avatar_url":"https://github.com/ChargrilledChook.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Chess\n\nA fully functional chess game that can be played in a terminal.\n\nFinal assignment for the Ruby section of [The Odin Project](https://www.theodinproject.com/).\n\nSpec and details for the assignment can be found [here](https://www.theodinproject.com/courses/ruby-programming/lessons/ruby-final-project).\n\nPlay online on [replit](https://repl.it/@HappyFrog/chess#README.md)\n\n## Demo\n\n\u003cimg src='chess_demo.gif' alt='fools mate'\u003e\n\n\n## Features\n\n* Various modes - play vs a friend, vs the computer or watch the computer battle itself\n* Save and load your game\n* Sophisticated artificial intelligence*\n* Gorgeous unicode graphics\n* Beautiful blue and gray chessboard\n\n\\* \u003cem\u003eMay not actually be sophisticated or intelligent\u003c/em\u003e\n\n## How to use\n\nTo play online, go [here](https://repl.it/@HappyFrog/chess#README.md).\n\nTo play locally, you must have Ruby installed. See [here](https://www.ruby-lang.org/en/downloads/) for more details. This program was written in Ruby 2.7 but is backwards compatible to at least Ruby 2.5.\n\nIf you have Ruby installed, clone this repository, navigate to the top level folder and type ruby main.rb in your terminal, then follow the in game instructions.\n\nTo run the tests you must have rspec installed. More info on rspec can be found [here](http://rspec.info/). These tests were written using rspec 3.9. Execute the tests by simply typing rspec in your console in the top level folder.\n\n## Style Guide\n\nWritten with the community [ruby style guide](https://rubystyle.guide/). See the .rubocop.yml file for specific tweaks.\n\n## Possible future additions\n\nA more complete list can be found at the project board [here](https://github.com/users/ChargrilledChook/projects/2).\n\n### UI / UX\n* Improve UX feedback - why a move failed (invalid move, you are in check etc)\n* Improve saving system (more files, custom naming)\n* Improve clarity of board / pieces\n\n### Internal\n* Various refactorings - particularly en passant, castling, and reducing size of ref and round classes\n* Increase test coverage\n* More unit tests\n* Integration testing?\n\n### Additional Features\n* A Puzzle mode - mate in 3 etc\n* Smarter AI\n\n## Known Bugs\n\n* It is possible to put yourself in check while doing an en pasasnt move, leading to an illegal board state. This will raise an exception.\n\n## Reflections\n\nThe hardest and most complex project I've worked on to date. Difficult both for the depth and breadth of problems to solve, and then integrating those various solutions together in a clean and modular way. Managing the bloat and cruft from various little experiments, or implementations that needed to change after realising they would need to change because of an edge case was a challenge. While I put quite a lot of thought into planning my overall design, which was a useful exercise, there were a lot of things that only became obvious after encountering / working through them.\n\nI definitely see the value of keeping systems as modular as possible, as the parts that were entangled became very difficult to make even small changes on as the project grew in size. Likewise testing discipline is important for being able to make changes and refactor safely.\n\nOn the whole a great project and a lot of lessons learned.\n\n## Contact\n\nChargrilledChook#7159 on discord :chicken:\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchargrilledchook%2Fchess","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fchargrilledchook%2Fchess","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fchargrilledchook%2Fchess/lists"}