Chapter 18Keep Going
You now have a functioning (albeit limited) text-based adventure game. Using libraries and functions, lists and dictionaries, and classes, you have everything you need to really build a complete and comprehensive game. In this chapter, we’ll give you some ideas about where to go next and pointers to help you get there.
Health and Lives
Many games track player lives. When players die, they lose a life and continue playing. The game is over when no lives are left. Our player
class has properties and methods for using lives, and you can use them in your game.
Newer games also track player health and often combine doing so ...
Get Captain Code: Unleash Your Coding Superpower with Python now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.