Please help me with HP

So, as some of you might know, I’m working on a game called Vironia. I’m working on simple HP for the player object (Vora). Here are some screenshots of the code I have:

When the player dies the HP number goes past 0:

And, once the player gets hit on the next life, he dies in one hit since the HP number is a negative. I just barely got past fixing an infinite loop error that might’ve destroyed my game trying to fix the HP.
I think it has something to do with the behaviors not re-setting when the player dies.

These are the death behaviors. They contain no 'Restart level.'

Since the death behaviors don’t contain Restart Level, the behaviors don’t re-set when the player dies. My help request is this: I need a way for the HP number to reset when the player dies.

My team member is away so he cannot help.

Thank you,
-Ember.Y

Filter, less than or equal to 0. Quite simple you don’t need all that code pass will restart the level and fail will output it into a bar.

2 Likes


I said,

Pass → 0 → global/number → health amount

1 Like

Could you please send a screenshot? I am quite confused and don’t know what output or input use on each behavior.

Never mind, I fixed it.

Cool bug that I saw while editing the level fading:

The main reason I didn’t want to use ‘Restart level’ is because the game contained a really cool fading object that made the screen fade when the player died and when the game started.

I made the restart level happen after the screen fades, easy.

2 Likes

Cool, sorry I didn’t respond I was at work

1 Like