Advertisement
Guest User

Untitled

a guest
Mar 18th, 2018
74
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.08 KB | None | 0 0
  1. options:
  2. C: &c&lDUEL &7
  3. p: &c&lDUEL &7
  4. S: &c
  5. S1: &c
  6. C1: chemist
  7. PM: Unknown command. Type "/help" for help.
  8. variables:
  9. {joustarena} = false
  10. {joust1} = false
  11. on load:
  12. broadcast "{@C}{@S}Duels.sk&7 by Dittoo was loaded!"
  13. command /dtoggle:
  14. permission: {@C1}.dtoggle
  15. permission message: {@PM}
  16. trigger:
  17. if {joustarena} is false:
  18. set {joustarena} to true
  19. message "{@C}&7Duels are now enabled!"
  20. stop
  21. if {joustarena} is true:
  22. set {joustarena} to false
  23. delete {joust1}
  24. message "{@C}&7Duels are now disabled!"
  25. stop
  26. command /duel <player>:
  27. usage: /duel <player>
  28. aliases: /1v1, /challenge, /d
  29. trigger:
  30. if argument 1 is equal to command sender:
  31. message "{@C}&7You cannot duel yourself!" to player
  32. stop
  33. if {joust1} is true:
  34. message "{@C}&7All arenas are in use, please try again later." to command sender
  35. stop
  36. if {joustarena} is true:
  37. if {joustinvite:%arg 1%:%command sender%} is set:
  38. send "{@C}You already have an active request!"
  39. stop
  40. else:
  41. message "{@C}You sent a duel request to {@S}%arg-1%&7!" to command sender
  42. set {joustinvite:%arg 1%:%command sender%} to true
  43. message "{@C}You were sent a duel invite from {@S}%command sender%&7, {@S}/accept {@S}%command sender%&7 to accept it!" to arg-1
  44. wait 30 seconds
  45. if {joustinvite:%arg-1%:%command sender%} is set:
  46. send "&7Your invitation from %command sender% has expired!" to arg-1
  47. send "&7Your invitation to %arg-1% has expired!" to command sender
  48. delete {joustinvite:%arg-1%:%command sender%}
  49. stop
  50. else:
  51. message "{@C}&7Duels are currently {@S}disabled&7! Try again later!"
  52. stop
  53.  
  54. command /accept <player>:
  55. aliases: a, acc
  56. trigger:
  57. if arg-1 is equal to command sender:
  58. message "{@C}&7You cannot joust yourself!" to player
  59. stop
  60. if {joustarena} is true:
  61. if {joustinvite:%command sender%:%arg 1%} is true:
  62. if {joust1} is false:
  63. message "{@C}&7You accepted a duel request from %arg 1%" to command sender
  64. message "{@C}&7Your request from %command sender% was accepted" to arg-1
  65. set {jouster1} to player
  66. set {jouster2} to argument 1
  67. broadcast "{@C}{@S}%arg 1% &7has challenged {@S}%command sender%&7!"
  68. heal arg-1 by 10.0 hearts
  69. heal command sender by 10.0 hearts
  70. execute console command "/gamemode adventure %command sender%"
  71. execute console command "/gamemode adventure %arg-1%"
  72. execute console command "/scoreboard teams join *GT %command sender%"
  73. execute console command "/scoreboard teams join *GT %arg-1%"
  74. delete {joustinvite:%command sender%:%arg 1%}
  75. delete {joustinvite:%arg-1%:%command sender%}
  76. make command sender execute command "/dwarp 1"
  77. make arg-1 execute command "/dwarp 2"
  78. set {joust1} to true
  79. stop
  80. else:
  81. send "{@C}All arenas are in use, please try again later."
  82. stop
  83. else:
  84. send "{@C}%arg-1% has not requested to duel you!"
  85. stop
  86. else:
  87. send "{@C}Duels are currently {@S}disabled&7."
  88. stop
  89.  
  90. on death of player:
  91. if {joustarena} is true:
  92. if {jouster1} is equal to victim:
  93. if {jouster2} is equal to attacker:
  94. broadcast "{@C}&7%{jouster2}% &7has defeated&7 %{jouster1}%!"
  95. execute console command "/spawn %{jouster2}%"
  96. heal {jouster2} by 10.0 hearts
  97. clear the inventory of {jouster2}
  98. clear the inventory of {jouster1}
  99. delete {jouster2}
  100. delete {jouster1}
  101. set {joust1} to false
  102. if {jouster2} is equal to victim:
  103. if {jouster1} is equal to attacker:
  104. broadcast "{@C}&7%{jouster1}% &7has defeated&7 %{jouster2}%!"
  105. execute console command "/spawn %{jouster1}%"
  106. heal {jouster1} by 10.0 hearts
  107. clear the inventory of {jouster1}
  108. clear the inventory of {jouster2}
  109. delete {jouster1}
  110. delete {jouster2}
  111. set {joust1} to false
  112. on quit:
  113. if {joustarena} is true:
  114. if {jouster1} is equal to player:
  115. broadcast "{@C}&7%{jouster2}% &7has defeated&7 %{jouster1}%!"
  116. execute console command "/win %{jouster2}%"
  117. heal {jouster2} by 10.0 hearts
  118. clear the inventory of {jouster2}
  119. clear the inventory of {jouster1}
  120. delete {jouster2}
  121. delete {jouster1}
  122. set {joust1} to false
  123. if {jouster2} is equal to player:
  124. broadcast "{@C}&7%{jouster1}% &7has defeated &7%{jouster2}%&7!"
  125. execute console command "/win %{jouster1}%"
  126. heal {jouster1} by 10.0 hearts
  127. clear the inventory of {jouster1}
  128. clear the inventory of {jouster2}
  129. delete {jouster1}
  130. delete {jouster2}
  131. set {joust1} to false
  132. on skript stop:
  133. delete {jouster1}
  134. delete {jouster2}
  135. delete {joust1}
  136. on skript start:
  137. delete {jouster1}
  138. delete {jouster2}
  139. delete {joust1}
  140.  
  141. command /dwarpset <integer>:
  142. permission: chemist.warpset
  143. permission message: {@PM}
  144. trigger:
  145. set {warp.%arg-1%} to location of player
  146. message "&7Duel spawn {@S}%arg-1%&7 is now at {@S}%location of player%&7!"
  147. command /dwarp <integer>:
  148. trigger:
  149. if {jouster1} is equal to player:
  150. teleport player to {warp.%arg-1%}
  151. message "&7Teleporting to duel spawn..."
  152. stop
  153. if {jouster2} is equal to player:
  154. teleport player to {warp.%arg-1%}
  155. message "&7Teleporting to duel spawn..."
  156. stop
  157. if {jouster1} is equal to player:
  158. stop
  159. if {jouster2} is equal to player:
  160. stop
  161. send "{@C}An error occurred, please try again."
  162. command /win <player>:
  163. executable by: players and console
  164. permission: tiger.core.op
  165. trigger:
  166. if argument 1 is equal to {jouster1}:
  167. broadcast "{@C}&7%{jouster1}% &7has defeated&7 %{jouster2}%!"
  168. delete {joust1}
  169. delete {jouster1}
  170. delete {jouster2}
  171. if argument 1 is equal to {jouster2}:
  172. broadcast "{@C}&7%{jouster2}% &7has defeated&7 %{jouster1}%!"
  173. delete {joust1}
  174. delete {jouster1}
  175. delete {jouster2}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement