« All Events
6 PM – Python OOP – Shawn
December 19, 2023 @ 6:00 pm - 7:00 pm
Today We:
- Continued the Monster Inheritence system project
Your HW:
- Add the magic attack options using a dictionary
- create 2 new dictionaries as atributes, magic_types and magic_damages
- Make their keys be “1”, “2” . . . “4” like the numbers in the magic menu (we’re doing the same thing as the grocery system menu)
- Make the magic_types values be the corresponding magic element from the menu ex: “fire”, “water”, “earth”, “air”
- Make the magic_damages values be the corresponding damage each magic attack does, ex: 15,15,15,18
- Ask the user what type of magic damage they want using the magic_menu
- Use the 2 dictionaries you created to get the magic type and damage
- Then call the recieve_magic_attack on the selected monster and feed it the correct parameters based on the user input
- Also make sure to calculate the damage the user takes after attacking the monster
- No class next week, resumes 1/2/24