Advertisement
Guest User

Untitled

a guest
Nov 19th, 2019
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.21 KB | None | 0 0
  1. command /ken:
  2. permission: sk.stick
  3. trigger:
  4. set {%player%.cooldown} to 0
  5. give 1 diamond sword named "&f剣" with lore "&f前方を範囲攻撃できる" to player
  6.  
  7.  
  8. on left click:
  9. if name of the item is "&f剣":
  10. if {%player%.kenskill} is not set:
  11. set {%player%.kenskill} to 0
  12. if {%player%.kenskill} is 0:
  13. if {%player%.knac} is not set:
  14. set {%player%.knac} to 0
  15. if {%player%.knac} is 0:
  16. set {%player%.knac} to 1
  17. set {%player%.kennorloc} to location of the block 3 meter in front of player's head
  18. set {%player%.kennorloc2} to location of the block 7 meter in front of player's head
  19. loop entities in radius 3 around {%player%.kennorloc}:
  20. loop-entity is not player
  21. damage loop-entity by 3.5 heart
  22. show 1 sweep attack particles at loop-entity offset by 0, 0, 0 at speed 1
  23. loop entities in radius 2 around {%player%.kennorloc2}:
  24. loop-entity is not player
  25. damage loop-entity by 3.5 heart
  26. show 1 sweep attack particles at loop-entity offset by 0, 0, 0 at speed 1
  27. wait 1 second
  28. set {%player%.knac} to {%player%.knac} -1
  29.  
  30. if {%player%.kenskill} is 1:
  31. if {%player%.knac} is not set:
  32. set {%player%.knac} to 0
  33. if {%player%.knac} is 0:
  34. set {%player%.knac} to 1
  35. set {%player%.kennorloc} to location of the block 4 meter in front of player's head
  36. set {%player%.kennorloc2} to location of the block 8 meter in front of player's head
  37. loop entities in radius 4 around {%player%.kennorloc}:
  38. loop-entity is not player
  39. damage loop-entity by 6 heart
  40. show 1 sweep attack particles at loop-entity offset by 0, 0, 0 at speed 1
  41. loop entities in radius 4 around {%player%.kennorloc2}:
  42. loop-entity is not player
  43. damage loop-entity by 6 heart
  44. show 1 sweep attack particles at loop-entity offset by 0, 0, 0 at speed 1
  45. wait 1 second
  46. set {%player%.knac} to {%player%.knac} -1
  47.  
  48. on leftclick:
  49. if name of the item is "&f剣":
  50. if {%player%.kenskill} is 0:
  51. if {%player%.knac2} is not set:
  52. set {%player%.knac2} to 0
  53. if {%player%.knac2} is 0:
  54. set {%player%.knac2} to 1
  55. play "ENTITY_PLAYER_ATTACK_SWEEP" to player at volume 1
  56. set {_%player%.num} to 2
  57. set {_Particle} to location of the block {_%player%.num} meter in front of player's head
  58. loop 6 times:
  59. show 1 sweep attack particles at {_Particle} offset by 0, 0, 0
  60. set {_%player%.num} to {_%player%.num} + 1
  61. set {_Particle} to location of the block {_%player%.num} meter infront of player's head
  62. if the block {_%player%.num} meter infront of player's head is not air:
  63. stop loop
  64. wait 1 second
  65. set {%player%.knac2} to 0
  66. if {%player%.kenskill} is 1:
  67. if {%player%.knac2} is not set:
  68. set {%player%.knac2} to 0
  69. if {%player%.knac2} is 0:
  70. set {%player%.knac2} to 1
  71. play "ENTITY_PLAYER_ATTACK_SWEEP" to player at volume 1
  72. set {_%player%.num} to 2
  73. set {_Particle} to location of the block {_%player%.num} meter in front of player's head
  74. loop 20 times:
  75. show 1 sweep attack particles at {_Particle} offset by 0, 0, 0
  76. display 10 redstone particle at location of {_Particle} with color 214, 35, 67 offset by 0.0, 0.0, 0.0
  77. set {_%player%.num} to {_%player%.num} + 0.5
  78. set {_Particle} to location of the block {_%player%.num} meter infront of player's head
  79. if the block {_%player%.num} meter infront of player's head is not air:
  80. stop loop
  81. wait 1 second
  82. set {%player%.knac2} to 0
  83. every 1 ticks:
  84. loop all players:
  85. clear {%loop-player%.hondwepon}
  86. if {%loop-player%.kenskill} is 1:
  87. display 10 redstone particle at location of loop-player with color 214, 35, 67 offset by 0.0, 0.0, 0.0
  88. if loop-player's held item is stone sword:
  89. set {%loop-player%.hondwepon} to 1
  90. set the loop-player's walk speed to 0.35
  91. set the maximum health of the loop-player to 15
  92. if loop-player's held item is iron sword:
  93. set {%loop-player%.hondwepon} to 2
  94. set the maximum health of the loop-player to 25
  95. set the loop-player's walk speed to 0.15
  96. if {%loop-player%.hondwepon} is not set:
  97. set the loop-player's walk speed to 0.25
  98. set the maximum health of the loop-player to 20
  99.  
  100.  
  101. on drop:
  102. if name of the item is "&f剣":
  103. if {%player%.ksac} is not set:
  104. set {%player%.ksac} to 0
  105. if {%player%.ksac} is 0:
  106. send "&e剣スキルを発動しました" to player
  107. set {%player%.kenskill} to 1
  108. wait 10 second
  109. set {%player%.kenskill} to 0
  110. set {%player%.ksac} to 50
  111. loop 50 times:
  112. wait 1 second
  113. set {%player%.ksac} to {%player%.ksac} -1
  114. send "スキルのクールダウンが終わりました!" to player
  115. if {%player%.ksac} >= 1:
  116. send "&cクールダウン中です!(残り%{%player%.ksac}%秒)" to player
  117.  
  118. on damage:
  119. set {%victim%.kenskilldamage} to damage
  120. if {%victim%.kenskill} is 1:
  121. set {%victim%.kenskilldamage} to {%victim%.kenskilldamage} / 2
  122. set {%victim%.kenskilldamage} to {%victim%.kenskilldamage} * -1
  123. increase the damage by {%victim%.kenskilldamage}
  124. command /heal:
  125. trigger:
  126. heal player by 99999 heart
  127. set the player's food level to 20
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement