Advertisement
Cool_Colton

Untitled

Sep 11th, 2020
39
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.05 KB | None | 0 0
  1. function ResetMine(l1: location, l2: location, b: item, luck: number):
  2. loop all blocks within {_l1} and {_l2}:
  3. tps is below 10:
  4. wait 1 tick
  5. type of loop-block is air or purple glazed terracotta
  6. set {_d} to a random integer from 1 to 10000
  7. set {_luck2} to {_luck} * 100
  8. {_d} is between 1 and {_luck2}:
  9. set block at location of loop-block to purple glazed terracotta
  10. else:
  11. set block at location of loop-block to {_b}
  12. broadcast "The mine has been reset:"
  13. broadcast "Air blocks have been set to %{_b}%"
  14. broadcast "with a %{_luck}%%% chance of a berry block"
  15.  
  16. on block break:
  17. add 1 to {blocks::for::reset}
  18. if {blocks::for::reset} is more than 10:
  19. delete {blocks::for::reset}
  20. wait 1 tick
  21. {d} is more than 5:
  22. set {d} to 0
  23. set {last::reset::mine} to now
  24. set {_d} to a random integer from 1 to 1000
  25. {_d} is between 1 and 250:
  26. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", red concrete, .5)
  27. {_d} is between 251 and 450:
  28. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", lime concrete, .6)
  29. {_d} is between 451 and 550:
  30. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", pink concrete, .7)
  31. {_d} is between 551 and 650:
  32. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", light blue concrete, .8)
  33. {_d} is between 651 and 750:
  34. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", orange concrete, 1)
  35. {_d} is between 751 and 800:
  36. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", yellow concrete, 1.5)
  37. {_d} is between 801 and 1000:
  38. ResetMine(location (0, 1, 0) world "world", location (69, 50, 69) world "world", red concrete, .6)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement