Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- options:
- nazwa_pisanki: &aP&bi&cs&da&en&2k&3a
- szansa_pisanka: 20%
- typ_krolika: sheep
- nazwa_krolika: Krolik
- rozmiar_rankingu: 10
- on join:
- if {pisanki::%player%} is not set:
- set {pisanki::%player%} to 0
- on mine of stone:
- chance of {@szansa_pisanka}:
- drop egg named "{@nazwa_pisanki}" at event-block
- send "&aZnalazles pisanke. Oddaj ja krolikowi!"
- command /pisanki [<offlineplayer=%player%>]:
- trigger:
- if player has permissions "pisanka.sprawdz":
- if arg is player:
- send "&aDo tej pory znalazles i wymieniles &c%{pisanki::%player%}%&a pisanek."
- set {_top::*} to sorted {pisanki::*} from highest to lowest with output "&aNajwiecej pisanek wymienil gracz &6@index&a."
- loop {_top::*}:
- send "%loop-value%"
- stop
- else:
- if player has permissions "pisanka.sprawdz.others":
- if {pisanki::%argument%} is set:
- send "&aDo tej pory gracz &6%argument% &aznalazl i wymienil &c%{pisanki::%argument%}%&a pisanek."
- set {_top::*} to sorted {pisanki::*} from highest to lowest with output "&aNajwiecej pisanek wymienil gracz &6@index&a."
- loop {_top::*}:
- send "%loop-value%"
- stop
- else:
- send "&cTen gracz nie zbiera pisanek!"
- stop
- else:
- send "&cNie masz uprawnien do tej komendy."
- stop
- else:
- send "&cNie masz uprawnien do tej komendy."
- stop
- on rightclick on {@typ_krolika}:
- if name of event-entity is "{@nazwa_krolika}":
- cancel event
- set {_pisanki} to number of all egg named "{@nazwa_pisanki}" in player's inventory
- if {_pisanki} is 0:
- send "&cNie masz zadnych pisanek. Wroc do mnie kiedy jakies znajdziesz."
- stop
- else:
- remove all egg named "{@nazwa_pisanki}" from player
- add {_pisanki} to {pisanki::%player%}
- send "&aOddales &c%{_pisanki}% &apisanek krolikowi."
- on damage of {@typ_krolika}:
- if name of victim is "{@nazwa_krolika}":
- if attacker is a player:
- cancel event
- set {_pisanki} to number of all egg named "{@nazwa_pisanki}" in attacker's inventory
- if {_pisanki} is 0:
- send "&cNie masz zadnych pisanek. Wroc do mnie kiedy jakies znajdziesz." to attacker
- stop
- else:
- remove all egg named "{@nazwa_pisanki}" from attacker
- add {_pisanki} to {pisanki::%attacker%}
- send "&aOddales &c%{_pisanki}% &apisanek krolikowi." to attacker
- command /krolik [<text="przywolaj">] [<text>]:
- trigger:
- if player has permissions "krolik.sk":
- if arg 1 is "przywolaj":
- spawn a {@typ_krolika} at player
- apply slowness 200 to last spawned entity for 9999999 seconds
- set name of last spawned entity to "{@nazwa_krolika}"
- send "&aPrzywolales krolika."
- if arg 1 is "usun":
- if arg 2 is "all":
- loop all {@typ_krolika}s:
- if name of loop-entity is "{@nazwa_krolika}":
- kill loop-entity
- send "&aWszystkie kroliki zostaly usuniete."
- stop
- else if arg 2 is not set:
- if targeted entity is a {@typ_krolika}:
- if name of targeted entity is "{@nazwa_krolika}":
- kill targeted entity
- send "&aUsunieto wybranego krolika."
- stop
- else:
- send "&cTo nie jest krolik!"
- stop
- else:
- send "&cTo nie jest krolik!"
- stop
- else:
- send "&cNie masz uprawnien do tej komendy."
- stop
- on death of {@typ_krolika}:
- if name of victim is "{@nazwa_krolika}":
- clear drops
- command /pisankitop:
- aliases: ptop
- trigger:
- send "&3Ranking zbieraczy pisanek:"
- set {_top::*} to sorted {pisanki::*} from highest to lowest with output "&6@index &7- &6@value"
- set {_rank} to 1
- loop {_top::*}:
- set {_pisanki} to loop-value
- replace all ".0" with "" in {_pisanki}
- send "&c%loop-index%. %{_pisanki}%"
- add 1 to {_rank}
- if {_rank} is more than {@rozmiar_rankingu}:
- stop
- if {_pisanki} is 0:
- stop
Add Comment
Please, Sign In to add comment