Skip to content

Java Chess

alexl4123 edited this page May 21, 2018 · 2 revisions

What is Java Chess?

Java Chess is a Chess game, implemented in the programming language Java. There shall be three game modes:

  1. Local - Directly in the executed jar
  2. LAN - In the local area Network
  3. AI - Against an Artificial Intelligence

Further technical intro:

We are not using pre defined Java-Chess movement packages. We calculate the possible moves based on the "Backgroundgrid". There has every meeple a pre defined value. E.g. The white pawn on a2 - 100. The AI works with simple brood force - it calculates the best moves, a few steps ahead. The algorithm is a better min max, which is called AlphaBeta.

How the AI-Works

As the AlphaBeta algorithm is an improvement of min-max, it uses a ,,Board-Evaluation-Function'' to judge, how a board state is good or bad for a team. After this is calculated the best possible outcome for the searching team is chosen. This is calculated until a certain depth, put simply it calculates all possible moves of team a and then all possible corresponding moves for team b, and again and again, until this has been done several times. And after this the Board-Evaluatoin-Function is applied.

The depth can be changed with the difficulty slider (Where 1 equals a search depth of 2).

The O() notation of this algorithm is a O(~24^n), where 24 is the average of the possible moves and n is the ,,search depth''.

Clone this wiki locally