nss-evening-cohort-12 / dino-kennel

A place to see all your dinos and send them on adventures!
0 stars 2 forks source link

Health Based of Species/Type #17

Open JeremiahV93 opened 4 years ago

JeremiahV93 commented 4 years ago

User Story

As a user, when I create a dino #4 the health that is assigned will be based of the type of dinosaur

AC

WHEN the user creates a dino THEN the function should assign the health AND there should be a switch statement that will use the species type to assign a specific health.

Dev Notes.

in buildDino () add a switch function that will take the value of the dropdown and assign health in the tempDino object based on the species


switch (getid.dinoTypeValue) {
case "T-rex": tempDino.health = 150
break;
case "Pterodactyl":  tempDino.health = 125
break;
etc
}
T-Rex =150
Pterodactyl = 125
Brachiosaurus= 175
Stegosaurus =100 
Triceratops = 250
Velociraptor = 50
* TODO
JeremiahV93 commented 4 years ago

hp values need to be discussed/approved