command /widz: trigger: if player has permission "widz.cmd": wait 1 tick open chest with 1 rows named "&b&lWidzenie" to player wait 2 ticks set {_a} to 0 loop 9 times: format slot {_a} of player with black glass to be unstealable add 1 to {_a} format slot 2 of player with ender pearl named "&aEFEKT WIDZENIA" with lore "&e&lWLACZ" to close then run [execute player command "/wlasginasp"] format slot 6 of player with ender pearl named "&aEFEKT WIDZENIA" with lore "&c&lWYLACZ" to close then run [execute player command "/wlasginasp"] command /wlasginasp: trigger: if {widzenie.%player%} is not set: send "&aWlaczyles/as efekt widzenia!" set {widzenie.%player%} to true apply night vision to player for 999 days stop else: send "&aWylaczyles/as efekt widzenia!" delete {widzenie.%player%} remove night vision from player stop