Organized

VeinMiner & GraveRobbers [SK]

Mar 18th, 2017
743
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.28 KB | None | 0 0
  1. command /veinminer <text>:
  2. permission: skript.op
  3. trigger:
  4. if arg 1 is "on":
  5. set {scenario::veinminer} to true
  6. send "&aEnabled"
  7. else if arg 1 is "off":
  8. delete {scenario::veinminer}
  9. send "&cDisabled"
  10.  
  11. on mine of coal ore:
  12. {scenario::veinminer} is true
  13. player is sneaking
  14. loop blocks in radius 4 around event-block:
  15. loop-block is equal to coal ore
  16. set loop-block to air
  17. if player has space for (1 of coal):
  18. give player (1 coal)
  19. else:
  20. drop (1 of coal ore) at (location 0.5 above player)
  21. drop 3 xp at player
  22. play "DIG_STONE" specifically to player with pitch 1 and volume 1.0
  23. wait 1 ticks
  24.  
  25. on mine of iron ore:
  26. {scenario::veinminer} is true
  27. player is sneaking
  28. loop blocks in radius 3 around event-block:
  29. loop-block is equal to iron ore
  30. set loop-block to air
  31. if {scenario::cutclean} is true:
  32. set {_block} to iron ingot
  33. drop 3 xp at player
  34. else:
  35. set {_block} to iron ore
  36. if player has space for (1 of {_block}):
  37. give player (1 of {_block})
  38. else:
  39. drop (1 of {_block}) at (location 0.5 above player)
  40. play "DIG_STONE" specifically to player with pitch 1 and volume 1.0
  41. wait 1 ticks
  42.  
  43. on mine of gold ore:
  44. {scenario::veinminer} is true
  45. player is sneaking
  46. loop blocks in radius 2 around event-block:
  47. loop-block is equal to gold ore
  48. set loop-block to air
  49. if {scenario::cutclean} is true:
  50. set {_block} to gold ingot
  51. drop 4 xp at player
  52. else:
  53. set {_block} to gold ore
  54. if player has space for (1 of {_block}):
  55. give player (1 of {_block})
  56. else:
  57. drop (1 of {_block}) at (location 0.5 above player)
  58. play "DIG_STONE" specifically to player with pitch 1 and volume 1.0
  59. wait 1 tick
  60.  
  61. on mine of lapis lazuli ore:
  62. {scenario::veinminer} is true
  63. player is sneaking
  64. loop blocks in radius 2 around event-block:
  65. loop-block is equal to lapis lazuli ore
  66. set loop-block to air
  67. if player has space for (6 of lapis lazuli):
  68. give player (6 of lapis lazuli)
  69. else:
  70. drop (6 of lapis lazuli) at (location 0.5 above player)
  71. drop 4 xp at player
  72. play "DIG_STONE" specifically to player with pitch 1 and volume 1.0
  73. wait 1 ticks
  74.  
  75. on mine of redstone ore:
  76. {scenario::veinminer} is true
  77. player is sneaking
  78. loop blocks in radius 3 around event-block:
  79. loop-block is equal to redstone ore
  80. set loop-block to air
  81. if player has space for (4 of redstone):
  82. give player (4 of redstone)
  83. else:
  84. drop (4 of redstone) at (location 0.5 above player)
  85. drop 4 xp at player
  86. play "DIG_STONE" specifically to player with pitch 1 and volume 1.0
  87. wait 1 tick
  88.  
  89. on mine of diamond ore:
  90. {scenario::veinminer} is true
  91. player is sneaking
  92. loop blocks in radius 2 around event-block:
  93. loop-block is equal to diamond ore
  94. set loop-block to air
  95. if player has space for (1 of diamond):
  96. give player (1 of diamond)
  97. else:
  98. drop (1 of diamond) at (location 0.5 above player)
  99. drop 5 xp at player
  100. play "DIG_STONE" specifically to player with pitch 1 and volume 1.0
  101. wait 1 ticks
  102.  
  103. on mine of emerald ore:
  104. {scenario::veinminer} is true
  105. player is sneaking
  106. loop blocks in radius 1 around event-block:
  107. loop-block is equal to emerald ore
  108. set loop-block to air
  109. if player has space for (1 of emerald):
  110. give player (1 of emerald)
  111. else:
  112. drop (1 of emerald) at (location 0.5 above player)
  113. drop 6 xp at player
  114. play "DIG_STONE" specifically to player with pitch 2 and volume 0.5
  115. wait 1 tick
  116.  
  117. on mine of gravel:
  118. {scenario::veinminer} is true
  119. player is sneaking
  120. loop blocks in radius 5 around event-block:
  121. loop-block is equal to gravel
  122. set loop-block to air
  123. if player has space for (1 of flint):
  124. give player (1 of flint)
  125. else:
  126. drop (1 of flint) at (location 0.5 above player)
  127. play "DIG_GRAVEL" specifically to player with pitch 0.8 and volume 0.5
  128. wait 1 tick
  129.  
  130.  
  131. #GraveRobbers, made: ‎01 ‎December ‎2016, ‏‎15:51:54
  132.  
  133. command /graverobbers <text>:
  134. aliases: /gr
  135. permission: skript.op
  136. trigger:
  137. if arg 1 is "on":
  138. set {scenario::graverobbers} to true
  139. send "&aEnabled"
  140. else if arg 1 is "off":
  141. delete {scenario::graverobbers}
  142. send "&cDisabled"
  143.  
  144. on death of player:
  145. {scenario::graverobbers} is true
  146. clear drops
  147. set {GR::loc::%victim%} to (location 2 below victim)
  148.  
  149. if block at (location 1 above {GR::loc::%victim%}) is air:
  150. set {_c} to y-coordinate of {GR::loc::%victim%}
  151. loop 256 times:
  152. if block at (location loop-number below {GR::loc::%victim%}) is not air:
  153. set {GR::loc::%victim%} to (location loop-number+1 below {GR::loc::%victim%})
  154. stop loop
  155.  
  156. set block 1 meter north of {GR::loc::%victim%} to chest
  157. set block at {GR::loc::%victim%} to chest
  158.  
  159. set the inventory of the block at {GR::loc::%victim%} to victim's inventory
  160. add the victim's helmet slot to the inventory of the block at {GR::loc::%victim%}
  161. add the victim's chestplate slot to the inventory of the block at {GR::loc::%victim%}
  162. add the victim's leggings slot to the inventory of the block at {GR::loc::%victim%}
  163. add the victim's boots slot to the inventory of the block at {GR::loc::%victim%}
  164. #clear the victim's inventory
  165.  
  166. set {GR::loc::%victim%} to (location 1 above {GR::loc::%victim%})
  167.  
  168. set block 1 meter north of {GR::loc::%victim%} to gravel
  169. set block at {GR::loc::%victim%} to gravel
  170.  
  171. set block 2 meter north of {GR::loc::%victim%} to cobblestone
  172. set block 1 meter south of {GR::loc::%victim%} to cobblestone
  173.  
  174. set {_e} to block 1 meter east of {GR::loc::%victim%}
  175. set {_w} to block 1 meter west of {GR::loc::%victim%}
  176.  
  177. set block 1 meter north of {_e} to cobblestone
  178. set block 2 meter north of {_e} to mossy cobblestone
  179. set block 1 meter south of {_e} to cobblestone
  180. set block at {_e} to mossy cobblestone
  181.  
  182. set block 1 meter north of {_w} to cobblestone
  183. set block 2 meter north of {_w} to mossy cobblestone
  184. set block 1 meter south of {_w} to cobblestone
  185. set block at {_w} to mossy cobblestone
  186.  
  187. set block 2 meter north of {GR::loc::%victim%} to cobblestone
  188. set {_h} to block 2 meter north of {GR::loc::%victim%}
  189. set {_h} to block 1 above {_h}
  190. set block at {_h} to sign
  191.  
  192. set line 1 of block at {_h} to "&cR.I.P"
  193. set line 2 of block at {_h} to "%victim%"
  194. set line 3 of block at {_h} to "&cKilled by"
  195. set line 4 of block at {_h} to "%attacker%"
  196.  
  197. on script unload:
  198. delete {GR::*}
Advertisement
Add Comment
Please, Sign In to add comment