Advertisement
Guest User

2v2 Skript?

a guest
Sep 1st, 2015
151
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.24 KB | None | 0 0
  1. Options:
  2. P: &8[&bHyperDriveMC&8]
  3. C: &7
  4. H: &a
  5. Perm: skript.op
  6. World: duel
  7.  
  8. command /startduel <player> <player> <player> <player>:
  9. permission: {@Perm}
  10. usage: /startduel <Player> <Player> <Player> <Player>
  11. trigger:
  12. set {duel} to true
  13. set {duel::%arg-1%} to true
  14. set {duel::%arg-2%} to true
  15. set {duel::%arg-3%} to true
  16. set {duel::%arg-4%} to true
  17. # First Player
  18. apply slowness 10 to arg-1 for 999 days
  19. apply resistance 10 to arg-1 for 999 days
  20. apply blindness 10 to arg-1 for 999 days
  21. equip arg-1 with a diamond helmet of protection 1 and unbreaking 10 named "&aHelmet"
  22. equip arg-1 with a iron chestplate of projectile protection 1 and unbreaking 10 named "&eChestPlate"
  23. equip arg-1 with a iron leggings of protection 1 and unbreaking 10 named "&3Leggings"
  24. equip arg-1 with a diamond boots of projectile protection 1 and unbreaking 10 named "&6Boots"
  25. give arg-1 a iron sword of sharpness 1 and unbreaking 10 named "&c&lSword"
  26. give arg-1 a bow of infinity 1 and power 1and unbreaking 10 named "&a&lBow"
  27. give arg-1 1 arrow named "&e&lArrow"
  28. give arg-1 346
  29. command "/warp duel1 %arg-1%"
  30. # Second Player
  31. apply slowness 10 to arg-2 for 999 days
  32. apply resistance 10 to arg-2 for 999 days
  33. apply blindness 10 to arg-2 for 999 days
  34. equip arg-2 with a diamond helmet of protection 1 and unbreaking 10 named "&aHelmet"
  35. equip arg-2 with a iron chestplate of projectile protection 1 and unbreaking 10 named "&eChestPlate"
  36. equip arg-2 with a iron leggings of protection 1 and unbreaking 10 named "&3Leggings"
  37. equip arg-2 with a diamond boots of projectile protection 1 and unbreaking 10 named "&6Boots"
  38. give arg-2 a iron sword of sharpness 1 and unbreaking 10 named "&c&lSword"
  39. give arg-2 a bow of infinity 1 and power 1 and unbreaking 10 named "&a&lBow"
  40. give arg-2 1 arrow named "&e&lArrow"
  41. give arg-2 346
  42. command "/warp duel1 %arg-2%"
  43. # Third Player
  44. apply slowness 10 to arg-3 for 999 days
  45. apply resistance 10 to arg-3 for 999 days
  46. apply blindness 10 to arg-3 for 999 days
  47. equip arg-3 with a diamond helmet of protection 1 and unbreaking 10 named "&aHelmet"
  48. equip arg-3 with a iron chestplate of projectile protection 1 and unbreaking 10 named "&eChestPlate"
  49. equip arg-3 with a iron leggings of protection 1 and unbreaking 10 named "&3Leggings"
  50. equip arg-3 with a diamond boots of projectile protection 1 and unbreaking 10 named "&6Boots"
  51. give arg-3 a iron sword of sharpness 1 and unbreaking 10 named "&c&lSword"
  52. give arg-3 a bow of infinity 1 and power 1 and unbreaking 10 named "&a&lBow"
  53. give arg-3 1 arrow named "&e&lArrow"
  54. give arg-3 346
  55. command "/warp duel2 %arg-3%"
  56. # Fourth Player
  57. apply slowness 10 to arg-4 for 999 days
  58. apply resistance 10 to arg-4 for 999 days
  59. apply blindness 10 to arg-4 for 999 days
  60. equip arg-4 with a diamond helmet of protection 1 and unbreaking 10 named "&aHelmet"
  61. equip arg-4 with a iron chestplate of projectile protection 1 and unbreaking 10 named "&eChestPlate"
  62. equip arg-4 with a iron leggings of protection 1 and unbreaking 10 named "&3Leggings"
  63. equip arg-4 with a diamond boots of projectile protection 1 and unbreaking 10 named "&6Boots"
  64. give arg-4 a iron sword of sharpness 1 and unbreaking 10 named "&c&lSword"
  65. give arg-4 a bow of infinity 1 and power 1 and unbreaking 10 named "&a&lBow"
  66. give arg-4 1 arrow named "&e&lArrow"
  67. give arg-4 346
  68. command "/warp duel2 %arg-4%"
  69.  
  70. broadcast "{@P}{@C} Duel Starting Between {@H}%arg-1% {@C}And {@H}%arg-2%{@C} Are Against {@H}%arg-3% {@C}And {@H}%arg-4%{@C}!”
  71. wait 10 ticks
  72. broadcast "{@P}{@C} Duel Starting In &a3{@C}..."
  73. loop all players:
  74. execute console command "/playsound random.click %loop-player% ~ ~ ~ 1 1 1"
  75. wait 1 second
  76. broadcast "{@P}{@C} Duel Starting In &a2{@C}..."
  77. loopall players:
  78. execute console command "/playsound random.click %loop-player% ~ ~ ~ 1 1 1"
  79. wait 1 second
  80. broadcast "{@P}{@C} Duel Starting In &a1{@C}..."
  81. loop all players:
  82. execute console command "/playsound random.click %loop-player% ~ ~ ~ 1 1 1"
  83. wait 1 second
  84. broadcast "{@P}{@C} Duel Between {@H}%arg-1% {@C}{@H}%arg-2% And {@H}%arg-3% {@H}%arg-4% Has Started {@C}Started!"
  85. loop all players:
  86. execute console command "/playsound note.pling %loop-player% ~ ~ ~ 1 1 1"
  87. command "/effect %arg-1% clear"
  88. command "/effect %arg-2% clear"
  89. command “/effect %arg-3% clear"
  90. command “/effect %arg-4% clear"
  91.  
  92. command /endduel <player> <player>:
  93. permission: {@Perm}
  94. usage: /endduel <Winner> <Winner>
  95. trigger:
  96. heal arg-1
  97. clear the inventory of arg-1
  98. command "/effect %arg-1% clear"
  99. command "/effect %arg-2% clear"
  100. command "/warp duelspawn %arg-1% %arg-2%”
  101. broadcast "{@P}{@H} %arg-1% and %arg-2% {@C}Won The Duel!"
  102. delete {duel}
  103. delete {duel::*}
  104.  
  105. command /stopduel:
  106. permission: {@Perm}
  107. trigger:
  108. loop all players:
  109. command "/warp duelspawn %loop-player%"
  110. clear the inventory of loop-player
  111. heal loop-player
  112. command "/effect %loop-player% clear"
  113. delete {duel}
  114. delete {duel::*}
  115. broadcast "{@P}{@C} Duel Stopped!"
  116.  
  117. command /duelhelp:
  118. permission: skript.option
  119. trigger:
  120. message "&8-----------------------------"
  121. message "{@H}/startduel <player> <player> &8- {@C}Start a duel against 2 players!"
  122. message "{@H}/endduel &8-{@C} End a duel and broadcast the winner!"
  123. message "{@H}/stopduel &8-{@C} Tab the wrong person? Stop the duel and tp all players to the duel spawn point."
  124. message "&cRemember&8-{@C} Set a warp named 'duelspawn' where you want the players to spawn. You also need to setwarps 'duel1' and 'duel2' for spawnpoints for players."
  125. message "&8-----------------------------"
  126.  
  127. on death of player:
  128. if {duel} is true:
  129. clear drops
  130. command "/endduel %attacker%"
  131.  
  132. on join:
  133. if {duel} is true:
  134. command "/warp duelspawn %player%"
  135. command "/effect %player% clear"
  136. heal player
  137. clear the inventory of player
  138.  
  139. on quit:
  140. if {duel::%player%} is true:
  141. broadcast "{@P}{@H} Duelling Player Logged Out!"
  142. command "/stopduel"
  143.  
  144. on damage:
  145. damage was caused by fall
  146. victim is a player
  147. victim is in the world "{@World}"
  148. {duel} is true
  149. cancel the event
  150.  
  151. on hunger meter change:
  152. player is in world "{@World}"
  153. set player's hunger meter to 10
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement