How to make a health bar?
kwan_blanche
Member Posts: 4
I've followed the instruction given on the wiki..but it doesn't work..
and what does this mean..
"When your player takes damage, make sure you put in a 'change attribute' behaviour to tell the game that your energy/lives is energy/lives-1"
what do I do with the "change attribute"? and is it for the health bar or the player?
and what does this mean..
"When your player takes damage, make sure you put in a 'change attribute' behaviour to tell the game that your energy/lives is energy/lives-1"
what do I do with the "change attribute"? and is it for the health bar or the player?
Comments
Make sure you are on game, then click on the middle tab (Attributes), which is below where it says inspector.
Click the + at the bottom of the new panel.
My Health bar has a constrain attribute: self.Size.Width To: 100*game.Lives/10
My actor has a change attribute place under his collide rule. with game.Player lives To. game/lives-1
When I test my game and colide with an enemy my actor just explodes and the health bar does nothing?
Is this because I need to move or change the Spawn actor that creates an explosion when it collides with enemy?
but the player's life should ends right? and player should be destroyed and disappears and the game should end..then how can i do that?
Thanks