command /arena [] []: trigger: if arg 1 is "dolacz": if player has permission "arena.gracz": if {arena.arena.start} is true: if {team.gracz.%player%} is not set: if arg 2 is set: if arg 2 is "red" or "czerwony": teleport player to {arena.arena.red} set {team.gracz.%player%} to "red" loop all items in player's inventory: add loop-item to {arena::eq::%{_nick}%::*} send "&aPomyslnie zapisano ekwipunek" clear the player's inventory equip player with all Leather armour named "&4&lDruzyna Red" dye player's helmet red dye player's chestplate red dye player's leggings red dye player's boots red enchant the player's boots with protection 5 and Unbreaking 10 enchant the player's leggings with protection 5 and Unbreaking 10 enchant the player's chestplate with protection 5 and Unbreaking 10 enchant the player's helmet with protection 5 and Unbreaking 10 give player diamond sword set spawn of player's to {arena.arena.red} stop if arg 2 is "blue" or "niebieski": teleport player to {arena.arena.blue} set {team.gracz.%player%} to "blue" loop all items in player's inventory: add loop-item to {arena::eq::%{_nick}%::*} send "&aPomyslnie zapisano ekwipunek" clear the player's inventory equip player with all Leather armour named "&4&lDruzyna Blue" dye player's helmet blue dye player's chestplate blue dye player's leggings blue dye player's boots blue enchant the player's boots with protection 5 and Unbreaking 10 enchant the player's leggings with protection 5 and Unbreaking 10 enchant the player's chestplate with protection 5 and Unbreaking 10 enchant the player's helmet with protection 5 and Unbreaking 10 give player diamond sword set player's spawn to {arena.arena.red} stop if arg 2 is "green" or "zielony": teleport player to {arena.arena.green} set {team.gracz.%player%} to "green" loop all items in player's inventory: add loop-item to {arena::eq::%{_nick}%::*} send "&aPomyslnie zapisano ekwipunek" clear the player's inventory equip player with all Leather armour named "&4&lDruzyna Green" dye player's helmet green dye player's chestplate green dye player's leggings green dye player's boots green enchant the player's boots with protection 5 and Unbreaking 10 enchant the player's leggings with protection 5 and Unbreaking 10 enchant the player's chestplate with protection 5 and Unbreaking 10 enchant the player's helmet with protection 5 and Unbreaking 10 give player diamond sword set player's spawn to {arena.arena.red} stop if arg 2 is "yellow" or "zloty": teleport player to {arena.arena.yellow} set {team.gracz.%player%} to "yellow" loop all items in player's inventory: add loop-item to {arena::eq::%{_nick}%::*} send "&aPomyslnie zapisano ekwipunek" clear the player's inventory equip player with all Leather armour named "&4&lDruzyna Yellow" dye player's helmet yellow dye player's chestplate yellow dye player's leggings yellow dye player's boots yellow enchant the player's boots with protection 5 and Unbreaking 10 enchant the player's leggings with protection 5 and Unbreaking 10 enchant the player's chestplate with protection 5 and Unbreaking 10 enchant the player's helmet with protection 5 and Unbreaking 10 set spawn of player to {arena.arena.red} give player diamond sword stop else: send "&6LISTA TEAMOW TO: &bczerowny &bNiebieski &aZielony &6zolty" stop else: execute player command "arena dolacz gui" stop else: send "&6&lPosiadasz juz druzyne, {team.gracz.%player%}" stop else: send "&4Arena jest nieczynna" stop if arg 1 is "help": send "&6Aby dolaczyc do areny uzyj komendy &4/Arena dolacz" send "&6Aby wyjsc z areny uzyj komendy &4/Arena leave" if arg 1 is "leave": if {team.gracz.%player%} is set: clear {team.gracz.%player%} clear player's inventory add {arena::eq::%{_nick}%::*} to player's inventory teleport player to spawn add {emeraldy.emeraldy.%player%} of emerald to player's inventory else: send "&4&lNIE MASZ PRZYDZIELONEJ DRUZYNY" if arg 1 is "ustawspawn": if arg 2 is "blue": set {arena.arena.blue} to location of player send "&4Ustawiles spawn druzyny blue" if arg 2 is "red": set {arena.arena.red} to location of player send "&4Ustawiles spawn druzyny red" if arg 2 is "yellow": set {arena.arena.yellow} to location of player send "&4Ustawiles spawn druzyny yellow" if arg 2 is "green": set {arena.arena.green} to location of player send "&4Ustawiles spawn druzyny green" if arg 1 is "wlacz": set {arena.arena.start} to true send "&4Arena zostala wlaczona" on damage of player: if {team.gracz.%attacker%} is "red": if {team.gracz.%victim%} is "red": cancel event send "&4&lNIE MOZESZ BIC SWOICH" if {team.gracz.%attacker%} is green: if {team.gracz.%victim%} is green: cancel event send "&4&lNIE MOZESZ BIC SWOICH" if {team.gracz.%attacker%} is blue: if {team.gracz.%victim%} is blue: cancel event send "&4&lNIE MOZESZ BIC SWOICH" if {team.gracz.%attacker%} is yellow: if {team.gracz.%victim%} is yellow: cancel event send "&4&lNIE MOZESZ BIC SWOICH" on death of player: if attacker is in world "BedWars": if victim is in world "BedWars": add 1 to {emaraldy.emeraldy.%attacker%} send "&b&lPo wyjsciu dostaniesz {emeraldy.emeraldy.%player%} szmaragdow"