Guest User

Untitled

a guest
Jul 19th, 2014
233
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.84 KB | None | 0 0
  1. variables:
  2. {pkt::%player%} = 1000
  3. {zabicia.%player%} = 0
  4. {zginiecia.%player%} = 0
  5. {walka.%player%} = false
  6. on script load:
  7. execute console command "scoreboard objectives add &aPunktow dummy"
  8. execute console command "scoreboard objectives setdisplay belowName &aPunktow"
  9. on script unload:
  10. execute console command "scoreboard objectives remove &aPunktow"
  11. on join:
  12. if {pkt::%player%} is not set:
  13. set {pkt.%player%} to 1000
  14. if {zabicia.%player%} is not set:
  15. set {zabicia.%player%} to 0
  16. if {zginiecia.%player%} is not set:
  17. set {zginiecia.%player%} to 0
  18. if {nick::%player%} is not set:
  19. set {nick::%player%} to uncolored display name of player
  20. execute console command "scoreboard players %player% set &aPunktow %{pkt::%player%}%"
  21. command /rs [<player>]:
  22. trigger:
  23. if arg 1 is set:
  24. if player has permission "pixelrank.rs.player":
  25. set {pkt::%arg 1%} to 1000
  26. execute console command "scoreboard players set %arg 1% &aPunktow %{pkt::%arg 1%}%"
  27. set {zginiecia.%arg 1%} to 0
  28. set {zabicia.%arg 1%} to 0
  29. send "&2Pomyslnie zresetowales statystyki gracza: &6%arg 1%!"
  30. else:
  31. send "&4Blad: &cNie masz uprawnien !"
  32. stop
  33. else:
  34. set {pkt::%player%} to 1000
  35. execute console command "scoreboard players set %player% &aPunktow %{pkt::%player%}%"
  36. set {zginiecia.%player%} to 0
  37. set {zabicia.%player%} to 0
  38. send "&2Pomyslnie zresetowales swoje statystyki !"
  39. on chat:
  40. broadcast "&8[&2%{pkt::%player%}%&8] &7%display name of player%: %message%"
  41. cancel event
  42. on death:
  43. if victim is player:
  44. if attacker is player:
  45. if {pkt.%victim%} is smaller than 999:
  46. strike lightning effect at the player
  47. add 1 to {kille.%attacker%}
  48. add 1 to {dedy.%victim%}
  49. add 5 to {pkt::%attacker%}
  50. set death message to "&6%victim% &czostal zabity przez: &6%attacker% &cz przedmiotu: &6%tool of attacker% &7(&a+58:&c-0&7)"
  51. execute console command "scoreboard players set %victim% &aPunktow %{pkt::%victim%}%"
  52. execute console command "scoreboard players set %attacker% &aPunktow %{pkt::%attacker%}%"
  53. else:
  54. strike lightning effect at the player
  55. add 1 to {kille.%attacker%}
  56. add 1 to {dedy.%victim%}
  57. set {_pktattacker} to {pkt::%victim%}*0.1
  58. add {_pktattacker} to {pkt::%attacker%}
  59. set {_pktvictim} to random integer between 30 and 50
  60. remove {_pktvictim} from {pkt::%victim%}
  61. set death message to "&6%victim% &czostal zabity przez: &6%attacker% &cz przedmiotu: &6%tool of attacker% &7(&a+%{_pktattacker}%&8:&c-%{_pktvictim}%&7)"
  62. execute console command "scoreboard players set %victim% &aPunktow %{pkt::%victim%}%"
  63. execute console command "scoreboard players set %attacker% &aPunktow %{pkt::%attacker%}%"
  64. else:
  65. strike lightning effect at the player
  66. add 1 to {dedy.%victim%}
  67. add -30 to {pkt.%victim%}
  68. set death message to "&6%victim% &czginal &7[&c-30&7]"
  69. execute console command "scoreboard players set %player% &aPunktow %{pkt::%victim%}%"
  70. command /ranking [<offlineplayer>]:
  71. trigger:
  72. if arg 1 is set:
  73. send "&7&l--------------------------------------------"
  74. send "&cGracz: &6%arg 1%"
  75. send "&cIlosc rankingu: &6%{pkt::%arg 1%}%"
  76. send "&cIlosc zabójstw: &6%{zabicia.%arg 1%}%"
  77. send "&cIlosc zgonów: &6%{zginiecia.%arg 1%}%"
  78. send "&7&l--------------------------------------------"
  79. else:
  80. send "&7&l--------------------------------------------"
  81. send "&cGracz: &6%player% &7&l "
  82. send "&cIlosc rankingu: &6%{pkt::%player%}% &7&l "
  83. send "&cIlosc zabójstw: &6%{zabicia.%player%}%&7&l "
  84. send "&cIlosc zgonów: &6%{zginiecia.%player%}%&7&l "
  85. send "&7&l--------------------------------------------"
  86. on right click with sword on player:
  87. send "&cRanking gracza: &6%clicked player% &cwynosi: &8[&2%{pkt::%clicked player%}%&8]"
  88. on damage:
  89. victim is player
  90. attacker is player:
  91. if {walka.%victim%} is true:
  92. if {walka.%attacker%} is true:
  93. stop
  94. else:
  95. set {walka.%victim%} to true
  96. set {walka.%attacker%} to true
  97. send "&cNie mozesz sie wylogowac poniewaz jestes podczas walki !" to the victim
  98. send "&cNie mozesz sie wylogowac poniewaz jestes podczas walki !" to the attacker
  99. wait 9 second
  100. set {walka.%victim%} to false
  101. set {walka.%attacker%} to false
  102. send "&aMozesz juz spokojnie sie wylogowac &b:)" to the victim
  103. send "&aMozesz juz spokojnie sie wylogowac &b:)" to the attacker
  104. stop
  105. else:
  106. set {walka.%victim%} to true
  107. set {walka.%attacker%} to true
  108. send "&cNie mozesz sie wylogowac poniewaz jestes podczas walki !" to the victim
  109. send "&cNie mozesz sie wylogowac poniewaz jestes podczas walki !" to the attacker
  110. wait 5 second
  111. set {walka.%victim%} to false
  112. set {walka.%attacker%} to false
  113. send "&aMozesz juz spokojnie sie wylogowac &b:)" to the victim
  114. send "&aMozesz juz spokojnie sie wylogowac &b:)" to the attacker
  115. stop
  116. command /top [<integer=1>]:
  117. trigger:
  118. set {_strony} to rounded up (size of {pkt::*} / 5)
  119. arg is between 1 and {_strony}:
  120. send "&8&l====&6Ranking top rank&8&l===="
  121. loop {stone::*}:
  122. set {_lista::%loop-index%} to loop-value
  123. set {_num} to size of {_lista::*}
  124. set {_max} to arg * 5
  125. set {_min} to {_max} - 4
  126. loop {_max} times:
  127. loop {_lista::*}:
  128. {_wartosc.%loop-number%} is not set:
  129. set {_wartosc.%loop-number%} to loop-value
  130. set {_nazwa.%loop-number%} to loop-index
  131. loop-value is more than {_wartosc.%loop-number%}:
  132. set {_wartosc.%loop-number%} to loop-value
  133. set {_nazwa.%loop-number%} to loop-index
  134. remove {_wartosc.%loop-number%} from {_lista::*}
  135. loop {_max} times:
  136. loop-number is between {_min} and {_max}
  137. loop-number <= {_num}:
  138. send "&8%loop-number%. &7%{nick::%{_nazwa.%loop-number%}%}% &2(%{_wartosc.%loop-number%}%)"
  139. {_max} is more than {_num}:
  140. set {_r} to {_num}
  141. loop {_max} - {_num} times:
  142. add 1 to {_r}
  143. send "&8%{_r}%. &7Brak gracz na tym miejscu"
  144. send "Strona: %arg% z %{_strony}%"
  145. stop
  146. {_strony} is 1:
  147. send "Wyniki mieszcza sie na 1 stronie."
  148. stop
  149. send "Wyniki mieszcza sie na %{_strony}% stronach."
  150. on quit:
  151. if {walka.%player%} is true:
  152. strike lightning effect at the player
  153. add 1 to {dedy.%player%}
  154. add -40 to {pkt::%player%}
  155. broadcast "&6%player% &clognol podczas walki &7[&c40&7]"
  156. execute console command "scoreboard players set %player% &aPunktow %{pkt::%player%}%"
  157. every 15 second:
  158. loop all players:
  159. execute console command "scoreboard players set %loop-player% &aPunktow %{pkt::%loop-player%}%"
  160. set {_packet::*} to "PacketPlayOutPlayerInfo", "%loop-players%", false and 0
  161. loop-player.sendPacket{{_packet::*}};
  162. set {_packet::*} to "PacketPlayOutPlayerInfo", "&2mc&7.&4pixel&7.&1net", true and 0
  163. loop-player.sendPacket{{_packet::*}};
  164. on command:
  165. if {walka.%player%} is true:
  166. cancel event
  167. else:
  168. stop
Advertisement
Add Comment
Please, Sign In to add comment