command /testy:
trigger:
open chest with 6 rows named "Disco XD" to player
set {_kolor} to 1
set player's current inventory's slot 0 to leather helmet
while inventory name of current inventory of player is "Disco XD":
if {_kolor} is 1:
dye (player's current inventory's slot 0) (0, 0, 255)
if {_kolor} is 2:
dye (player's current inventory's slot 0) (0, 255, 0)
if {_kolor} is 3:
dye (player's current inventory's slot 0) (255, 0, 0)
add 1 to {_kolor}
if {_kolor} is 4:
set {_kolor} to 1
wait 0.5 second
on inventory click:
if inventory name of current inventory of player is "Disco XD":
cancel event