Guest User

Untitled

a guest
Sep 1st, 2014
472
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.35 KB | None | 0 0
  1. options:
  2.  
  3. Prefix: &8[&cPyrotechnics&8]
  4.  
  5. HC: &e
  6. CC: &r
  7.  
  8.  
  9. command /pyrotechnics [<text>]:
  10. trigger:
  11. if arg-1 is "on" or "enable":
  12. command sender has permission "skript.pyrotechnics":
  13. if {Pyrotechnics.Enabled} is not set:
  14. set {Pyrotechnics.Enabled} to true
  15. broadcast "{@Prefix}{@CC} Enabled by {@HC}%command sender%!"
  16. loop all players:
  17. set {Pyrotechnics.HasWater.%loop-player%} to true
  18. add loop-player to {Pyrotechnics.List::*}
  19. player's inventory has space for 1 water block:
  20. give 1 water block to loop-player
  21. message "{@Prefix}{@CC} A water block was given to you!" to loop-player
  22. else:
  23. drop 1 water block at loop-player
  24. message "{@Prefix}{@CC} A water block was dropped near you!" to loop-player
  25. else:
  26. message "{@Prefix}{@CC} Already enabled!" to the command sender
  27. else:
  28. execute console command "/playsound random.break %command sender% ~ ~ ~ 1 1 1"
  29. message "{@Prefix}{@CC} You don't have permission for that!" to the command sender
  30.  
  31. else if arg-1 is "off" or "disable":
  32. command sender has permission "skript.pyrotechnics":
  33. if {Pyrotechnics.Enabled} is true:
  34. delete {Pyrotechnics.Enabled}
  35. broadcast "{@Prefix}{@CC} Disabled by {@HC}%command sender%!"
  36. loop {Pyrotechnics.List::*}:
  37. delete {Pyrotechnics.HasWater.%loop-value%}
  38. else:
  39. message "{@Prefix}{@CC} Already disabled!" to the command sender
  40. else:
  41. execute console command "/playsound random.break %command sender% ~ ~ ~ 1 1 1"
  42. message "{@Prefix}{@CC} You don't have permission for that!" to the command sender
  43.  
  44.  
  45. else if arg-1 is "toggle" or "switch":
  46. if {Pyrotechnics.Enabled} is true:
  47. command sender command "/pyrotechnics off"
  48. stop trigger
  49. if {Pyrotechnics.Enabled} is not set:
  50. command sender command "/pyrotechnics on"
  51. stop trigger
  52.  
  53. else if arg-1 is "help" or "?" or "question" or "info" or "information":
  54. message "" to the command sender
  55. if command sender has permission "skript.pyrotechnics":
  56. message "{@Prefix}{@CC} /pyrotechnics {@HC}on/off/toggle" to the command sender
  57. message "{@Prefix}{@CC} Scenario by: {@HC}/u/flooft"
  58. if command sender is "Fleft":
  59. message "{@Prefix}{@CC} Skript: {@HC}You!" to the command sender
  60. else:
  61. message "{@Prefix}{@CC} Skript: {@HC}Fleft" to the command sender
  62. message "" to the command sender
  63. message "{@Prefix}{@CC} In {@HC}Pyrotechnics{@CC}, all damage not" to the command sender
  64. message "{@Prefix}{@CC} caused by fire will ignite you. All players" to the command sender
  65. message "{@Prefix}{@CC} start out with a water block!" to the command sender
  66. message "" to the command sender
  67.  
  68. else if arg-1 is not set:
  69. command sender command "/pyrotechnics help"
  70. else:
  71. command sender command "/pyrotechnics help"
  72.  
  73.  
  74.  
  75.  
  76. on login:
  77. {Pyrotechnics.Enabled} is true:
  78. {Pyrotechnics.HasWater.%player%} is not set:
  79. player's inventory has space for 1 water block:
  80. give 1 water block to the player
  81. message "{@Prefix}{@CC} A water block was given to you!" to the player
  82. else:
  83. drop 1 water block at player
  84. message "{@Prefix}{@CC} A water block was dropped near you!" to the player
  85.  
  86.  
  87. on damage of player:
  88. {Pyrotechnics.Enabled} is true:
  89. damage was caused by fire:
  90. stop trigger
  91. else:
  92. ignite the victim
Advertisement
Add Comment
Please, Sign In to add comment