i wish a health bar

i wanna make a game where i can get hit by spikes and survive by health bar where when it eaches 0 my level re starts

try something like this: http://flowlab.io/game/view/9822

well…i guess it solved nothing for him.

he wanna know how to make one.