Ilom_uk

Rates (Updated)

Oct 13th, 2017
634
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 9.63 KB | None | 0 0
  1. #My rates skript, which has the ability to toggle oak-only and shears via COMMANDS! :) - Ilom
  2.  
  3. options:
  4. p: &8[&3Apple Rates&8]&r #Apple Rates
  5. p2: &8[&3Flint Rates&8]&r #Flint Rates
  6. p3: &8[&3Rates Options&8]&r #Rates Options
  7. perms: skript.op
  8. oakonly: true #set to true if only oak trees drop apples
  9. nerfshears: true #set to true to nerf so shears wont get you alot of apples
  10.  
  11. command /apples [<text>] [<int>]:
  12. permission: {@perms}
  13. aliases: /applerates, /arates, /appler
  14. usage: /apples [<set:reset>] [<rate (1-100)>]
  15. trigger:
  16. if arg-1 is "reset":
  17. broadcast "{@p} Apple Rates set to Vanilla"
  18. delete {rates::apples}
  19. loop all players:
  20. command "/playsound random.pop %loop-player% ~ ~ ~ 1 0.5 1"
  21. else if arg-1 is "set":
  22. if arg-2 is not set:
  23. send "{@p} You must specify a rate to set it to!" to command sender
  24. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  25. stop
  26. else if arg-2 is less than 0:
  27. send "{@p} No number lower than 0!" to command sender
  28. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  29. stop
  30. else if arg-2 is greater than 100:
  31. send "{@p} No number higher than 100!" to command sender
  32. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  33. stop
  34. set {rates::apples} to arg-2
  35. broadcast "{@p} Apple Rates set to %arg-2%%%"
  36. loop all players:
  37. command "/playsound random.pop %loop-player% ~ ~ ~ 1 0.5 1"
  38. else:
  39. if {rates::apples} is set:
  40. send "{@p} Current Apple Rates: %{rates::apples}%%%"
  41. else:
  42. send "{@p} Current Apple Rates: Vanilla"
  43. send "{@p} /apples [<set:reset>] [<rate (1-100)>]"
  44. command "/playsound random.explode %command sender% ~ ~ ~ 1 0.5 1"
  45.  
  46. command /flint [<text>] [<int>]:
  47. permission: {@perms}
  48. aliases: /flintrates, /flintr, /frates
  49. usage: /flintrates [<set:reset>] [<rate (1-100)>]
  50. trigger:
  51. if arg-1 is "reset":
  52. broadcast "{@p2} Flint Rates set to Vanilla"
  53. delete {rates::flint}
  54. loop all players:
  55. command "/playsound random.pop %loop-player% ~ ~ ~ 1 0.5 1"
  56. else if arg-1 is "set":
  57. if arg-2 is not set:
  58. send "{@p2} You must specify a rate to set it to!" to command sender
  59. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  60. stop
  61. else if arg-2 is less than 0:
  62. send "{@p2} No number lower than 0!" to command sender
  63. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  64. stop
  65. else if arg-2 is greater than 100:
  66. send "{@p} No number higher than 100!" to command sender
  67. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  68. stop
  69. set {rates::flint} to arg-2
  70. broadcast "{@p2} Flint Rates set to %arg-2%%%"
  71. loop all players:
  72. command "/playsound random.pop %loop-player% ~ ~ ~ 1 0.5 1"
  73. else:
  74. if {rates::flint} is set:
  75. send "{@p2} Current Flint Rates: %{rates::flint}%%%"
  76. else:
  77. send "{@p2} Current Flint Rates: Vanilla"
  78. send "{@p2} /flint [<set:reset>] [<rate (1-100)>]"
  79. command "/playsound random.break %command sender% ~ ~ ~ 1 0.5 1"
  80.  
  81. on break of gravel:
  82. event-player's gamemode is survival
  83. world is not "pvparena" or "spawn" or "musim"
  84. if {rates::flint} is not set:
  85. stop
  86. cancel the event
  87. set the event-block to air
  88. set {_chance} to a random integer between 1 and 100
  89. if {_chance} is between -1 and {rates::flint}:
  90. drop 1 flint at event-block
  91. else:
  92. drop 1 gravel at event-block
  93.  
  94. on leaves decay:
  95. world is not "pvparena" or "spawn" or "musim"
  96. if {rates::apples} is not set:
  97. stop
  98. cancel the event
  99. set the event-block to air
  100. chance of {rates::apples}%:
  101. drop 1 apple at event-block
  102. if event-block is oak leaves:
  103. chance of 5%
  104. drop 1 oak sapling at event-block
  105. else if event-block is spruce leaves:
  106. chance of 5%
  107. drop 1 spruce sapling at event-block
  108. else if event-block is birch leaves:
  109. chance of 5%
  110. drop 1 birch sapling at event-block
  111. else if event-block is jungle leaves:
  112. chance of 5%
  113. drop 1 jungle sapling at event-block
  114. else if event-block is acacia leaves:
  115. chance of 5%
  116. drop 1 acacia sapling at event-block
  117. else if event-block is dark oak leaves:
  118. chance of 5%
  119. drop 1 dark oak sapling at event-block
  120.  
  121. on break of leaves:
  122. event-player's gamemode is survival
  123. # world is not "pvparena" or "spawn" or "musim"
  124. if {rates::apples} is not set:
  125. stop
  126. if event-player is holding shears:
  127. {@nerfshears} is true
  128. stop
  129. if {@oakonly} is true:
  130. event-block is not oak leaves or dark oak leaves
  131. stop
  132. cancel the event
  133. set the event-block to air
  134. chance of {rates::apples}%:
  135. drop 1 apple at event-block
  136. if event-block is oak leaves:
  137. chance of 5%
  138. drop 1 oak sapling at event-block
  139. else if event-block is spruce leaves:
  140. chance of 5%
  141. drop 1 spruce sapling at event-block
  142. else if event-block is birch leaves:
  143. chance of 5%
  144. drop 1 birch sapling at event-block
  145. else if event-block is jungle leaves:
  146. chance of 5%
  147. drop 1 jungle sapling at event-block
  148. else if event-block is acacia leaves:
  149. chance of 5%
  150. drop 1 acacia sapling at event-block
  151. else if event-block is dark oak leaves:
  152. chance of 5%
  153. drop 1 dark oak sapling at event-block
  154.  
  155. command /rates [<text>] [<text>]:
  156. usage: /rates [<reset:oakonly:shears>] [<on:off>]
  157. trigger:
  158. player has the permission "{@perms}":
  159. if arg-1 is "reset":
  160. broadcast "{@p2} Flint & Apple Rates set to Vanilla"
  161. delete {rates::flint}
  162. delete {rates::apples}
  163. set {oakonly} to true
  164. set {nerfshears} to true
  165. loop all players:
  166. command "/playsound random.explode %loop-player% ~ ~ ~ 0.5 0.5 1"
  167. else if arg-1 is "oakonly":
  168. if arg-2 is "on":
  169. set {oakonly} to true
  170. broadcast "{@p3} Oak-only enabled! - Apples will now only drop from oak and dark oak trees!"
  171. loop all players:
  172. command "/playsound random.pop %loop-player% ~ ~ ~ 1 0.5 1"
  173. if arg-2 is "off":
  174. set {oakonly} to false
  175. broadcast "{@p3} Oak-only disabled! - Apples will now drop from all trees!"
  176. loop all players:
  177. command "/playsound random.pop %loop-player% ~ ~ ~ 0.5 0.5 1"
  178. else if arg-1 is "shears":
  179. if arg-2 is "on":
  180. set {nerfshears} to false
  181. broadcast "{@p3} Shears enabled! - Shearing leaves will now drop apples!"
  182. loop all players:
  183. command "/playsound random.pop %loop-player% ~ ~ ~ 1 0.5 1"
  184. if arg-2 is "off":
  185. set {nerfshears} to true
  186. broadcast "{@p3} Shears disabled! - Shearing leaves will no longer drop apples!"
  187. loop all players:
  188. command "/playsound random.pop %loop-player% ~ ~ ~ 0.5 0.5 1"
  189. else:
  190. command "/playsound random.pop %command sender% ~ ~ ~ 0.75 0.5 1"
  191. if {rates::flint} is set:
  192. send "{@p2} Current Flint Rates: %{rates::flint}%%%"
  193. else:
  194. send "{@p2} Current Flint Rates: Vanilla"
  195. wait for 1 tick
  196. send "{@p2} /flint [<set:reset>] [<rate (1-100)>]"
  197. if {rates::apples} is set:
  198. send "{@p} Current Apple Rates: %{rates::apples}%%%"
  199. else:
  200. send "{@p} Current Apple Rates: Vanilla"
  201. wait for 1 tick
  202. send "{@p} /apples [<set:reset>] [<rate (1-100)>]"
  203. if {oakonly} is true:
  204. send "{@p3} Oak-only apples are currently enabled!"
  205. else:
  206. send "{@p3} Oak only apples are currently disabled!"
  207.  
  208. if {nerfshears} is true:
  209. send "{@p3} Shears-nerf is currently enabled!"
  210. else:
  211. send "{@p3} Shears-nerf is currently disabled!"
  212.  
  213. player doesn't have permission "{@perms}":
  214. command "/playsound random.pop %command sender% ~ ~ ~ 0.75 0.5 1"
  215. if {rates::flint} is set:
  216. send "{@p2} Current Flint Rates: %{rates::flint}%%%"
  217. else:
  218. send "{@p2} Current Flint Rates: Vanilla"
  219. if {rates::apples} is set:
  220. send "{@p} Current Apple Rates: %{rates::apples}%%%"
  221. else:
  222. send "{@p} Current Apple Rates: Vanilla"
  223. if {oakonly} is true:
  224. send "{@p3} Oak-only apples are currently enabled!"
  225. else:
  226. send "{@p3} Oak-only apples are currently disabled!"
  227. if {nerfshears} is true:
  228. send "{@p3} Shears-nerf is currently enabled!"
  229. else:
  230. send "{@p3} Shears-nerf is currently disabled!"
  231.  
  232.  
  233. command /ratesinfo:
  234. aliases: /rinfo, /rateslist
  235. usage: /ratesinfo
  236. trigger:
  237. player has the permission "{@perms}":
  238. command "/playsound random.pop %command sender% ~ ~ ~ 0.75 0.5 1"
  239. if {rates::flint} is set:
  240. send "{@p2} Current Flint Rates: %{rates::flint}%%%"
  241. else:
  242. send "{@p2} Current Flint Rates: Vanilla"
  243. wait for 1 tick
  244. send "{@p2} /flint [<set:reset>] [<rate (1-100)>]"
  245. if {rates::apples} is set:
  246. send "{@p} Current Apple Rates: %{rates::apples}%%%"
  247. else:
  248. send "{@p} Current Apple Rates: Vanilla"
  249. wait for 1 tick
  250. send "{@p} /apples [<set:reset>] [<rate (1-100)>]"
  251. if {oakonly} is true:
  252. send "{@p3} Oak-only apples are currently enabled!"
  253. else:
  254. send "{@p3} Oak-only apples are currently disabled!"
  255. if {nerfshears} is true:
  256. send "{@p3} Shears-nerf is currently enabled!"
  257. else:
  258. send "{@p3} Shears-nerf is currently disabled!"
  259.  
  260. player doesn't have permission "{@perms}":
  261. command "/playsound random.pop %command sender% ~ ~ ~ 0.75 0.5 1"
  262. if {rates::flint} is set:
  263. send "{@p2} Current Flint Rates: %{rates::flint}%%%"
  264. else:
  265. send "{@p2} Current Flint Rates: Vanilla"
  266. if {rates::apples} is set:
  267. send "{@p} Current Apple Rates: %{rates::apples}%%%"
  268. else:
  269. send "{@p} Current Apple Rates: Vanilla"
  270. if {oakonly} is true:
  271. send "{@p3} Oak-only apples are currently enabled!"
  272. else:
  273. send "{@p3} Oak-only apples are currently disabled!"
  274. if {nerfshears} is true:
  275. send "{@p3} Shears-nerf is currently enabled!"
  276. else:
  277. send "{@p3} Shears-nerf is currently disabled!
Advertisement
Add Comment
Please, Sign In to add comment