Dots Game


Background:

"Dots" is a two player game.  The playing board has a grid of dots.  The objective is to capture as many regions as possible.  Players take turns selecting dots.  When adjacent dots are selected, a line is drawn between the two dots.  When four lines form a square enclosing a region, the region is "captured" by the player.  When a player captures a region, the player can select another dot.

Program Specifications:

  1. When a user clicks a dot, it should change color to indicate that it has been selected.
  2. When two adjacent dots are selected, a line should be drawn between them.
  3. When the four dots on the corners of a square are selected, the region enclosed by the four dots is captured and the color of the region should change to the color corresponding to the player who clicked the dot.
  4. When a person captures a region, they should be able to select another dot.
  5. The program should display whose turn it is.
  6. When all dots have been selected, the game should end.
  7. The program should indicate the winner (the person who captured the most regions).
  8. The score should be displayed.
  9. The game time should be displayed while the game is played.
  10. A means to start a new game should be provided.
  11. A means to exit (with verification) should be provided.
  12. The users should be able to select their color.
  13. The users should be able to select the grid size.
  14. The game should be user friendly and look "professional".

Extra Credit

  1.  Create a one player version that allows the player to play against the computer. Consider making several versions of the computer.  The most simple (and least intelligent) computer player would have the computer randomly select dots to click. You can make the computer more intelligent by having it check for locations that will result in regions and/or locations that will not permit the player to get regions.
  2. Have each region be worth points. You could display the value of the region on the board.