Rules of the Game
This is a Java implementation of the traditional Chinese game for two to six
Each player has ten pegs of one color at one starting point of the star.
The objective of the game is to occupy the star point directly opposite.
The first player to accomplish this is a winner. Of course if in the same
round more than one players reach the end point all of them are winners.
Each player moves in turn, (in this implementation clockwise).
A move consists of placing a peg into one of the adjacent holes or jumping
over any other one peg into a hole beyond. The direction of the move has to be
one of the following: left/right, forward left/right, backward left/right in
respect with the player's position on the board. Only one move is made at a
time, except when jumping. Then the player can make any number of jumps in any
direction as long as all the moves consist of jumps. Players may jump their
own or their opponents' pegs. No pegs are removed from the board during play.
The whole game is split into two main panels, the "Game Setup" panel
and the "Game Board" panel.
Using the "Game Setup" window you can choose the number of players
you want in the game, their positions and their colors.
- Using the red button you can choose the number of players.
- Using the green button you can change the order of the players on the board.
- Using the blue button you can choose the color of the players.
All the changes you make affect the order, the color and the number of the
dragons on the middle of the panel. By clicking the dragons you can choose
between computer or human player.
Finally (for this panel) you can press the "Play" button to start
When you choose the "Play" button the "Game Board" panel
appears and the game
starts immediately. On the top left of the screen you see the color of the
player who is currently making a move. On the bottom left you see the
"Stop" button which stops the game and brings you back to the
"Game Setup" panel.
Most of this panel is occupied by the game board itself. This is where
you see your pegs and you make your moves.
When it is your turn to play you can choose your move by following these steps:
- Choose the peg that you want to move by clicking on it.
- Choose the first move by clicking on a free position, for near moves
only one selection will be allowed, for far moves (jumps) you can choose as
many as you can (according to the rules).
- When you have "drawn" your path you double-click on the last
position of your move and the computer moves the peg.
If you want to cancel a move just click on the selected peg and the computer
will erase the move path.