« All Events
5 PM – Python OOP – Bill
July 26, 2022 @ 5:00 pm - 6:00 pm
Today We:
- Continued the Monster System project
- Reviewed HW
- Created a player health attribute
- Created a monsters dictionary attribute
- Created a load_monsters method to fill the monsters dictionary
- Created a basic main loop
- Created a get_main_menu_response method
- Made it print out each monster’s health and attack and get the user input
Your HW:
- If the user selects a valid monster, ask the user for which type of attack they want to use:
- If the user enters 2, subtract from the Selected Monster’s health a random number between 10 and 20
What do you want to do with the {Selected Monster}
1. Magic attack
2. Sword attack - 10 to 20 damage
Enter your selection: