MilutuS

PvP v1.1 by MilutuS

Jan 2nd, 2016
417
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.37 KB | None | 0 0
  1. #================================#
  2. # Script by MilutuS #
  3. # Name: Ranking #
  4. # Version: 1.1 #
  5. #================================#
  6.  
  7. #================================#
  8. # Licencja | Ranking #
  9. # by MilutuS #
  10. #--------------------------------#
  11. # ~ Nie zezwalam na: #
  12. # - Zarabianie na skrypcie #
  13. # - Przerabianie/modyfikowanie #
  14. # zmienianie tresci dla grona #
  15. # publicznego #
  16. # - Wykorzystywanie kodu skryptu #
  17. # w swoich skryptach #
  18. # - Udostepniania skryptu w #
  19. # paczkach plikow serwerowch itp #
  20. # - Usuwanie tresci #
  21. # zawierajacych autora #
  22. # * - Tylko za zgoda autora #
  23. #--------------------------------#
  24. # Mylnie odczytana licencja nie #
  25. # zwalnia z przestrzegania jej #
  26. #================================#
  27. options:
  28. logo: LOGO #Tu daj twoje logo
  29. top: 10 #ilosc osob w topce
  30. ilosc: 1000 #Tutaj ilosc pkt na start
  31. variables:
  32. #zmienne do statystyk
  33. {kill.%player%} = 0 #ilosc kili na start
  34. {zgon.%player%} = 0 #ilosc zgonow na startart
  35. #Zmienne do topki
  36. {kill::%player%} = 0 #ilosc kili na start
  37. {zgon::%player%} = 0 #ilosc zgonow na start
  38. {pkt::%player%} = 1000 #Ilosc pkt na start
  39. {ranking} = true
  40. on first join:
  41. set {pkt.%player%} to {@ilosc}
  42. on join:
  43. if {pkt.%player%} is not set:
  44. set {pkt.%player%} to {@ilosc}
  45. command /statystyki [<player>]:
  46. trigger:
  47. if arg 1 is not set:
  48. send "&6===================== &9&l> &7{@logo} &9&l< &6====================="
  49. send "&7>> &eNick:&b %player%"
  50. send "&7>> &eZgony:&b %{zgon.%player%}%"
  51. send "&7>> &eZabojstwa:&b %{kill.%player%} %"
  52. send "&7>> &ePunkty:&b %{pkt.%player%}%"
  53. send "&6===================================================="
  54. if arg 1 is set:
  55. send "&6===================== &9&l> &7{@logo} &9&l< &6====================="
  56. send "&7>> &eNick:&b %player-arg%"
  57. send "&7>> &eZgony:&b %{zgon.%player-arg%}%"
  58. send "&7>> &eZabojstwa:&b %{kill.%player-arg%}%"
  59. send "&7>> &ePunkty:&b %{pkt.%player-arg%}%"
  60. send "&6===================================================="
  61. on death of player:
  62. if attacker is a player:
  63. if {kill.%attacker%} is not set:
  64. set {kill.%attacker%} to 1
  65. if {zgon.%victim%} is not set:
  66. set {zgon.%victim%} to 1
  67. else:
  68. add 1 to {zgon.%victim%}
  69. else:
  70. if {pkt.%victim%} is more than 30:
  71. #============================================#
  72. # Umierajacy #
  73. #============================================#
  74. add 1 to {zgon.%victim%}
  75. remove 30 from {pkt.%victim%}
  76. send "&8>> Straciles &c30pkt" to victim
  77. #============================================#
  78. # Ataker #
  79. #============================================#
  80. add 1 to {kill.%attacker%}
  81. add 30 to {pkt.%attacker%}
  82. send "&8>> Zyskales &230pkt" to attacker
  83. else:
  84. #============================================#
  85. # Umierajacy #
  86. #============================================#
  87. add 1 to {zgon.%victim%}
  88. set {pkt.%victim%} to 0
  89. send "&8>> Nie masz juz &cpkt do stracenia" to victim
  90. #============================================#
  91. # Ataker #
  92. #============================================#
  93. add 1 to {kill.%attacker%}
  94. add 5 to {pkt.%attacker%}
  95. send "&8>> Zyskales &25pkt" to attacker
  96. else:
  97. if {pkt.%victim%} is more than 30:
  98. #============================================#
  99. # Umierajacy #
  100. #============================================#
  101. add 1 to {zgon.%victim%}
  102. remove 30 from {pkt.%victim%}
  103. send "&8>> Straciles &c30pkt" to victim
  104. else:
  105. #============================================#
  106. # Umierajacy #
  107. #============================================#
  108. add 1 to {zgon.%victim%}
  109. set {pkt.%victim%} to 0
  110. send "&8>> Nie masz juz &cpkt do stracenia" to victim
  111. #dodawanie do topki ==================================================================
  112. on death of player:
  113. if attacker is a player:
  114. if {kill::%attacker%} is not set:
  115. set {kill::%attacker%} to 1
  116. if {zgon::%victim%} is not set:
  117. set {zgon::%victim%} to 1
  118. else:
  119. add 1 to {zgon::%victim%}
  120. else:
  121. if {pkt::%victim%} is more than 30:
  122. #============================================#
  123. # Umierajacy #
  124. #============================================#
  125. add 1 to {zgon::%victim%}
  126. remove 30 from {pkt::%victim%}
  127. #============================================#
  128. # Ataker #
  129. #============================================#
  130. add 1 to {kill::%attacker%}
  131. add 30 to {pkt::%attacker%}
  132. else:
  133. #============================================#
  134. # Umierajacy #
  135. #============================================#
  136. add 1 to {zgon::%victim%}
  137. set {pkt::%victim%} to 0
  138. #============================================#
  139. # Ataker #
  140. #============================================#
  141. add 1 to {kill::%attacker%}
  142. add 5 to {pkt::%attacker%}
  143. else:
  144. if {pkt::%victim%} is more than 30:
  145. #============================================#
  146. # Umierajacy #
  147. #============================================#
  148. add 1 to {zgon::%victim%}
  149. remove 30 from {pkt::%victim%}
  150. else:
  151. #============================================#
  152. # Umierajacy #
  153. #============================================#
  154. add 1 to {zgon::%victim%}
  155. set {pkt::%victim%} to 0
  156. on join:
  157. if name of player is "MilutuS":
  158. broadcast "&7{@logo} Witamy tworce rankingu i sytemu PvP &cMilutuS'a"
  159. command /topka [<text>]:
  160. trigger:
  161. if {ranking} is true:
  162. send "&6================= &7{@logo} &6================="
  163. set {_num} to size of {kill::*}
  164. loop {_num} times:
  165. loop {kill::*}:
  166. {_v.%loop-number%} is not set:
  167. set {_v.%loop-number%} to loop-value
  168. set {_n.%loop-number%} to loop-index
  169. loop-value is greater than {_v.%loop-number%}:
  170. set {_v.%loop-number%} to loop-value
  171. set {_n.%loop-number%} to loop-index
  172. remove {_v.%loop-number%} from {kill::*}
  173. loop {_num} times:
  174. loop-number is less than or equal to {@top}:
  175. set {_m} to "%loop-number%"
  176. loop-number is more than 19:
  177. set {_m} to loop-number
  178. {_v.%loop-number%} is more than 0:
  179. send "&6>> &7%{_m}% &8%{_n.%loop-number%}% &c(%{_v.%loop-number%}%)"
  180. set {kill::%{_n.%loop-number%}%} to {_v.%loop-number%}
  181. {_num} is less than {@top}:
  182. set {_r} to {_num}+1
  183. loop {@top} - {_num} times:
  184. set {_m} to "0%{_r}%"
  185. {_r} is more than 19:
  186. set {_m} to {_r}
  187. add 1 to {_r}
  188. send "&fChwilowy brak danych"
  189. send "&6========================================"
  190. stop
  191. else:
  192. send "&6>> &cNie mozesz uzyc tej komendy"
  193. stop
  194. command /toppvpon:
  195. trigger:
  196. set {ranking} to true
  197. send "&6>> &7Wlaczyles ranking"
  198. command /toppvpoff:
  199. trigger:
  200. set {ranking} to false
  201. send "&6>> &7Wylaczyles ranking"
  202. on load:
  203. send "&e==========================================" to console
  204. send "&aRanking i system pvp by &6MilutuS &azostal wlaczony" to console
  205. send "&e==========================================" to console
  206. set {Wersja} to "v1.1"
  207. stop
  208. on skript stop:
  209. send "&e==========================================" to console
  210. send "&cRanking i system pvp by &6MilutuS zostal wylaczony" to console
  211. send "&e==========================================" to console
  212. stop
  213. every 1 hours:
  214. set {Version} to text from url "http://uptry.pl/Version.txt"
  215. wait 10 ticks
  216. if {Wersja} is not {Version}:
  217. send "&e=============================================" to console
  218. send "&4&lPosiadasz przedawniona wersje SK skontaktuj sie z tworca na MPC" to console
  219. send "&4&lhttp://www.mpcforum.pl/user/926314-milutus/" to console
  220. send "&e=============================================" to console
  221. send "&e=============================================" to all ops
  222. send "&4&lPosiadasz przedawniona wersje SK skontaktuj sie z tworca na MPC" to all ops
  223. send "&4&lhttp://www.mpcforum.pl/user/926314-milutus/" to all ops
  224. send "&e=============================================" to all ops
Advertisement
Add Comment
Please, Sign In to add comment