options: tag: &8[&aO&4X&8]&7: &r variables: {ox.start} = false {ox.start.dolaczanie} = true {ox.online.max} = 0 {ox.pytanie} = false command /ox [] [] []: trigger: arg 1 is "setspawn": player have permission "ox.setspawn" or "ox.*": set {ox.spawn} to location of player send "{@tag}&6Ustawiles spawn!" stop arg 1 is "start": player have permission "ox.start" or "ox.*": {ox.start} is false: send "{@tag}&6Wystartowales event!" set {ox.start} to true set {ox.organizator} to "%player%" else: send "{@tag}&6Event zostal juz wystartowany!" stop arg 1 is "setadmin": player have permission "ox.setadmin" or "ox.*": set {ox.admin.spawn} to location of player send "{@tag}&6Ustawiles spawn dla adminow!" stop arg 1 is "admin": player have permission "ox.admin" or "ox.*": execute player command "/spawn" teleport player to {ox.admin.spawn} send "{@tag}&6Witamy na evencie! :)" arg 1 is "dolacz" or "join": {ox.start} is true: {ox.start.dolaczanie} is true: {ox.player.%player%} is not set: set {ox.player.%player%} to true add 1 to {ox.online} execute player command "/spawn" teleport player to {ox.spawn} display scoreboard named "&8[&aO&4X&8]&7" to player move display of player to "sidebar" add 1 to {ox.online.max} loop all players: {ox.player.%loop-player%} is true: make score of "&9Liczba graczy" in scoreboard of loop-player to {ox.online} else: send "{@tag}&6Nie mozesz dolaczyc do eventu, na ktorym aktualnie jestes!" else: send "{@tag}&6Event juz sie zaczal!" else: send "{@tag}&6Aktualnie nie odbywa sie event!" stop arg 1 is "wyjdz" or "leave": {ox.player.%player%} is true: remove 1 from {ox.online} clear {ox.player.%player%} execute player command "/spawn" send "{@tag}&6Wyszedles z areny!" nullify score of "&9Liczba graczy" in scoreboard of player else: send "{@tag}&6Musisz byc na evencie, aby z niego wyjsc 0_0" stop arg 1 is "pytanie": player have permission "ox.pytanie" or "ox.*": arg 2 is set: arg 2 is "tak" or "nie": set {ox.odp} to "%arg 2%" arg 3 is set: loop all players: {ox.player.%loop-player-1%} is true: {ox.pytanie} is false: {ox.start.dolaczanie} is true: send "{@tag}&6&lEvent juz sie zaczal, mozliwosc dolaczenia zostala wylaczona!" set {ox.start.dolaczanie} to false set {ox.pytanie} to true send "{@tag}&6Odpowiedz zostala ustawiona na: &4%{ox.odp}%" send "{@tag}&7[&6Pytanie&7] &b%arg 3%" to loop-player-1 make score of "&1Pozostaly czas" in scoreboard of loop-player to 30 send "{@tag}&6Pozostalo 30 sekund na odpowiedz" to loop-player-1 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 29 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 28 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 27 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 26 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 25 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 24 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 23 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 22 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 21 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 20 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 19 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 18 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 17 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 16 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 15 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 14 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 13 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 12 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 11 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 10 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 9 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 8 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 7 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 6 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 5 send "{@tag}&6Czas na odpowiedz:&c 5" to loop-player-1 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 4 send "{@tag}&6Czas na odpowiedz:&c 4" to loop-player-1 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 3 send "{@tag}&6Czas na odpowiedz:&c 3" to loop-player-1 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 2 send "{@tag}&6Czas na odpowiedz:&c 2" to loop-player-1 wait 1 second make score of "&1Pozostaly czas" in scoreboard of loop-player to 1 send "{@tag}&6Czas na odpowiedz:&c 1" to loop-player-1 wait 1 second nullify score of "&1Pozostaly czas" in scoreboard of loop-player send "{@tag}&6Poprawna odpowiedz to:&c %{ox.odp}%" to loop-player-1 loop all players: {ox.odp} is "tak": {ox.odp.%loop-player-2%} is "tak": send "{@tag}&6Udalo ci sie poprawnie odpowiedziec na pytanie! Przechodzisz dalej." to loop-player-2 clear {ox.win::*} add "%loop-player-2%" to {ox.win::*} teleport loop-player-2 to {ox.spawn} clear {ox.odp.%loop-player-2%} {ox.odp.%loop-player-2%} is "nie": send "{@tag}&6Niestety, zle odpowiedziales na pytanie!" to loop-player-2 remove 1 from {ox.online} clear {ox.player.%loop-player-2%} execute loop-player-2 command "/spawn" nullify score of "&9Liczba graczy" in scoreboard of loop-player-2 remove "%loop-player-2%" from {ox.win::*} {ox.odp.%loop-player-2%} is "brak": send "{@tag}&6Nie wybrales zadnej odpowiedzi! Straciles szanse" to loop-player-2 remove 1 from {ox.online} clear {ox.player.%loop-player-2%} execute loop-player-2 command "/spawn" nullify score of "&9Liczba graczy" in scoreboard of loop-player-2 remove "%loop-player-2%" from {ox.win::*} {ox.odp} is "nie": {ox.odp.%loop-player-2%} is "nie": send "{@tag}&6Udalo ci sie poprawnie odpowiedziec na pytanie! Przechodzisz dalej." to loop-player-2 clear {ox.win::*} add "%loop-player-2%" to {ox.win::*} teleport loop-player-2 to {ox.spawn} clear {ox.odp.%loop-player-2%} {ox.odp.%loop-player-2%} is "tak": send "{@tag}&6Niestety, zle odpowiedziales na pytanie!" to loop-player-2 remove 1 from {ox.online} clear {ox.player.%loop-player-2%} execute loop-player-2 command "/spawn" nullify score of "&9Liczba graczy" in scoreboard of loop-player-2 remove "%loop-player-2%" from {ox.win::*} {ox.odp.%loop-player-2%} is "brak": send "{@tag}&6Nie wybrales zadnej odpowiedzi! Straciles szanse" to loop-player-2 remove 1 from {ox.online} clear {ox.player.%loop-player-2%} execute loop-player-2 command "/spawn" nullify score of "&9Liczba graczy" in scoreboard of loop-player-2 remove "%loop-player-2%" from {ox.win::*} {ox.online} is 1: send "{@tag}&c%{ox.win::*}%&6 wygral" to all players log "Organizowal: %{ox.organizator}% Wygral: %loop-player% Gralo: %{ox.online.max}%" to "ox.log" clear {ox.odp} clear {ox.online.max} clear {ox.win::*} clear {ox.organizator} set {ox.start} to false set {ox.start.dolaczanie} to true set {ox.online} to 0 set {ox.online.max} to 0 loop all players: nullify score of "&9Liczba graczy" in scoreboard of loop-player-1 clear {ox.player.%loop-player-1%} clear {ox.odp.%loop-player-1%} stop {ox.online} is less than 1: send "{@tag}&6Nikt nie wygral" to all players log "Organizowal: %{ox.organizator}% Gralo: %{ox.online.max}%" to "ox.log" clear {ox.odp} clear {ox.online.max} clear {ox.win::*} clear {ox.organizator} set {ox.start} to false set {ox.start.dolaczanie} to true set {ox.online} to 0 set {ox.online.max} to 0 loop all players: nullify score of "&9Liczba graczy" in scoreboard of loop-player-1 clear {ox.player.%loop-player-1%} clear {ox.odp.%loop-player-1%} stop set {ox.pytanie} to false stop else: send "{@tag}&6Pytanie juz jest zadane!" else: send "{@tag}&6Nie wpisales pytania!" else: send "{@tag}&6Musisz wpisac odpowiedz tak/nie" else: send "{@tag}&6Musisz wpisac odpowiedz tak/nie" stop arg 1 is "restart": player have permission "ox.restart" or "ox.*": send "{@tag}&6Zrestartowano wszystkie zmienne!" clear {ox.odp} clear {ox.win::*} clear {ox.organizator} set {ox.start} to false set {ox.start.dolaczanie} to true set {ox.online} to 0 set {ox.online.max} to 0 set {ox.pytanie} to false loop all players: clear {ox.player.%loop-player%} clear {ox.odp.%loop-player%} nullify score of "&9Liczba graczy" in scoreboard of loop-player stop arg 1 is "reload": player have permission "ox.reload" or "ox.*": execute player command "sk reload %script%" stop arg 1 is "info": {ox.start} is true: send "{@tag}&6Aktualnie odbywa sie event!" else: send "{@tag}&6Aktualnie&c nie&6 odbywa sie event!" send "{@tag}&6Aktualnie w grze jest %{ox.online}%" stop arg 1 is "pomoc": send "&6=-=-=-={@tag}&7[&2Pomoc&7]&6=-=-=-=" send "&6/ox dolacz &8- &7Dolaczanie do areny (jezeli jest organizowana)" send "&6/ox wyjdz &8- &7Wychodzenie z areny" send "&6/ox info &8- &7Info o evencie" player have permission "ox.*": send "&6=-=-=-=&cKomendy admina&6=-=-=-=" send "&6/ox start &8- &7Startowanie eventu" send "&6/ox pytanie tak/nie &8- &7Zadawanie pytania dla graczy" send "&6/ox admin &8- &7Teleport na event dla adminow" send "&6/ox setadmin &8- &7Ustawianie teleportu dla adminow" send "&6/ox setspawn &8- &7Ustawianie spawnu dla graczy" send "&6/ox reload &8- &7Reloadowanie skryptu" send "&6/ox restart &8- &7Restartowanie zmiennych" send "&6=-=-=-={@tag}&7[&2Pomoc&7]&6=-=-=-=" else: send "&6=-=-=-={@tag}&7[&2Pomoc&7]&6=-=-=-=" stop arg 1 is not set: send "{@tag}&cUzyj /ox pomoc" stop else: send "{@tag}&cBledna komenda! Uzyj /ox pomoc!" every 10 second: {ox.start} is true: {ox.start.dolaczanie} is true: send "{@tag}&6&lNiedlugo zacznie sie event! Wpisz &c&n/ox dolacz&r&6&l aby dolaczyc" to all players on quit: {ox.player.%player%} is true: restore inventory of player from {ox.inventory.%player%} clear {ox.inventory.%player%} remove 1 from {ox.online} clear {ox.player.%player%} every 1 second: loop all players: loop-player have permission "ox.*": {ox.start} is true: make score of "&9Liczba graczy" in scoreboard of loop-player to {ox.online} else: nullify score of "&9Liczba graczy" in scoreboard of loop-player on respawn: {ox.player.%player%} is true: restore inventory of player from {ox.inventory.%player%} clear {ox.inventory.%player%} remove 1 from {ox.online} clear {ox.player.%player%} on command: {ox.player.%player%} is true: command is "ox": stop else: cancel event #on chat: # {ox.player.%player%} is true: # cancel event on drop: {ox.player.%player%} is true: cancel event on step on light green wool: {ox.player.%player%} is true: set {ox.odp.%player%} to "tak" on step on red wool: {ox.player.%player%} is true: set {ox.odp.%player%} to "nie" on step on white wool: {ox.player.%player%} is true: set {ox.odp.%player%} to "brak"