Java - Checkers

 

This is a project of Artificial Intelligence class at George Mason University, Fall 1997.

You play Checkers with the computer in this game. Checkers is a very popular board game. Since it is relatively easier (i.e. its branching factor is relatively less) than 'chess' or 'go', it is a good example to show the power of AI. Currently, the official world champion of Checkers is a computer program, called 'Chinook'.

The rules are easy:
1. You can only move one step forward along the diagonal row of the gird with same color;
2. You can make a jump to eat opponent pieces;
3. When your piece reach your opponent bottom line, that piece becomes a King. You may move or jump either forward or backward, but still along the diagonal row;
4. You must eat if you can eat, and eat them all;
5. If you remove all opponent pieces or block him so that he cannot move, you win.

The key issue in this kind of problem is the pruning tree algorithm and the evaluation funtion. I follow the alpha-beta pruning method from the textbook, "Artificial Intelligence - A Modern Approach" (Stuart Russell, Peter Norvig), Ch5. As to the evaluation funtion, I simply use material value for each piece, a normal piece is worth 1, while a king is worth 2, and just ignore other features such as the positions of pieces, or their "structure".

The applet support drap-and-drop the pieces. Another thing is when you move your mouse over the pieces, the piece which can be moved is highlighted.

powered by Gentoo powered by Apache Made with CSS powered by MySQL powered by PHP powered by smarty