Advertisement
sniperwolf1130

magic

May 30th, 2020
1,901
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.43 KB | None | 0 0
  1. on first join:
  2. set {mana.%player%} to 500
  3.  
  4. options:
  5. Mana.Ll.SR: 60 #Lightning RodをShift+右クリックしたときの消費mana
  6. Cd.Ll.SR: 20 #Lightning RodをShift+右クリックしたときのクールダウン時間(秒)
  7. Mana.Ll.R: 10 #Lightning Rodを右クリックしたときの消費mana
  8. Cd.Ll.R: 1 #Lightning Rodを右クリックしたときのクールダウン時間(秒)
  9.  
  10. Mana.Hc.SR: 40 #Heal CharmをShift+右クリックしたときの消費mana
  11. Cd.Hc.SR: 60 #Heal CharmをShift+右クリックしたときのクールダウン時間(秒)
  12. Mana.Hc.R: 10 #Heal Charmを右クリックしたときの消費mana
  13. Cd.Hc.R: 20 #Heal Charmを右クリックしたときのクールダウン時間(秒)
  14.  
  15. Mana.Sr: 10 #Search Ringを右クリックしたときの消費mana
  16. Cd.Sr: 20 #Search Ringを右クリックしたときのクールダウン時間(秒)
  17.  
  18. CdM: "<light red>wait cooldown!" #クールダウン中のメッセージ
  19. NmM: "<light red>not enough mana!" #mana不足のメッセージ
  20.  
  21. #|================================================================================|Lightning Rod
  22.  
  23. on right click with gold hoe:
  24. name of player's tool contains "<gold>Lightning Rod"
  25. cancel event
  26. if player is sneaking:
  27. if {cd.llsr.%player%} is not 0:
  28. if {mana.%player%} >= {@Mana.Ll.SR}:
  29. set {cd.llsr.%player%} to 0
  30. execute command "/execute at %player% run particle minecraft:portal ~ ~ ~ 1 1 1 0.1 1000 normal"
  31. execute command "playsound entity.illusioner.prepare_blindness master %player% ~ ~ ~ 1 0.5 1"
  32. wait 40 tick
  33. loop all entities in radius 20 of location of player:
  34. loop-entity is not player
  35. "%loop-entity%" is not "experience orb"
  36. "%loop-entity%" is not "dropped item"
  37. strike fake fake lightning at the loop-entity
  38. damage loop-entity by 10 hearts
  39. execute command "playsound entity.illusioner.prepare_mirror master %player% ~ ~ ~ 1 2 1"
  40. subtract {@Mana.Ll.SR} from {mana.%player%}
  41. wait {@Cd.Ll.SR} seconds
  42. set {cd.llsr.%player%} to 1
  43. else:
  44. set action bar of player to {@NmM}
  45. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  46. else:
  47. set action bar of player to {@CdM}
  48. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  49.  
  50. else:
  51. player's target entity is set
  52. player's target entity is not player
  53. "%player's target entity%" is not "experience orb"
  54. "%player's target entity%" is not "dropped item"
  55. if {cd.llr.%player%} is not 0:
  56. if {mana.%player%} >= {@Mana.Ll.R}:
  57. set {cd.llr.%player%} to 0
  58. strike fake fake lightning at the player's target entity
  59. execute command "playsound entity.generic.explode master %player% ~ ~ ~ 1 2 1"
  60. subtract {@Mana.Ll.R} from {mana.%player%}
  61. damage player's target entity by 5 hearts
  62. wait {@Cd.Ll.R} seconds
  63. set {cd.llr.%player%} to 1
  64. else:
  65. set action bar of player to {@NmM}
  66. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  67. else:
  68. set action bar of player to {@CdM}
  69. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  70.  
  71.  
  72. on left click with gold hoe:
  73. name of player's tool contains "<gold>Lightning Rod"
  74. cancel event
  75.  
  76. #|================================================================================|Search Ring
  77.  
  78. on right click with heart of the sea:
  79. name of player's tool contains "<light aqua>Search Ring"
  80. cancel event
  81. if {cd.sr.%player%} is not 0:
  82. if {mana.%player%} >= {@Mana.Sr}:
  83. set {cd.sr.%player%} to 0
  84. loop all entities in radius 50 of location of player:
  85. loop-entity is not player
  86. "%loop-entity%" is not "experience orb"
  87. "%loop-entity%" is not "dropped item"
  88. apply glowing to loop-entity for 10 seconds
  89. execute command "playsound block.conduit.deactivate master %player% ~ ~ ~ 1 1 1"
  90. subtract {@Mana.Sr} from {mana.%player%}
  91. wait {@Cd.Sr} second
  92. set {cd.sr.%player%} to 1
  93. else:
  94. set action bar of player to {@NmM}
  95. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  96. else:
  97. set action bar of player to {@CdM}
  98. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  99.  
  100. on left click with heart of the sea:
  101. name of player's tool contains "<light aqua>Search Ring"
  102. cancel event
  103.  
  104. #|================================================================================|Heal Charm
  105.  
  106. on right click with pink dye:
  107. name of player's tool contains "<light purple>Heal Charm"
  108. cancel event
  109. if player is sneaking:
  110. if {cd.hisr.%player%} is not 0:
  111. if {mana.%player%} >= {@Mana.Hc.SR}:
  112. set {cd.hisr.%player%} to 0
  113. loop all players in radius 10 of location of player:
  114. execute command "playsound entity.player.levelup master %loop-player% ~ ~ ~ 1 2 1"
  115. heal loop-player
  116. subtract {@Mana.Hc.SR} from {mana.%player%}
  117. wait {@Cd.Hc.SR} seconds
  118. set {cd.hisr.%player%} to 1
  119. else:
  120. set action bar of player to {@NmM}
  121. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  122. else:
  123. set action bar of player to {@CdM}
  124. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  125.  
  126. else:
  127. if {cd.hir.%player%} is not 0:
  128. if {mana.%player%} >= {@Mana.Hc.R}:
  129. set {cd.hir.%player%} to 0
  130. execute command "playsound entity.player.levelup master %player% ~ ~ ~ 1 2 1"
  131. heal player
  132. subtract {@Mana.Hc.R} from {mana.%player%}
  133. wait {@Cd.Hc.R} seconds
  134. set {cd.hir.%player%} to 1
  135. else:
  136. set action bar of player to {@NmM}
  137. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  138. else:
  139. set action bar of player to {@CdM}
  140. execute command "playsound block.note_block.bass master @p ~ ~ ~ 1 0.5 1"
  141.  
  142.  
  143. on left click with pink dye:
  144. name of player's tool contains "<light purple>Heal Charm"
  145. cancel event
  146.  
  147. #|================================================================================|
  148.  
  149. command /magic <text>:
  150. permission: op
  151. trigger:
  152. if arg is "ll":
  153. give 1 gold hoe named "<gold>Lightning Rod" with lore "<purple>Right <white>: <gray>通常攻撃" and "<purple>mana cost <white>: <gray>{@Mana.Ll.R}" and "<purple>cooldown <white>: <gray>{@Cd.Ll.R}" and "" and "<purple>Shift + Right <white>: <gray>範囲攻撃" and "<purple>mana cost <white>: <gray>{@Mana.Ll.SR}" and "<purple>cooldown <white>: <gray>{@Cd.Ll.SR}" to player
  154. else if arg is "hc":
  155. give 1 pink dye named "<light purple>Heal Charm" with lore "<purple>Right <white>: <gray>自己回復" and "<purple>mana cost <white>: <gray>{@Mana.Hc.R}" and "<purple>cooldown <white>: <gray>{@Cd.Hc.R}" and "" and "<purple>Left <white>: <gray>範囲回復" and "<purple>mana cost <white>: <gray>{@Mana.Hc.SR}" and "<purple>cooldown <white>: <gray>{@Cd.Hc.SR}" to player
  156. else if arg is "sr":
  157. give 1 heart of the sea named "<light aqua>Search Ring" with lore "<purple>Right <white>: <gray>周囲探索" and "<purple>mana cost <white>: <gray>{@Mana.Sr}" and "<purple>cooldown <white>: <gray>{@Cd.Sr}" to player
  158. else:
  159. message "<light red>That tool does not exist."
  160.  
  161. every 10 tick:
  162. loop all players:
  163. set action bar of loop-player to "<gold>mana <white>: <purple>%{mana.%loop-player%}%"
  164. add 1 to {mana.%loop-player%}
  165.  
  166. command /mb:
  167. trigger:
  168. message "<command:/get ll><gray>[<gold>Lightning Rod<gray>]<reset>"
  169. message "<command:/get hc><gray>[<light purple>Heal Charm<gray>]<reset>"
  170. message "<command:/get sr><gray>[<light aqua>Search Ring<gray>]<reset>"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement