Maddox Smith Staff asked 4 years ago

CFS2160 Software Design & Development


The problem is to define classes suitable for playing an extended version of Snakes and Ladders. You will need to define classes to represent the playing of the game. You should try to design your game and the classes that you will need before starting coding. Your game must have a graphical user interface to display the state of the game at all times. The most obvious collection to use to represent a grid is an array. This may not be the best choice. Be careful in selecting collection types. The players should use the game alternately to take their turn. Traditionally this is done by rolling a die but you could invent new ways of doing this. To obtain a bare pass your game should:  Allow two players to play the game  Allow a player to win  Allow each player to take their turn  Keep track of where each player is on the grid  Enable the movement of players up ladders and down snakes. To gain a higher mark you will need to implement some extensions to your game. Some suggestions might be:  Allow more than two players to play the game  Inclusion of other rewards and pitfalls besides snakes and ladders  Hidden/secret playing strategies  Varying the position of rewards and pitfalls so that you get a different game every time