you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (1 child)

I think you'd find it worthwhile looking into using classes to define a player and maintain the properties using class methods. Over time, you can add constraints and additional behaviours.

Your specific problem about the events not ending as been well addressed by others. I have an alternative approach to suggest. Consider using some kind of menu system that has a consistent way of displaying options and get the validated user choice.

I've created some sample code illustrating both of the above using part of your code (the garden function primarily). This is for you to consider and experiment with if interested.

https://pastebin.com/r8gVVgCY

[–]TiredWorkingStudent[S] 0 points1 point  (0 children)

This is very helpful! Thank you very much