Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command /statystyki [<text>] [<integer=1>]:
- aliases: staty
- trigger:
- if arg 1 is not set:
- send "&3/staty stone - &cTOP 5. Wykopanego &8stone/cobblestone &cna serwerze!"
- send "&3/staty diamenty - &cTOP 5. Zdobytych &8diamentow &cna serwerze!"
- stop
- if arg 1 is "stone":
- set {_strony} to rounded up (size of {stone::*} / 5)
- arg 2 is between 1 and {_strony}:
- send "&a| &9Ranking kopaczy &a|"
- loop {stone::*}:
- set {_lista::%loop-index%} to loop-value
- set {_num} to size of {_lista::*}
- set {_max} to arg 2 * 5
- set {_min} to {_max} - 4
- loop {_max} times:
- loop {_lista::*}:
- {_wartosc.%loop-number%} is not set:
- set {_wartosc.%loop-number%} to loop-value
- set {_nazwa.%loop-number%} to loop-index
- loop-value is more than {_wartosc.%loop-number%}:
- set {_wartosc.%loop-number%} to loop-value
- set {_nazwa.%loop-number%} to loop-index
- remove {_wartosc.%loop-number%} from {_lista::*}
- loop {_max} times:
- loop-number is between {_min} and {_max}
- loop-number <= {_num}:
- send "&6%loop-number%&7. &e&l%{nick::%{_nazwa.%loop-number%}%}% &e(&c%{_wartosc.%loop-number%}%&e)"
- {_max} is more than {_num}:
- set {_r} to {_num}
- loop {_max} - {_num} times:
- add 1 to {_r}
- send "%{_r}%. brak"
- send "&9Strona: &e%arg 2% &9z &e%{_strony}%"
- stop
- {_strony} is 1:
- send "&9Wyniki mieszcza sie na &e1 &9stronie."
- stop
- send "&9Wyniki mieszcza sie na &e%{_strony}% &9stronach."
- if arg 1 is "diamenty" or "diaxy":
- set {_strony} to rounded up (size of {diamenty::*} / 5)
- arg 2 is between 1 and {_strony}:
- send "&a| &9Ranking kopaczy diamentow &a|"
- loop {diamenty::*}:
- set {_lista::%loop-index%} to loop-value
- set {_num} to size of {_lista::*}
- set {_max} to arg 2 * 5
- set {_min} to {_max} - 4
- loop {_max} times:
- loop {_lista::*}:
- {_wartosc.%loop-number%} is not set:
- set {_wartosc.%loop-number%} to loop-value
- set {_nazwa.%loop-number%} to loop-index
- loop-value is more than {_wartosc.%loop-number%}:
- set {_wartosc.%loop-number%} to loop-value
- set {_nazwa.%loop-number%} to loop-index
- remove {_wartosc.%loop-number%} from {_lista::*}
- loop {_max} times:
- loop-number is between {_min} and {_max}
- loop-number <= {_num}:
- send "&6%loop-number%&7. &e&l%{nick::%{_nazwa.%loop-number%}%}% &e(&c%{_wartosc.%loop-number%}%&e)"
- {_max} is more than {_num}:
- set {_r} to {_num}
- loop {_max} - {_num} times:
- add 1 to {_r}
- send "%{_r}%. brak"
- send "&9Strona: &e%arg 2% &9z &e%{_strony}%"
- stop
- {_strony} is 1:
- send "&9Wyniki mieszcza sie na &e1 &9stronie."
- stop
- send "&9Wyniki mieszcza sie na &e%{_strony}% &9stronach."
- #
- on join:
- {diamenty::%player%} is not set:
- set {diamenty::%player%} to 0
- {stone::%player%} is not set:
- set {stone::%player%} to 0
- {nick::%player%} is not set:
- set {nick::%player%} to uncolored display name of player
- {wejscia::%player%} is not set:
- set {wejscia::%player%} to 1
- send "&6To juz twoje %{wejscia::%player%}% wejscie!"
- on mine of a stone or a cobblestone:
- add 1 to {stone::%player%}
Advertisement
Add Comment
Please, Sign In to add comment