Sunday, January 9, 2011

Source code

The source code for the game can be found at
http://sourceforge.net/projects/scotland-yard/


The source code for the zoom used for this program can be found at
http://blogs.sonyericsson.com/developerworld/2010/05/18/android-one-finger-zoom-tutorial-part-1/

The game

Instructions:

About the game

This game is the Android version of the Scotland Yard board game.

In Scotland Yard, the player controls the detectives trying to capture the elusive "Mr. X" before he can escape from London. The detectives move around on the board, which is a map of London, but Mr. X moves in secret; recording his moves on a pad.

All of the players can only move from one location to another if they have a ticket of the proper type. There are three types of ticket; bus, taxi and underground. The players have a limited supply of tickets and the detectives must work together in order to trap Mr. X.

The detectives try to close in on Mr. X's location. Every third move Mr. X must reveal his location which allows the detectives to slowly narrow their search. If a detective ever lands on the location occupied by Mr. X, you win the game. If Mr. X manages to elude the detectives until they run out of tickets then the Mr. X is the winner.



Playing the game

(T: Taxi, B: Bus, UG: Underground)

The game can be played in one of three modes:

- 3 detectives - T:7, B: 4, UG: 2 tickets - 13 moves
- 4 detectives - T:8, B: 6, UG: 3 tickets - 17 moves
- 5 detectives - T:10, B: 8, UG: 4 tickets - 23 moves

T:  White line
B:  Green line
UG: Red dotted line

The difficulty for each mode can also be selected which determines the level of the AI.

When you start the game in one of the modes, you will initially see a map on the screen with the initial positions of the detectives. Mr. X first makes the move and his mode of transport is shown on the screen. The user then moves the detectives by clicking on one of the detectives and then clicking on the node it would like to move to. If more than one mode of transport is available, then an option will be shown as to which mode should be used.

A detective's ticket supply is limited. To check each detectives ticket supply, click on one of the detectives.

Once all the detectives have moved, click the 'Move' button on the screen to indicate Mr. X to make the move. Clicking 'Reset' will deselect the detective and allow you to make a move again.

ALL THE BEST. PLAY TO WIN.