Help with setting up dynamic health

I wanted my health system to be similar to the one in Doodle adventures. Each of the health trees have a wire that will purchase a channel that will add one to the counter, and the counter also adds one to the property

From there, every time you are defeated, a lifecycle will say you were defeated, and will activate the five checkers. Each of the checkers has a corresponding property requirement, and health module. For instance if you have activated two trees and are defeated, the checker will see you have a property of two and give you an additional 200 shield.

However, this is not how it is working. You just never gain any additional shield even though your property is the right number. Any ideas for might be wrong?

Uh,let’s see,if this is the case,let’s try debugging the health granters.
Could you show us the settings for the health granters?

Is there block code for this?

No I have not.

Should I have?

Given your case, most likely.

The reason that it’s not granting health is because the granters don’t know the property exists,and therefor it can’t calculate how much shield to grant

Also with the block code you could save 4 health granters and 5 checkers

In that case, what should I do to fix it?

Is the property type set to number? Are you sure the health granter is activating properly?

What’s your max hp and shield set to? (In map options)

Wait ignore the second question

BROOOOOO. I set the lifecycle to Player knocks out and not knocked out…

lol that happens sometimes

Hm. Are your checkers set correctly? Are they receiving on a channel or wire?

Do you have a sign wrong in a checker? Example: less than instead of greater than.

It is still not working :confused:

What is the property’s scope? Player, right? And did you make sure the counter is set up correctly?

Yeah the property is set to player, and I don’t know how to check if the counter is working right.

My checkers are using channels

If the counter is visible in-game, you can move it so you can see it. Once you do something that should make the counter increase, go check it

1 Like

Yes the counter is counting up
And I have a second counter that checks for the property amount, so it is not that the property isn’t updating.

Well then it has to be your checkers/health granters. The channels are the exact same and in the correct spot, right?

Just double checked them, but still no luck…

Have you checked if the lifecycle is broadcasting to all the checkers?

I just figured something out! The problem is with the lifecycle!!! It is not detecting that a player got defeated. With this in mind, any ideas on how to remake the system?