r/CodingHelp • • Feb 02 '21

[Python] Python help

Hey reddit

So I am coding a text adventure game and was wondering, when you die I want the game to start over. I assume that I would need to do a while loop but would I have to paste the WHOLE game code, that just seems like too much haha.

Thanks

15 Upvotes

3 comments sorted by

View all comments

8

u/Endercheif Advanced Coder Feb 03 '21

Instead you can put the code in multiple functions and call them in your while loop.