aliases:
craft = 58
options:
gorronox : iron helmet with nbt "{AttributeModifiers:[{Slot:""head"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:0,UUIDMost:0}]}" named "&eGorro anti nox"
pecheranox : iron chestplate with nbt "{AttributeModifiers:[{Slot:""chest"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:1,UUIDMost:1}]}" named "&ePechera anti nox"
pantalonnox : iron leggings with nbt "{AttributeModifiers:[{Slot:""legs"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:2,UUIDMost:2}]}" named "&ePantalones anti nox"
botasnox : iron boots with nbt "{AttributeModifiers:[{Slot:""feet"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:3,UUIDMost:3}]}" named "&eBotas anti nox"
on inventory click:
#message "%clicked slot%"
if player's target block is craft:
if clicked slot is 0:
if event-item is iron helmet:
if slot 8 of current inventory of player is blaze_rod:
add "{AttributeModifiers:[{Slot:""head"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:0,UUIDMost:0}]}" to nbt of event-item
message "Work helmet"
stop
if event-item is iron chestplate:
if slot 2 of current inventory of player is blaze_rod:
add "{AttributeModifiers:[{Slot:""head"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:1,UUIDMost:1}]}" to nbt of event-item
message "Work chestplate"
stop
if event-item is iron leggings:
if slot 5 and 5 of current inventory of player is blaze_rod:
add "{AttributeModifiers:[{Slot:""head"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:2,UUIDMost:2}]}" to nbt of event-item
message "Work leggings"
stop
if event-item is iron boots:
if slot 1 and 3 of current inventory of player is blaze_rod:
add "{AttributeModifiers:[{Slot:""head"",AttributeName:""generic.armor"",Name:""armor"",Amount:0,Operation:0,UUIDLeast:3,UUIDMost:3}]}" to nbt of event-item
message "Work boots"
stop
message "Don't work"
stop
on damage:
victim is wearing {@gorronox} or {@pecheranox} or {@pantalonnox} or {@botasnox}:
set {_dmg} to damage
set damage to 0
subtract {_dmg} from victim's health
send "Test to see if it works" to victim
every 5 seconds in world "dangoria":
loop all players:
loop-player is in world "dangoria":
if loop-player has permission "skripts.inmune":
stop
if loop-player's gamemode is creative:
stop
else:
loop {radiacion.habitable::*}:
distance between the loop-player and loop-value-2 is between 200 and 249:
if {radiacion.mensaje.aviso.cooldown::%loop-player%} isn't set:
send "{@auraalerta} <orange>El sistema alerta que esta cerca de una zona esta afectada por nox. <red>Equipate con un traje anti nox lo antes posible." to loop-player
set {radiacion.mensaje.aviso.cooldown::%loop-player%} to 2
else:
subtract 1 from {radiacion.mensaje.aviso.cooldown::%loop-player%}
if {radiacion.mensaje.aviso.cooldown::%loop-player%} is 0:
delete {radiacion.mensaje.aviso.cooldown::%loop-player%}
stop
distance between the loop-player and loop-value-2 is more than 250:
loop-player is wearing a iron helmet:
if name of helmet slot of loop-player is "<yellow>Gorro anti nox":
loop-player is wearing a iron chestplate:
if name of chestplate slot of loop-player is "<yellow>Pechera anti nox":
loop-player is wearing a iron leggings:
if name of leggings slot of loop-player is "<yellow>Pantalones anti nox":
loop-player is wearing a iron boots:
if name of boots slot of loop-player is "<yellow>Botas anti nox":
set {_loreh} to uncolored lore of loop-player's helmet parsed as number
subtract 5 from {_loreh}
set line 1 of the lore of loop-player's helmet to "%{_loreh}%"
set {_lorec} to uncolored lore of loop-player's chestplate parsed as number
subtract 5 from {_lorec}
set line 1 of the lore of loop-player's chestplate to "%{_lorec}%"
set {_lorel} to uncolored lore of loop-player's leggings parsed as number
subtract 5 from {_lorel}
set line 1 of the lore of loop-player's leggings to "%{_lorel}%"
set {_loreb} to uncolored lore of loop-player's boots parsed as number
subtract 5 from {_loreb}
set line 1 of the lore of loop-player's boots to "%{_loreb}%"
if {_loreh} is less than 0:
set loop-player's helmet to air
send "<light red>El gorro anti nox ha quedado inservible" to loop-player
if {_lorec} is less than 0:
set loop-player's chestplate to air
send "<light red>El abrigo anti nox ha quedado inservible" to loop-player
if {_lorel} is less than 0:
set loop-player's leggings to air
send "<light red>Las botas anti nox han quedado inservibles" to loop-player
if {_loreb} is less than 0:
set loop-player's boots to air
send "<light red>Las botas anti nox han quedado inservibles" to loop-player
stop
{radiacion.mensaje.daño.cooldown::%loop-player%} isn't set:
send "{@auraalerta} <red>PELIGRO: <orange>Se detectan niveles dañinos de nox." to loop-player
set {radiacion.mensaje.daño.cooldown::%loop-player%} to 2
else:
subtract 1 from {radiacion.mensaje.daño.cooldown::%loop-player%}
if {radiacion.mensaje.daño.cooldown::%loop-player%} is 0:
delete {radiacion.mensaje.daño.cooldown::%loop-player%}
damage the loop-player by 1.5
apply nausea to loop-player for 10 seconds
apply slowness to loop-player for 10 seconds