zYGlg6BD
Język: Skript
|
Autor: elo_elo
options: startowe-zycia: 3 koszt-zycia: 100 command /zycia [<offlineplayer>]: trigger: if arg 1 is not set: send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" send " &cPosiadasz &4&l%{zycia::%player%}% &cżycia!" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" if arg 1 is set: send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" send " &4&l%arg 1% &cposiada &4&l%{zycia::%arg 1%}% &cżyć!" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" command /buy:eliksirżycia: aliases: kup:eliksirżycia trigger: if player's balance >= {@koszt-zycia}: add potion named "&cEliksir Życia" to player's inventory remove {@koszt-zycia} from player's balance send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ELIKSIR &8«&c*&8»&8&m-----------&8«&c*&8»" send " &f&k&lX &c&lPomyślnie Zakupiłeś Eliksir Życia &f&k&lX" send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" else: send "&cNie stać cię na to! Potrzebujesz ${@koszt-zycia}" command /zycia:daj [<offlineplayer>] [<integer>]: permission: zycia.daj permission message: &cBrak uprawnień. trigger: add arg-2 to {zycia::%arg-1%} send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to player send " &cDodałeś &4&l%arg 2% &cżyć dla &4&l%arg 1%&c!" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to player unban arg-1 set {tablist::zycia::%arg-1%} to tabListFooter({zycia::%arg-1%}) command /zycia:set [<offlineplayer>] [<integer>]: permission: zycia.set permission message: &cBrak uprawnień. trigger: set {zycia::%arg 1%} to arg 2 send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" send " &cGracz &4&l%arg 1% &cma &c &4&l%arg 2% &cżyć" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" unban arg-1 set {tablist::zycia::%arg-1%} to tabListFooter({zycia::%arg-1%}) command /zycia:zabierz [<offlineplayer>] [<integer>]: permission: zycia.zabierz permission message: &cBrak uprawnień. trigger: remove arg 2 from {zycia::%arg 1%} send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" send " &cZabrałeś &4&l%arg 2% &4&lżyć &cod &4&l%arg 1%" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" unban arg-1 set {tablist::zycia::%arg-1%} to tabListFooter({zycia::%arg-1%}) command /dajzycie [<offlineplayer>] [<integer>]: trigger: if {zycia::%player%} <= arg 2: ban player due to "&cBrak żyć!" stop remove arg 2 from {zycia::%player%} add arg 2 to {zycia::%arg-1%} unban arg 1 send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to player send " &cDodałeś &4&l%arg 2% &cżyć dla Gracza &4&l%arg 1%&c!" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to arg 1 send " &cOtrzymałeś od &4&l%arg 1% &4&l%arg 2%&c żyć!" to arg 1 send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to arg 1 set {tablist::zycia::%player%} to tabListFooter({zycia::%player%}) set {tablist::zycia::%arg-1%} to tabListFooter({zycia::%arg-1%}) on consume: player is in world "world" or world "world_nether" or world "world_the_end" if player's tool is potion named "&cEliksir Życia": add 1 to {zycia::%player%} send "&cWypiłeś/as Eliksir Życia i Dodalo tobię życia" set {tablist::zycia::%player%} to tabListFooter({zycia::%player%}) wait 0.05 second execute console command "/execute run clear %player% minecraft:glass_bottle 1" on death of player: player is in world "world" or world "world_nether" or world "world_the_end" remove 1 from {zycia::%player%} set {tablist::zycia::%player%} to tabListFooter({zycia::%player%}) if {zycia::%player%} <= 0: kick player due to "&cBrak żyć! Wróć ponownie za 24 godziny" ban player due to "&cBrak żyć! Wróć ponownie za 24 godziny" for 24 hours on join: if {zycia::%player%} is not set: set {zycia::%player%} to {@startowe-zycia} if {zycia::%player%} <= 0: set {zycia::%player%} to {@startowe-zycia} set {tablist::zycia::%player%} to tabListFooter({zycia::%player%}) function tabListFooter(i: integer) :: string: {_i} > 0: loop {_i} times: if {_f} is not set: set {_f} to "&4❤" else: set {_f} to "%{_f}% ❤" return {_f} return " " command /eliksirżycia: trigger: send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ELIKSIR &8«&c*&8»&8&m-----------&8«&c*&8»" send "&8» &4Eliksir Życia Kosztuję 50$." send "&8» &4Aby kupić taki Eliksir trzeba wpisać komende: ." send "&8» &4 /buy:eliksiżycia ." send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" command /zycia:pomoc: trigger: send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&6*&8»&8&m-----------&8«&c*&8»" send "&8» &4/zycia:pomoc &8- &7Pokazuję komendy odnośnie żyć." send "&8» &4/dajzyc &8- &7Dajesz komuś życie." send "&8» &4/zycie &8- &7Informacje ile masz żyć." send "&8» &4/eliksirżycia &8- &7Informację na temat Eliksiru Życia." send "&8» &4/buy:eliksirżycia &8- &7Kupujesz Eliksir Życia." send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&6*&8»&8&m-----------&8«&c*&8»" if player has permission "script.admin": send "&8«&6*&8»&8&m--------&8«&6*&8»&c ADMIN POMOC &8«&6*&8»&8&m--------&8«&6*&8»" send "&4 /zycia:daj [Gracz] [Ilosć] &8- &7Dajesz Graczowi życia ." send "&4 /zycia:zabierz [Gracz] [Ilość] &8- &7Zabierasz Graczowi życia." send "&4 /zycia:reload &8- &7Przeładowujesz Skrypt." send "&4 /zycia:set [Gracz] [Ilosć] &8- &7Ustawiasz Graczowi Życia ." send "&8«&6*&8»&8&m--------&8«&6*&8»&c ADMIN POMOC &8«&6*&8»&8&m--------&8«&6*&8»" command /zycia:reload: trigger: if player has permission "daj.zycia": send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to player send "&4 &lSkript Został Przeładowany" to player send "&8«&c*&8»&8&m-----------&8«&c*&8»&c ŻYCIA &8«&c*&8»&8&m-----------&8«&c*&8»" to player execute console command "/sk reload zycia"