Player Health and Death


After implementing the waypoint system I spent some time refactoring the game code and fixed some minor bugs. After I felt like the project was in a good state I started working on the player health system.

Whenever the player makes a hard landing, which occurs if they jump off a tall platform or fall off the map, they will lose one health. If the player's health drops to zero a death animation will play and the player will respawn at the last major checkpoint (the start of the level and the entrance to the last section of the level).

I also added a rudimentary health UI so players can see their current health. This system will be important for implementing new hazards like spikes. I also eventually plan to add some feedback to the player health UI such as basic animations when health is lost or gained. I'm also looking into whether I can add a particle system to the UI as additional feedback for losing health.

Files

vaults-and-vampires-webgl.zip Play in browser
Version 2024-01-15-b37eef0 Jan 15, 2024

Leave a comment

Log in with itch.io to leave a comment.