Current Features:
Play:
Navigable map of rooms
Room inventories
Examine objects and locations
If first time in room: long description
If seen before: short description
north and n both move (+south ect...)
Player Inventory
Pick up and drop objects
Object Inventories (like a box of things)
System:
Restart Game
Help Info
Exit Game
Set Verbose (always long room description)
Set Brief (Unset Verbose)
clear screen
"g" repeats last action
Future Features (1st Priority):
Play:
inventory limits
inventory "all" command
Use Fireplace for secret door event test
game status list (events triggered)
Triggerable Events
System:
Future Features (2nd Priority:
Play:
Player Stats
Equip gear and weapons
consume foods and drink
Dangerous Events
Static Enemies
Future Features (3rd Priority)
Play:
Wandering Enemies (with defined map boundaries)
NPCs with Dialogue Trees
Money
Shops with static goods
Eat and Drink
Time based on number of turns (day, night, ect...)
wait command
System:
Save Game
Load Game
Score
Future Features (4th Priority)
Play:
Economy(?)
Shops with shifting goods lists
Magic
Give each definition a dictionary of exits like:
exits = {'north': testroom1(),
'south': testroom2()}
default_exit = testroom3()
In default room have a transition method that's like:
def transition(self, exit):
self.exit = exit
if exit in exits:
return exits[exit]
else:
return default_exit
This is really rough. You can fix it up.
Also, I would recommend giving your game engine a "map",
somewhat like how Zed Shaw did in the text adventure in Hard Way.
Rather than having rooms create rooms keep a dictionary of rooms
in the engine that is called when the program start. Something
like {"den": room1(), "kitchen": room2()...}
That way you can just have something like
current_location = self.map["den"]
So you only initialize the rooms when the game first starts.
Comments
0 B
|👍
/👎