Setting health and cancelling it

  • Welcome to skUnity!

    Welcome to skUnity! This is a forum where members of the Skript community can communicate and interact. Skript Resource Creators can post their Resources for all to see and use.

    If you haven't done so already, feel free to join our official Discord server to expand your level of interaction with the comminuty!

    Now, what are you waiting for? Join the community now!

  • LOOKING FOR A VERSION OF SKRIPT?

    You can always check out skUnity Downloads for downloads and any other information about Skript!

Status
Not open for further replies.

WiebeHero

Active Member
Aug 23, 2017
135
5
0
23
Hi i am WiebeHero and i got an issue here it is.
Code:
every 1 second:
loop all players:
loop-player's max health is above 9.5
if loop-player is wearing a helmet with lore "&7Reinforced I":
increase loop-player's max health by 1
if loop-player is not wearing helmet with lore "&7Reinforced I":
decrease loop-player's max health by 1
So it keeps adding up 1 but i just want it to add 1 without setting a max health like this: set loop-player's max health to 10
And decrease doesnt work for some reason is there another way?
Thanks!
 
use equip/unequip event its better than checking every second..
[doublepost=1506435518,1506433844][/doublepost]and you must use unequip/equip event because this can increase your health infinitely. And why you wont use set to max health of player to blabla. ?
 
Thats the problem i would use equip/unequip but im using the latest version of skript and it doesnt work there!
[doublepost=1506436242,1506436196][/doublepost]and the reason is i would have to make it so that at every health point health increases and i dont want to do that.
 
Ow woops that could be it XD
Nope just tested it doesnt work that way either.
I am though using the newest version of skript so that could be something
 
Status
Not open for further replies.