Working healthbar tied to player

Healthbar done, separating player code to work better.