Adding lives and health on game-maker

Adding lives and health on game-maker








the fist thing i did whilst adding the lives and health on game maker was create an object called lives, then selected the event  'room start' and set health to 100. then i clicked on the event draw and added the action draw health bar. 







after this i started working on making the game more immersive by setting the alarm 0 to 30 and creating a variable that every second the health looses 2 points until the player dies and has to restart the game. 
after this i added the lives which at first where just points that went down every time you got hit however because it was hard to see i had to change it to big read hearts. 

to make this work i added the variable on the red object, that says: "if the red object impacts with the blue the health of the player goes down by 1 and if it reaches 0 it goes back to the start menu, in other levels i would just make it restart that level. 

Comments