Hi I'm making a game which includes a health bar.
The health bar uses to variables, Health and Max. Health. With health being the health of player and Max. Health being the maximum healh.
Also, you can increase your maximum health with armour using this script.
forever set(Max. health v) to ((Max. health)+(armour))However, it when the armour value is greater than 0, the maximum health constancy increases. For example if armour is 4, the varible keeps rising by 4.
Offline
It's doing that because it's always making the maxhealth variable equal to itself plus armour, I don't know the context but it'd probably be best to either have that run once whenever armour changes, or when the gf is clicked. Or you could always have a separate variable that is the sum of the two
Offline
Offline