- This event has passed.
6 PM – Intro To Java – Gamas
November 11 @ 6:00 pm - 7:00 pm
Today We Did
- We continued with Monster Inheritance project
- We display the main menu
- We added adMonster
- We added listAllMonsters
- We started Start Adventure
Homework
Inside MonsterInheritanceMain.java, inside startAdventure().
- Add code that would display the player’s name and health.
- Add code that would display list of monster menu in a forever loop after user enter their name and health. If they enter “exit”, it will go back to the main menu. Look at below example
-
MAIN MENU: 1. View All Monsters 2. Add New Monster 3. Start Adventure Make your selection (enter 'exit' to quit): 3 PLAY ADVENTURE Enter player's name: Gamas Enter player's health: 100 Hi Gamas, welcome to AYC Logic Game!! Gamas, you have 100 health remaining. Gamas remaining health is 100. Please choose the monster you wish to fight. - Dragon - 100 health - 20 minimum damage - 100 maximum damage - Stone Golem - 50 health - 20 minimum damage - 50 maximum damage - Water Golem - 50 health - 20 minimum damage - 50 maximum damage - Minotaur - 80 health - 25 minimum damage - 80 maximum damage - Cylops - 75 health - 15 minimum damage - 90 maximum damage Enter your selection (enter 'exit' to quit): dragon Gamas remaining health is 100. Please choose the monster you wish to fight. - Dragon - 100 health - 20 minimum damage - 100 maximum damage - Stone Golem - 50 health - 20 minimum damage - 50 maximum damage - Water Golem - 50 health - 20 minimum damage - 50 maximum damage - Minotaur - 80 health - 25 minimum damage - 80 maximum damage - Cylops - 75 health - 15 minimum damage - 90 maximum damage Enter your selection (enter 'exit' to quit): exit MAIN MENU: 1. View All Monsters 2. Add New Monster 3. Start Adventure Make your selection (enter 'exit' to quit):