variables: {wybrana.%player%} = false on join: if {wybrana.%player%} is false: wait 5 tick open chest with 1 row named "WYBIERZ KLASE" to player set player's current inventory's slot 0 to stone named "Frakcja droidow" with lore "lore" set player's current inventory's slot 1 to dirt named "Frakcja wojownikow" with lore "lore" on inventory close: if inventory name of current inventory of player is "WYBIERZ KLASE": if {wybrana.%player%} is false: send "&cWybierz klase!" wait 5 tick open chest with 1 row named "WYBIERZ KLASE" to player set player's current inventory's slot 0 to stone named "Frakcja droidow" with lore "lore" set player's current inventory's slot 1 to dirt named "Frakcja wojownikow" with lore "lore" on inventory click: if inventory name of current inventory of player is "WYBIERZ KLASE": cancel event if clicked slot is 0: execute console command "pex user %player% group set Droid" send "daj wiadomosc" to player set {wybrana.%player%} to true if clicked slot is 1: execute console command "pex user %player% group set Wojownik" send "daj wiadomosc" to player set {wybrana.%player%} to true