This is a simple 2 player Ludo Game! This was the third task assigned in the SF summer web-training workshop!
In accordance with the problem statement, here are the rules for the game:
This is a simplified version of Ludo.
In this game:
● There are 2 tokens for each player (as shown in locker)
● Initially all 2 are in locker.
● Players roll a die turn-wise, starting from Player A!
● A token can be freed from the locker only when die rolls 6.
● Tokens are freed at START point of the player.
● The START point of the player is the dark coloured squre! The end point is the light coloured one!
● If all tokens are in locker and the die does not roll 6, turn
passes to other player.
● If the player who has rolled has a token in play, he can
choose a token and move it ahead (clockwise) a number
of squares equal to the number indicated on the die.
● If a 6 is rolled, the player can release a token from the
locker (instead of moving a token).
● Unlike the real game, here chance passes to another player even if he/she gets a 6!
● If a player’s token moves to cell already occupied by
opponent, the player’s token replaces those of the
opponent, while the opponent’s token(s) return to its(their)
locker.
● When a token reaches / crosses the end point, it leaves
the game board!
● The player whose all 2 tokens leave the board first, wins!