Tuesday 13 November 2018

Lab4

Topics:
Multi-way and nested selections


Learning Outcome:
At the end of this lab, student should be able:
1. Use multi-way and nested selection statement to specify alternative paths of program’s execution

So for the 4th lab,we need to design an adventure game,where it game tells story through passage of text revealed to a player in response to typed instructions. The game starts with the player inside a “room” with textual description. The player can move from one room to another by typing in commands.
As for the command we can determine on our own.we also need to add some character that the player needs to interact with during game.Our task is to make at least 10 rooms for the player to explore during the game.


For this lab, we need to use nested selections,where there is selections in selection,that is why it is called nested.The 10 room that we need to have,is based on the nested selection we build in the coding.
This is the example of  my games ;



It shows you the introduction to the adventure game and also  selections for room1 and room2.

No comments:

Post a Comment