Giter VIP home page Giter VIP logo

bobby's Introduction

Bobby

Build Quality Gate Status Coverage


💥 Try it on Lichess! 💥


This basic Chess game is a humble tribute to famous Chess player Robert James "Bobby" Fischer, World Chess Champion.

Note that the author does not agree with Fischer's political and religious opinions, but remains a fan of his genius at Chess.

Bobby Chess Game

Note: requires Java 17

About Bobby

If you are interested in how this engine works, please have a look at those two articles by the author:

  1. Implementing a Chess engine from scratch
  2. Enhancing a Java Swing App to a clean, elegant Web App without changing the code

How to launch

From a released JAR

  1. If not already done, you can install OpenJDK 17 for free (see the excellent distributions of Temurin by Adoptium)
  2. Download the latest release JAR
  3. Then launch the downloaded JAR
    java -jar bobby-0.1.jar 
    

From source code

  1. Checkout the code
  2. Build it with maven
     mvn package -Dmaven.test.skip=true
    
  3. Launch the created JAR
    java -jar target/bobby-1.0-SNAPSHOT.jar 
    

Online

🆕 Lichess Bot

Thanks to the great lib Chariot, it is now possible to play against Bobby on Lichess.

Just browse to bobby-bot profile on Lichess.org and challenge it! If the server is running, the bot will accept the challenge and play.

GUI in browser (deprecated)

There was a browser version of the game (limited to one single user at a time), but it was stopped for costs reasons.

Features

Game

  • AI with multiple strength level, from random-stupid to 3-depths computation, using a minimax algorithm
  • All moves implemented
  • Change GUI view according to selected color
  • Draw proposals
  • Undo last move
  • Suggest move
  • Usage of 15+ famous openings
  • Limit computation time to n seconds
  • Save game to and load from text files with basic notation
  • Load PGN file
  • AI is as arrogant as the real Bobby was 😄

Technical

  • Uses Java 17
  • Ability to use bundled light JRE (doc here)
  • Strong code coverage, incl. GUI testing
  • Code style with Checkstyle, code quality with SpotBugs and SonarSource
  • Pipeline with GitHub Actions
  • Uses a nice modern Look & Feel FlatLaf for all platforms
  • Uses free font FreeSerif in order to have a nice rendering of chess pieces

Limitations

Computation time

The implemented AI works uses a depth-first computation, which means that if the computation time is restricted, it may not evaluate every single possible move: it evaluates as deep as possible a first move, then a second, etc, but has no guarantee to cover every move of the first depth.

bobby's People

Contributors

teemoo7 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.