How to make an armor piece that gives health?

  • 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.

jameym

Member
Jun 5, 2022
1
0
1
42
So I am trying to make an armor piece that when equip[ped increases the player's max health by 50

This is my code currently:

every 1 tick:
loop all players:
if loop-player is wearing an iron helmet:
if name of loop-player's helmet is "Skeleton Helmet":
set the maximum health of the loop-player to 150

every 1 tick:
loop all players:
if loop-player is not wearing an iron helmet:
if name of loop-player's helmet is not "Skeleton Helmet":
set the maximum health of the loop-player to 100



Now this technically increases the health by 50 but it is a set value and wont work for like a mmorpg world.

Ive tried using %player's health +50% but it I get an error message saying I can not increases the max health because %player's health +50% is not a number.

Any ideas on how to do what im trying to do?
 
Status
Not open for further replies.