Oxalist

Untitled

Apr 14th, 2018
110
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 7.46 KB | None | 0 0
  1. variables:
  2. {frosted::%player%} = "False"
  3.  
  4. command /frosted:
  5. trigger:
  6. if {game::started} is "True":
  7. send "&b&lFrosted &8&l» &7The game is already running, please wait"
  8. stop
  9. if {frosted::%player%} is "False":
  10. set {frosted::%player%} to "True"
  11. add 1 to {frosted}
  12. set the player's tablist name to "&e%player%"
  13. add player to {frosted::list}
  14. send "&b&lFrosted &8&l» &7You have joined the queue (%{frosted}%/12)"
  15. stop
  16. if {frosted} is more than 1:
  17. loop all players:
  18. if {frosted::%loop-player%} is "True":
  19. wait 1 second
  20. send loop-player title "&b&lFrosted" with subtitle "&7Game starting in 10 seconds" for 2 seconds
  21. wait 5 seconds
  22. send loop-player title "&b&lFrosted" with subtitle "&7Game starting in 5 seconds" for 1 second
  23. wait 1 second
  24. send loop-player title "&b&lFrosted" with subtitle "&7Game starting in 4 seconds" for 1 second
  25. wait 1 seconds
  26. send loop-player title "&b&lFrosted" with subtitle "&7Game starting in 3 seconds" for 1 second
  27. wait 1 seconds
  28. send loop-player title "&b&lFrosted" with subtitle "&7Game starting in 2 seconds" for 1 second
  29. wait 1 seconds
  30. send loop-player title "&b&lFrosted" with subtitle "&7Game starting in 1 seconds" for 1 second
  31. wait 1 second
  32. set {health::%loop-player%} to 5
  33. set {lives::%loop-player%} to 5
  34. set the loop-player's tablist name to "&b%loop-player% &f%{lives::%loop-player%}%"
  35. set {_loc} to a random element out of {frosted::spawns::*}
  36. teleport loop-player to {_loc}
  37. set slot 0 of player's inventory to 1 slimeball of knockback 2 named "&b&lFrosted &8&l» &7Default Kit"
  38. send loop-player title "&b&lFrosted" with subtitle "&7The game has started" for 2 seconds
  39. set {game::started} to "True"
  40. set {ingame::%loop-player%} to "True"
  41. stop
  42. if {frosted::%player%} is "True":
  43. set {frosted::%player%} to "False"
  44. remove 1 from {frosted}
  45. set the player's tablist name to "&7%player%"
  46. remove player from {frosted::list}
  47. send "&b&lFrosted &8&l» &7You have left the queue (%{frosted}%/12)"
  48. stop
  49.  
  50. every second:
  51. loop all players:
  52. if {ingame::%loop-player%} is "True":
  53. set the loop-player's tablist name to "&b%loop-player% &f%{lives::%loop-player%}%"
  54. if {frosted} is equal to 0:
  55. broadcast "&b&lFrosted &8&l» &7The game has ended, please play again"
  56. set {health::%loop-player%} to 5
  57. set {game::started} to "False"
  58. set {lives::%loop-player%} to 5
  59. set {ingame::%loop-player%} to "False"
  60. remove 1 slimeball named "&b&lFrosted &8&l» &7Default Kit" from loop-player
  61. set {frosted::%loop-player%} to "False"
  62. set the loop-player's tablist name to "&7%loop-player%"
  63. delete {frosted::list}
  64. teleport loop-player to {spawn}
  65. delete {frosted}
  66. stop
  67.  
  68. every second:
  69. loop all players:
  70. if {ingame::%loop-player%} is "True":
  71. If block below loop-player is bedrock:
  72. remove 1 from {health::%loop-player%}
  73. if {lives::%loop-player%} is equal to 0:
  74. send "&b&lFrosted &8&l» &7You have died" to loop-player
  75. set {health::%loop-player%} to 5
  76. set {lives::%loop-player%} to 5
  77. set {ingame::%loop-player%} to "False"
  78. set {frosted::%loop-player%} to "False"
  79. set the loop-player's tablist name to "&7%loop-player%"
  80. remove loop-player from {frosted::list}
  81. remove 1 from {frosted}
  82. teleport loop-player to {spawn}
  83. if {health::%loop-player%} is equal to 0:
  84. send "&b&lFrosted &8&l» &7You have lost 1 life" to loop-player
  85. set {health::%loop-player%} to 5
  86. remove 1 from {lives::%loop-player%}
  87. set {_loc} to a random element out of {frosted::spawns::*}
  88. teleport loop-player to {_loc}
  89.  
  90. every tick:
  91. loop all players:
  92. if {ingame::%loop-player%} is "True":
  93. set action bar of loop-player to "&b&lHealth %{health::%loop-player%}% "
  94.  
  95.  
  96. every second:
  97. loop all players:
  98. if {ingame::%loop-player%} is "True":
  99. wipe loop-player's sidebar
  100. set name of sidebar of loop-player to "&b&lFrosted Lives"
  101. set score "&9" in sidebar of loop-player to 6
  102. set score "&7Players: &f%{frosted}%" in sidebar of loop-player to 5
  103. set score "&7Health: &f%{health::%loop-player%}%" in sidebar of loop-player to 4
  104. set score "&a" in sidebar of loop-player to 3
  105. set score "&7Lives: &f%{lives::%loop-player%}%" in sidebar of loop-player to 2
  106. set score "&6" in sidebar of loop-player to 1
  107.  
  108. on damage:
  109. if {ingame::%attacker%} is "True":
  110. stop
  111. if {ingame::%attacker%} is "False":
  112. send "&b&lPvP &8&l» &7You cannot pvp when you are not in a game"
  113. stop
  114.  
  115.  
  116. command /setspawnpoints-frosted:
  117. trigger:
  118. add location of player to {frosted::spawns::*}
  119. send "&b&lFrosted &8&l» &7Successfully set a spawn point"
  120.  
  121. command /list:
  122. trigger:
  123. send "%{frosted}%"
  124.  
  125. command /resetqueue:
  126. trigger:
  127. loop all players:
  128. set {game::started} to "False"
  129. set {frosted::%loop-player%} to "False"
  130. set {imgame::%loop-player%} to "False"
  131. set {frosted} to 0
  132.  
  133. options:
  134. databasePrefix: jdogdatabase_
  135. nopermission: &cNo Permission.
  136. version: 1.0.0
  137.  
  138. on any movement:
  139. if {ingame::%player%} is "True":
  140. if block at location of player is water:
  141. stop
  142. if block 1 above player is water:
  143. stop
  144. if block 2 above player is water:
  145. stop
  146. if block 3 above player is water:
  147. stop
  148. if block 1 below player is air:
  149. stop
  150. loop blocks in radius 2 of player:
  151. if loop-block is water:
  152. set loop-block to ice
  153. add location of loop-block to {blocks%player%::*}
  154. loop blocks in radius 2 of player:
  155. if loop-block is ice:
  156. if block 1 above loop-block is ice:
  157. set loop-block to water
  158. if block 2 above loop-block is ice:
  159. set loop-block to water
  160. set {loc%player%} to location of player
  161. stop
  162. wait 2 seconds
  163. loop {blocks%player%::*}:
  164. loop all entities in radius 3 of loop-value-1:
  165. if loop-entity is player:
  166. stop
  167. set block at location of loop-value to water
  168.  
  169. every 3 seconds:
  170. loop all players:
  171. if {blocks%loop-player%::*} is set:
  172. loop {blocks%loop-player%::*}:
  173. set {loc2%loop-player%} to location of loop-value-2
  174. if distance between {loc%loop-player%} and {loc2%loop-player%} is more than 2:
  175. chance of 75%:
  176. set block at location of loop-value-2 to water
  177. remove location of loop-value-2 from {blocks%loop-player%::*}
Advertisement
Add Comment
Please, Sign In to add comment