Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- on load:
- send "Minigra MicroBattle zostala pomyslnie wlaczona!" to console
- on unload:
- send "Minigra MicroBattle zostala wylaczona! :C" to console
- options:
- tag: &8[&eMicroBattle&8]
- arena.region: microbattle-arena
- czas: 30
- item: gold nugget
- name: &9Start gry za:&2
- command /mb [<text>] [<text>] [<text>]:
- description: Glowne komendy MicroBattle
- aliases: microbattle
- trigger:
- if arg 1 is not set:
- send "&2&m-----------------------------------------------"
- send "&b MicroBattle"
- send "&7- &e/mb create [arena_name] &7- Tworzy arene"
- send "&7- &e/mb delete [arena_name] &7- Usuwa arene"
- send "&7- &e/mb setmainlobby &7- Ustawia lobby glowne"
- send "&7- &e/mb setlobby [arena_name] &7- Ustawia lobby areny"
- send "&7- &e/mb setspawn [arena_name] [team] &7- Ustawia spawn druzyn"
- send "&7- &e/mb join [arena_name] &7- Dolacza do areny"
- send "&7- &e/mb leave &7- Wychodzi z areny"
- send "&7- &e/mb stats &7- Statystyki"
- send "&7- &e/mb reload &7- Przeladowanie skryptu"
- send "&b by boleknowak"
- send "&2&m-----------------------------------------------"
- if arg 1 is "reload" or "rl":
- send "{@tag} &7Przeladowano! :)"
- execute player command "sk reload %script%"
- if arg 1 is "create":
- if arg 2 is set:
- if {microbattle.arena.%arg 2%} is true:
- send "{@tag} &cTaka arena juz istnieje!"
- else:
- send "{@tag} &aArena &3%arg 2% &azostala pomyslnie stworzona!"
- set {microbattle.arena.%arg 2%} to true
- send "{@tag} &2Ustaw teraz: &bglowne lobby (&c/mb setmainlobby&b), lobby areny (&c/mb setlobby [arena_name]&b), spawny druzyn (&csetspawn [arena_name] [team]&b)"
- else:
- send "{@tag} &cPodaj nazwe areny!"
- if arg 1 is "delete":
- if arg 2 is set:
- if {microbattle.arena.%arg 2%} is true:
- set {microbattle.arena.%arg 2%} to false
- send "{@tag} &aUsuneles arene &c%arg 2%&a!"
- delete {microbattle.spawn.%arg 2%.team.red}
- delete {microbattle.spawn.%arg 2%.team.blue}
- delete {microbattle.spawn.%arg 2%.team.yellow}
- delete {microbattle.spawn.%arg 2%.team.green}
- delete {microbattle.lobby.%arg 2%}
- else:
- send "{@tag} &cPodaj nazwe areny!"
- if arg 1 is "setmainlobby":
- send "{@tag} &aUstawiles glowne lobby dla gry &eMicroBattle&a!"
- set {microbattle.main.lobby} to location of player
- if arg 1 is "setlobby":
- if arg 2 is set:
- if {microbattle.arena.%arg 2%} is true:
- send "{@tag} &aUstawiles lobby dla areny &6%arg 2%"
- set {microbattle.arena.%arg 2%.lobby} to location of player
- else:
- send "{@tag} &cNie ma takiej areny!"
- else:
- send "{@tag} &cPodaj nazwe areny!"
- if arg 1 is "setspawn":
- if arg 2 is set:
- if {microbattle.arena.%arg 2%} is true:
- if arg 3 is "blue":
- set {microbattle.spawn.%arg 2%.team.blue} to location of player
- send "{@tag} &cUstawiles spawn dla druzyny &1BLUE"
- if arg 3 is "red":
- set {microbattle.spawn.%arg 2%.team.red} to location of player
- send "{@tag} &cUstawiles spawn dla druzyny &4RED"
- if arg 3 is "yellow":
- set {microbattle.spawn.%arg 2%.team.yellow} to location of player
- send "{@tag} &cUstawiles spawn dla druzyny &eYELLOW"
- if arg 3 is "green":
- set {microbattle.spawn.%arg 2%.team.green} to location of player
- send "{@tag} &cUstawiles spawn dla druzyny &2GREEN"
- if arg 3 is not set:
- send "{@tag} &cPodaj team! (&6blue | red | yellow | green&c)"
- if arg 1 is "join":
- if arg 2 is set:
- if {microbattle.arena.%arg 2%} is true:
- if {microbattle.full.%arg 2%} is greater than 11:
- send "{@tag} &cNie mozesz dolaczyc bo jest arena pelna!"
- else:
- send "{@tag} &aDolaczyles do areny!"
- send "%arg 2%"
- send "{@tag} &9Teraz dolacz do druzyny!"
- send "{@tag} &3Team'y: &1BLUE&3, &2GREEN&3, &eYELLOW&3, &4RED"
- send "{@tag} &9Wybierz klase!"
- set {_} to "{@tag} &3Klasy: &7tank&3, &7worker&3, &7archer"
- replace all "<none>" with "NIE ZAKUPIONE" in {_}
- replace all "true" with "ZAKUPIONE" in {_}
- send "%{_}%"
- teleport player to {microbattle.arena.%arg 2%.lobby}
- set {microbattle.state.%player%} to true
- add 1 to {microbattle.full.%arg 2%}
- give nether star named "&6Sklep" to player
- if {microbattle.odlicz.%arg 2%} is greater than 10:
- execute player command "mb start %arg 2%"
- if arg 1 is "team":
- if arg 2 is "blue":
- if {microbattle.team.blue} is greater than 2:
- send "{@tag} &cNie mozesz do tego teamu wejsc! (3/3)"
- else:
- add 1 to {microbattle.team.blue}
- set {microbattle.team.%player%.blue} to true
- set {microbattle.team.%player%.red} to false
- set {microbattle.team.%player%.green} to false
- set {microbattle.team.%player%.yellow} to false
- add player to {microbattle.arena.players::*}
- add player to {microbattle.arena.team.blue.players::*}
- send "{@tag} &aWybrales team &1BLUE"
- if arg 2 is "red":
- if {microbattle.team.red} is greater than 2:
- send "{@tag} &cNie mozesz do tego teamu wejsc! (3/3)"
- else:
- add 1 to {microbattle.team.red}
- set {microbattle.team.%player%.blue} to false
- set {microbattle.team.%player%.red} to true
- set {microbattle.team.%player%.green} to false
- set {microbattle.team.%player%.yellow} to false
- add player to {microbattle.arena.players::*}
- add player to {microbattle.arena.team.red.players::*}
- send "{@tag} &aWybrales team &4RED"
- if arg 2 is "green":
- if {microbattle.team.green} is greater than 2:
- send "{@tag} &cNie mozesz do tego teamu wejsc! (3/3)"
- else:
- add 1 to {microbattle.team.green}
- set {microbattle.team.%player%.blue} to false
- set {microbattle.team.%player%.red} to false
- set {microbattle.team.%player%.green} to true
- set {microbattle.team.%player%.yellow} to false
- add player to {microbattle.arena.players::*}
- add player to {microbattle.arena.team.green.players::*}
- send "{@tag} &aWybrales team &2GREEN"
- if arg 2 is "yellow":
- if {microbattle.team.yellow} is greater than 2:
- send "{@tag} &cNie mozesz do tego teamu wejsc! (3/3)"
- else:
- add 1 to {microbattle.team.yellow}
- set {microbattle.team.%player%.blue} to false
- set {microbattle.team.%player%.red} to false
- set {microbattle.team.%player%.green} to false
- set {microbattle.team.%player%.yellow} to true
- add player to {microbattle.arena.players::*}
- add player to {microbattle.arena.team.yellow.players::*}
- send "{@tag} &aWybrales team &eYELLOW"
- if arg 2 is not set:
- send "{@tag} &cWybierz team! /mb team <blue | red | yellow | green>"
- if arg 1 is "kit":
- if arg 2 is "tank":
- remove bow from player
- remove 128 arrow from player
- remove stone pickaxe from player
- give wooden sword to player
- send "{@tag} &aWybrales klase &3tank"
- if arg 2 is "worker":
- if {microbattle.class.archer.state.%player%} is true:
- remove wooden sword from player
- give wooden sword to player
- give stone pickaxe to player
- send "{@tag} &aWybrales klase &3worker"
- else:
- send "{@tag} &cNie masz tej klasy zakupionej!"
- if arg 2 is "archer":
- if {microbattle.class.worker.state.%player%} is true:
- remove wooden sword from player
- give wooden sword to player
- give bow to player
- send "{@tag} &aWybrales klase &3archer"
- give 10 arrow to player
- wait 60 seconds
- give 20 arrow to player
- else:
- send "{@tag} &cNie masz tej klasy zakupionej!"
- if arg 2 is not set:
- send "{@tag} &aDostepne zestawy: &3tank&7, &3worker&7, &3archer"
- if arg 1 is "start":
- if arg 2 is set:
- if {microbattle.arena.%arg 2%} is true:
- set {_} to {@czas} + 1
- loop {@czas} + 1 times:
- add -1 to {_}
- remove {@item} from player
- give {@item} named "{@name} %{_}%" to player
- wait 1 seconds
- if {_} is 0:
- remove {@item} from player
- send "&aZostales przeteleportowany na arene!"
- teleport {microbattle.arena.team.red.players::*} to {microbattle.spawn.%arg 2%.team.red}
- teleport {microbattle.arena.team.blue.players::*} to {microbattle.spawn.%arg 2%.team.blue}
- teleport {microbattle.arena.team.green.players::*} to {microbattle.spawn.%arg 2%.team.green}
- teleport {microbattle.arena.team.yellow.players::*} to {microbattle.spawn.%arg 2%.team.yellow}
- send "{@tag} &6Za 10 sekund bedziesz mogl niszczyc, a za 20 atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &6Za 10 sekund bedziesz mogl niszczyc, a za 20 atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &6Za 10 sekund bedziesz mogl niszczyc, a za 20 atakowac!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &6Za 10 sekund bedziesz mogl niszczyc, a za 20 atakowac!" to {microbattle.arena.team.yellow.players::*}
- wait 5 seconds
- send "{@tag} &6Za 5 sekund bedziesz mogl niszczyc, a za 14 atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &6Za 5 sekund bedziesz mogl niszczyc, a za 14 atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &6Za 5 sekund bedziesz mogl niszczyc, a za 14 atakowac!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &6Za 5 sekund bedziesz mogl niszczyc, a za 14 atakowac!" to {microbattle.arena.team.yellow.players::*}
- wait 1 seconds
- send "{@tag} &6Za 4 sekund bedziesz mogl niszczyc, a za 13 atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &6Za 4 sekund bedziesz mogl niszczyc, a za 13 atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &6Za 4 sekund bedziesz mogl niszczyc, a za 13 atakowac!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &6Za 4 sekund bedziesz mogl niszczyc, a za 13 atakowac!" to {microbattle.arena.team.yellow.players::*}
- wait 1 seconds
- send "{@tag} &6Za 3 sekund bedziesz mogl niszczyc, a za 12 atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &6Za 3 sekund bedziesz mogl niszczyc, a za 12 atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &6Za 3 sekund bedziesz mogl niszczyc, a za 12 atakowac!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &6Za 3 sekund bedziesz mogl niszczyc, a za 12 atakowac!" to {microbattle.arena.team.yellow.players::*}
- wait 1 seconds
- send "{@tag} &6Za 2 sekund bedziesz mogl niszczyc, a za 11 atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &6Za 2 sekund bedziesz mogl niszczyc, a za 11 atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &6Za 2 sekund bedziesz mogl niszczyc, a za 11 atakowac!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &6Za 2 sekund bedziesz mogl niszczyc, a za 11 atakowac!" to {microbattle.arena.team.yellow.players::*}
- wait 1 seconds
- send "{@tag} &6Za 1 sekund bedziesz mogl niszczyc, a za 10 atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &6Za 1 sekund bedziesz mogl niszczyc, a za 10 atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &6Za 1 sekund bedziesz mogl niszczyc, a za 10 atakowac!" to {microbattle.arena.team.green.players::*}
- wait 1 seconds
- send "{@tag} &3Ruszaj! Atakowac mozesz za 10 sekund!" to {microbattle.arena.team.yellow.players::*}
- send "{@tag} &3Ruszaj! Atakowac mozesz za 10 sekund!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &3Ruszaj! Atakowac mozesz za 10 sekund!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &3Ruszaj! Atakowac mozesz za 10 sekund!" to {microbattle.arena.team.green.players::*}
- wait 10 seconds
- send "{@tag} &aMozesz juz atakowac!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &aMozesz juz atakowac!" to {microbattle.arena.team.yellow.players::*}
- send "{@tag} &aMozesz juz atakowac!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &aMozesz juz atakowac!" to {microbattle.arena.team.green.players::*}
- set {microbattle.arena.state} to true
- set {microbattle.attack} to true
- set {microbattle.build} to true
- if arg 1 is "leave":
- if {microbattle.state.%player%} is true:
- send "{@tag} &cOpusciles arene!"
- teleport player to {microbattle.main.lobby}
- remove player from {microbattle.arena.team.blue.players::*}
- remove player from {microbattle.arena.team.red.players::*}
- remove player from {microbattle.arena.team.green.players::*}
- remove player from {microbattle.arena.team.yellow.players::*}
- remove wooden sword from player
- else:
- send "{@tag} &cNie ma cie na arenie!"
- if arg 1 is "stats":
- set {_1} to "%{microbattle.%player%.win}%"
- set {_2} to "%{microbattle.%player%.lose}%"
- set {_3} to "%{microbattle.%player%.rozegrane}%"
- set {_4} to "%{microbattle.%player%.monety}%"
- replace all "<none>" with "0" in {_1}
- replace all "<none>" with "0" in {_2}
- replace all "<none>" with "0" in {_3}
- replace all "<none>" with "0" in {_4}
- send "&6Wygrane: &7%{_1}%"
- send "&6Przegrane: &7%{_2}%"
- send "&6Rozegrane: &7%{_3}%"
- send "&6Monety: &7%{_4}%"
- if arg 1 is "shop":
- execute console command "mbshop %player% shop"
- command /mbshop [<player>] [<text>]:
- executable by: console
- trigger:
- if arg 2 is "klasy":
- wait 2 tick
- open chest with 1 rows named "&eMicroBattle - klasy &7(1/1)" to player-arg
- wait 2 tick
- set {_none} to "&c%{microbattle.class.worker.state.%player-arg%}%"
- set {_true} to "&c%{microbattle.class.worker.state.%player-arg%}%"
- replace all "<none>" with "NIE ZAKUPIONE" in {_none}
- replace all "true" with "ZAKUPIONE" in {_true}
- format slot 0 of player-arg with 1 of stone pickaxe named "&2Klasa: &7Worker" with lore "&3&lCennik:||&a||&b* &2Gracz: &7100||&b* &6VIP: &780||&b* &3Super&6VIP: &770" to run "mbshop %player-arg% worker"
- format slot 1 of player-arg with 1 of bow named "&2Klasa: &7Archer" with lore "&3&lCennik:||&a||&b* &2Gracz: &7100||&b* &6VIP: &780||&b* &3Super&6VIP: &770" to run "mbshop %player-arg% archer"
- if arg 2 is "shop":
- wait 2 tick
- open chest with 1 rows named "&eMicroBattle - sklep &7(1/1)" to player-arg
- wait 2 tick
- format slot 0 of player-arg with 1 of nether star named "&6Sklep z klasami" to run "mbshop %player-arg% klasy"
- if arg 2 is "worker":
- if {microbattle.class.worker.state.buy.%player-arg%} is true:
- send "{@tag} &cZakupiles juz ta klase!" to player-arg
- else:
- if player-arg has permission "microbattle.buy.worker.gracz":
- if {microbattle.%player-arg%.monety} is greater or equal to 100:
- add -100 to {microbattle.%player-arg%.monety}
- send "{@tag} &aZakupiles klase &3WORKER&a!" to player-arg
- set {microbattle.class.worker.state.%player-arg%} to true
- set {microbattle.class.worker.state.buy.%player-arg%} to true
- else:
- send "{@tag} &cNie stac Cie!" to player-arg
- else if player-arg has permission "microbattle.buy.worker.vip":
- if {microbattle.%player-arg%.monety} is greater or equal to 80:
- add -80 to {microbattle.%player-arg%.monety}
- send "{@tag} &aZakupiles klase &3WORKER&a!" to player-arg
- set {microbattle.class.worker.state.%player-arg%} to true
- set {microbattle.class.worker.state.buy.%player-arg%} to true
- else if player-arg has permission "microbattle.buy.worker.svip":
- if {microbattle.%player-arg%.monety} is greater or equal to 70:
- add -70 to {microbattle.%player-arg%.monety}
- send "{@tag} &aZakupiles klase &3WORKER&a!" to player-arg
- set {microbattle.class.worker.state.%player-arg%} to true
- set {microbattle.class.worker.state.buy.%player-arg%} to true
- else:
- send "{@tag} &cNie masz uprawnien do tej czynnosci!"
- if arg 2 is "archer":
- if {microbattle.class.archer.state.buy.%player-arg%} is true:
- send "{@tag} &cZakupiles juz ta klase!" to player-arg
- else:
- if player-arg has permission "microbattle.buy.archer.gracz":
- if {microbattle.%player-arg%.monety} is greater or equal to 100:
- add -100 to {microbattle.%player-arg%.monety}
- send "{@tag} &aZakupiles klase &3ARCHER&a!" to player-arg
- set {microbattle.class.archer.state.%player-arg%} to true
- set {microbattle.class.archer.state.buy.%player-arg%} to true
- else:
- send "{@tag} &cNie stac Cie!" to player-arg
- else if player-arg has permission "microbattle.buy.archer.vip":
- if {microbattle.%player-arg%.monety} is greater or equal to 80:
- add -80 to {microbattle.%player-arg%.monety}
- send "{@tag} &aZakupiles klase &3ARCHER&a!" to player-arg
- set {microbattle.class.archer.state.%player-arg%} to true
- set {microbattle.class.archer.state.buy.%player-arg%} to true
- else if player-arg has permission "microbattle.buy.archer.svip":
- if {microbattle.%player-arg%.monety} is greater or equal to 70:
- add -70 to {microbattle.%player-arg%.monety}
- send "{@tag} &aZakupiles klase &3ARCHER&a!" to player-arg
- set {microbattle.class.archer.state.%player-arg%} to true
- set {microbattle.class.archer.state.buy.%player-arg%} to true
- else:
- send "{@tag} &cNie masz uprawnien do tej czynnosci!"
- on death:
- if attacker is player:
- if victim is player:
- if {microbattle.arena.state} is true:
- send "{@tag} &aGracz &6%attacker% &azabil gracza &6%victim%&a!" to {microbattle.arena.players::*}
- send "&a+4 monety!" to attacker
- send "{@tag} &cPrzegrales, wiec zostales przeteleportowany do glownego lobby!" to victim
- add 1 to {microbattle.%victim%.lose}
- add 4 to {microbattle.%attacker%.monety}
- remove player from {microbattle.arena.team.blue.players::*}
- add -1 to {microbattle.arena.team.blue.players::*}
- clear drops
- if {microbattle.arena.team.blue.players::*} is 0:
- send "{@tag} &cDruzyna &1BLUE &czostala pokonana!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &cDruzyna &1BLUE &czostala pokonana!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &cDruzyna &1BLUE &czostala pokonana!" to {microbattle.arena.team.yellow.players::*}
- delete {microbattle.arena.team.blue.players::*}
- delete {microbattle.team.blue}
- else if {microbattle.arena.team.green.players::*} is 0:
- send "{@tag} &cDruzyna &2GREEN &czostala pokonana!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &cDruzyna &2GREEN &czostala pokonana!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &cDruzyna &2GREEN &czostala pokonana!" to {microbattle.arena.team.yellow.players::*}
- delete {microbattle.arena.team.green.players::*}
- delete {microbattle.team.green}
- else if {microbattle.arena.team.red.players::*} is 0:
- send "{@tag} &cDruzyna &4RED &czostala pokonana!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &cDruzyna &4RED &czostala pokonana!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &cDruzyna &4RED &czostala pokonana!" to {microbattle.arena.team.yellow.players::*}
- delete {microbattle.arena.team.red.players::*}
- delete {microbattle.team.red}
- else if {microbattle.arena.team.yellow.players::*} is 0:
- send "{@tag} &cDruzyna &eYELLOW &czostala pokonana!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &cDruzyna &eYELLOW &czostala pokonana!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &cDruzyna &eYELLOW &czostala pokonana!" to {microbattle.arena.team.blue.players::*}
- delete {microbattle.arena.team.yellow.players::*}
- delete {microbattle.team.yellow}
- else if {microbattle.team.red} and {microbattle.team.blue} and {microbattle.team.green} and {microbattle.team.yellow} is 0:
- execute player command "mbres"
- on place:
- if {microbattle.build} is true:
- stop
- else:
- send "Nie mozesz budowac!"
- cancel event
- on break:
- if {microbattle.build} is true:
- stop
- else:
- send "Nie mozesz niszczyc!"
- cancel event
- on damage:
- if {microbattle.attack} is true:
- stop
- else:
- send "Nie mozesz jeszcze bic!"
- cancel event
- every 180 seconds:
- if {microbattle.arena.state} is true:
- send "{@tag} &4Koniec gry!" to {microbattle.arena.team.red.players::*}
- send "{@tag} &4Koniec gry!" to {microbattle.arena.team.blue.players::*}
- send "{@tag} &4Koniec gry!" to {microbattle.arena.team.green.players::*}
- send "{@tag} &4Koniec gry!" to {microbattle.arena.team.yellow.players::*}
- teleport {microbattle.arena.team.red.players::*} to {microbattle.main.lobby}
- teleport {microbattle.arena.team.blue.players::*} to {microbattle.main.lobby}
- teleport {microbattle.arena.team.green.players::*} to {microbattle.main.lobby}
- teleport {microbattle.arena.team.yellow.players::*} to {microbattle.main.lobby}
- set {microbattle.arena.state} to false
- #delete
- else:
- stop
- on rightclick with nether star:
- if name of player's tool is "&6Sklep":
- execute player command "mb shop"
- command /mbres:
- trigger:
- delete {microbattle.team.red}
- delete {microbattle.team.blue}
- delete {microbattle.team.yellow}
- delete {microbattle.team.green}
- delete {microbattle.arena.full.%arg 2%}
- send "Cleared!"
Advertisement
Add Comment
Please, Sign In to add comment