Advertisement
Cool_Colton

Boostpads

Oct 17th, 2020
43
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.19 KB | None | 0 0
  1. Options:
  2. padblock: gold block
  3. defaultforce: 2
  4.  
  5.  
  6. command /boostpad [<text = create>] [<number = {@defaultforce}>]:
  7. permission: boostpad.admin
  8. trigger:
  9. set {_d} to block at player's location
  10. remove 1 from the y coordinate of {_d}
  11. if arg-1 is "create":
  12. if {padblocks::*} doesn't contain {_d}:
  13. set block at {_d} to {@padblock}
  14. add {_d} to {padblocks::*}
  15. set {padforce::%{_d}%} to arg-2
  16. else:
  17. send "&cThere is already a valid boostpad at this location."
  18. else if arg-1 is "delete":
  19. if {padblocks::*} contains {_d}:
  20. set block at {_d} to air
  21. remove {_d} from {padblocks::*}
  22. delete {padforce::%{_d}%}
  23. else:
  24. send "&cThere is no valid boostpad at this location."
  25. else if arg-1 is "setforce" or "force" or "setpower" or "power":
  26. if {padblocks::*} contains {_d}:
  27. set {padforce::%{_d}%} to arg-2
  28. else:
  29. send "&cThere is no valid boostpad at this location."
  30. else if arg-1 is "edit":
  31. if {padblocks::*} contains {_d}:
  32. send formatted "&aEditing the boostpad at %{_d}%:","<tooltip: &aClick here to change!><suggest command:/boostpad power >&8Current power: &b(&2%{padforce::%{_d}%}%<reset>&b)","<command:/boostpad delete>&cClick here to delete the boostpad!"
  33. else:
  34. send "&cThere is no valid boostpad at this location."
  35. else if arg-1 is "EditWand" or "edit-wand" or "editwand" or "getwand" or "get" or "wand":
  36. give player a stick named "&aBoostpad edit wand!"
  37.  
  38. command /boostpad2 [<text = delete>] [<number = {@defaultforce}>]:
  39. permission: boostpad.wand
  40. trigger:
  41. set {_d} to location of player's targeted block
  42. if arg-1 is "delete":
  43. if {padblocks::*} contains {_d}:
  44. set block at {_d} to air
  45. remove {_d} from {padblocks::*}
  46. delete {padforce::%{_d}%}
  47. else:
  48. send "&cThere is no valid boostpad where you are looking."
  49. else if arg-1 is "setforce" or "force" or "setpower" or "power":
  50. if {padblocks::*} contains {_d}:
  51. set {padforce::%{_d}%} to arg-2
  52. else:
  53. send "&cThere is no valid boostpad at this where you are looking."
  54.  
  55.  
  56. on right click with a stick:
  57. name of player's tool contains "Boostpad edit wand!":
  58. player has permission "boostpad.wand" or "boostpad.admin":
  59. set {_d} to location of event-block
  60. {padblocks::*} contains {_d}
  61. send formatted "&aEditing the boostpad at %{_d}%:","<tooltip: &aClick here to change!><suggest command:/boostpad2 power >&8Current power: &b(&2%{padforce::%{_d}%}%<reset>&b)","<command:/boostpad2 delete>&cClick here to delete the boostpad!"
  62.  
  63.  
  64.  
  65. on walk on {@padblock}:
  66. if {padblocks::*} contains location of event-block:
  67. set {_d} to (direction from player's location to location 150 meters in front of player)
  68. push player {_d} with force ({padforce::%location of event-block%}*2)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement