NoHacksJustACow

Levelup | CowsFarm

Feb 17th, 2019
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.80 KB | None | 0 0
  1. variables:
  2. {levels::%player%} = 0
  3. {mutechat} = true
  4.  
  5. command /mutechat:
  6. permission: mod
  7. permission message: &e&l* &7You must be &e&lMOD &7or higher to use this command!
  8. trigger:
  9. if {mutechat} is true:
  10. set {mutechat} to false
  11. broadcast " "
  12. broadcast "&c&lCowNetwork &8:: &e%player% &7muted the chat"
  13. broadcast " "
  14. else:
  15. set {mutechat} to true
  16. broadcast " "
  17. broadcast "&c&lCowNetwork &8:: &e%player% &7unmuted the chat"
  18. broadcast " "
  19.  
  20. on chat:
  21. cancel event
  22. if {mutechat} is false:
  23. if player does not have permission "mod":
  24. send "&e&l* &7Chat is muted!"
  25. else:
  26. broadcast "&8[&cLvl&0.&c%{levels::%player's uuid%}%&8] &7%player's display name% &6» &7%message%"
  27. if {mutechat} is true:
  28. broadcast "&8[&cLvl&0.&c%{levels::%player's uuid%}%&8] &7%player's display name% &6» &7%message%"
  29.  
  30. every tick in "CowClicks":
  31. loop all players:
  32. if {levels::%loop-player's uuid%} is not set:
  33. set {levels::%loop-player's uuid%} to 0
  34.  
  35. command /toplevel:
  36. aliases: /levels
  37. trigger:
  38. loop {Levels::*}:
  39. add 1 to {_size}
  40. if {_low.to.high.list::%loop-value%} is not set:
  41. set {_low.to.high.list::%loop-value%} to loop-index
  42. else:
  43. set {_n} to 0
  44. loop {_size} times:
  45. set {_n} to {_n}+1
  46. {_low.to.high.list::%loop-value-1%.%{_n}%} is not set
  47. set {_low.to.high.list::%loop-value-1%.%{_n}%} to loop-index
  48. stop loop
  49. wait 1 tick
  50. set {_n} to size of {_low.to.high.list::*}
  51. loop {_low.to.high.list::*}:
  52. set {_high.to.low.list::%{_n}%} to loop-value
  53. set {_n} to {_n}-1
  54. wait 1 tick
  55. set {_i} to 0
  56. send "&7&m-----------&8< &6Top10 &8>&7&m-----------"
  57. loop {_high.to.low.list::*}:
  58. add 1 to {_topnumber}
  59. set {_player} to "%loop-value%" parsed as offlineplayer
  60. send "&7%{_topnumber}% - &c%{_player}% &8» &7Level %{Levels::%loop-value%}%"
  61. add 1 to {_i}
  62. if {_topnumber} > 9: #this is top 10 you can change it
  63. stop
  64. send "&7&m------------------------------"
  65.  
  66. command /levelup:
  67. aliases: /rankup
  68. trigger:
  69. if {levels::%player's uuid%} <= 9:
  70. if player's balance is greater than or equal to 1000000:
  71. remove 1000000 from player's balance
  72. add 1 to {levels::%player's uuid%}
  73. add 1 to {totallvl::%player's uuid%}
  74. send "&7You bought 1 Level for &a&l$1M"
  75. else:
  76. set {_amount} to 1000000 - player's balance
  77. send ""
  78. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  79. send ""
  80. stop
  81. if {levels::%player's uuid%} >= 10:
  82. if {levels::%player's uuid%} <= 19:
  83. if player's balance is greater than or equal to 1200000:
  84. remove 1200000 from player's balance
  85. add 1 to {levels::%player's uuid%}
  86. add 1 to {totallvl::%player's uuid%}
  87. send "&7You bought 1 Level for &a&l$1.2M"
  88. else:
  89. set {_amount} to 1200000 - player's balance
  90. send ""
  91. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  92. send ""
  93. stop
  94. if {levels::%player's uuid%} >= 20:
  95. if {levels::%player's uuid%} <= 29:
  96. if player's balance is greater than or equal to 1400000:
  97. remove 1400000 from player's balance
  98. add 1 to {levels::%player's uuid%}
  99. add 1 to {totallvl::%player's uuid%}
  100. send "&7You bought 1 Level for &a&l$1.4M"
  101. else:
  102. set {_amount} to 1400000 - player's balance
  103. send ""
  104. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  105. send ""
  106. stop
  107. if {levels::%player's uuid%} >= 30:
  108. if {levels::%player's uuid%} <= 39:
  109. if player's balance is greater than or equal to 1600000:
  110. remove 1600000 from player's balance
  111. add 1 to {levels::%player's uuid%}
  112. add 1 to {totallvl::%player's uuid%}
  113. send "&7You bought 1 Level for &a&l$1.4M"
  114. else:
  115. set {_amount} to 1600000 - player's balance
  116. send ""
  117. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  118. send ""
  119. stop
  120. if {levels::%player's uuid%} >= 30:
  121. if {levels::%player's uuid%} <= 39:
  122. if player's balance is greater than or equal to 1600000:
  123. remove 1600000 from player's balance
  124. add 1 to {levels::%player's uuid%}
  125. add 1 to {totallvl::%player's uuid%}
  126. send "&7You bought 1 Level for &a&l$1.6M"
  127. else:
  128. set {_amount} to 1600000 - player's balance
  129. send ""
  130. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  131. send ""
  132. stop
  133. if {levels::%player's uuid%} >= 40:
  134. if {levels::%player's uuid%} <= 49:
  135. if player's balance is greater than or equal to 1800000:
  136. remove 1800000 from player's balance
  137. add 1 to {levels::%player's uuid%}
  138. add 1 to {totallvl::%player's uuid%}
  139. send "&7You bought 1 Level for &a&l$1.8M"
  140. else:
  141. set {_amount} to 1800000 - player's balance
  142. send ""
  143. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  144. send ""
  145. stop
  146. if {levels::%player's uuid%} >= 50:
  147. if {levels::%player's uuid%} <= 59:
  148. if player's balance is greater than or equal to 2000000:
  149. remove 2000000 from player's balance
  150. add 1 to {levels::%player's uuid%}
  151. add 1 to {totallvl::%player's uuid%}
  152. send "&7You bought 1 Level for &a&l$2M"
  153. else:
  154. set {_amount} to 2000000 - player's balance
  155. send ""
  156. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  157. send ""
  158. stop
  159. if {levels::%player's uuid%} >= 60:
  160. if {levels::%player's uuid%} <= 69:
  161. if player's balance is greater than or equal to 2200000:
  162. remove 2200000 from player's balance
  163. add 1 to {levels::%player's uuid%}
  164. add 1 to {totallvl::%player's uuid%}
  165. send "&7You bought 1 Level for &a&l$2.2M"
  166. else:
  167. set {_amount} to 2200000 - player's balance
  168. send ""
  169. send "&7You need &c%{_amount}% &7More &a$$$ &7To levelup"
  170. send ""
  171. stop
  172.  
  173.  
  174.  
  175. command /setlevel [<offlineplayer>] [<number>]:
  176. permission: staff.lollol
  177. trigger:
  178. if arg-1 is set:
  179. if arg-2 is set:
  180. set {levels::%arg-1's uuid%} to arg-2
  181. send "&7You set &c%arg-1%'s levels to &c%arg-2%"
  182. if arg-1 is not set:
  183. send "&c/setlevel <player> <number>"
Advertisement
Add Comment
Please, Sign In to add comment