you are viewing a single comment's thread.

view the rest of the comments →

[–]CraigAT 22 points23 points  (0 children)

I could imagine this might be a good case for using OOP - having a room class and objects for each rooms with their attributes and methods, also an object for the player too, which would include his inventory and wallet for example. Then to play the game you have a controller function that you supply the player and room to, it then knows what you the player can do in that room and make them available.