Your energy at the top is basically your health bar and if it drains to 0 the game will end. Enemies will also drain your energy if they touch the button, I find when play testing it I would sometimes forget where the bar was when attacking enemies or an enemy got past me. I Should probably add something that makes that clearer.