Advertisement
Guest User

Skript

a guest
Jul 12th, 2014
208
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #- HostEssentials - The Basics for running an efficient ultrahardcore game!
  2. #- Written by /u/Mortimier
  3. #- You NEED to have Essentials, PVP Toggle, SimplyVanish, ServerMOTD, and the Ultrahardcore plugin in order for this skript to work.
  4. #- If you don't know how to get or set up these plugins, learn how to do that before using skripts. Please. For everyone's sake.
  5. #- This is much easier to read if you get Notepad++. Google it. You need it. I promise.
  6. #- For help using this skript to its full effectiveness, go to https://docs.google.com/document/d/11ClNMHPyvfG1jxGsMqgjOl32G0uE3OnB6Wr-nyOyOcg/edit?usp=sharing
  7.  
  8. options:
  9. #- Prefix before all broadcasts -#
  10. Pre: &b[&3S&Q&b]&5
  11. #- Prefix before all messages -#
  12. PreMess: &b[&3S&Q&b]&5
  13. #- Prefix before all important broadcasts, mainly /y"
  14. PreImpo: &b[&3S&Q&b]&5
  15. #- Permission for hosts -#
  16. OpPerm: UHCEss.host
  17. #- Message for not being a spectator-#
  18. NotSpecMess: &b[&3S&Q&b]&5 Only Spectators and Hosts can use that command, silly!
  19. #- Message for not having host permissions -#
  20. PermMess: &b[&3S&Q&b]&5 Only Hosts can use that command, silly!
  21. #- List of all skripts to be reloaded after a UHC match -#
  22. VanillaSkripts: HostEssentials, sbutcher, scatter, vote, kickskript, bropvp, pregen, teams
  23. #- Percentage of flint drop rates (if FlintRates is on) -#
  24. GravelPercentage: 75
  25. #- Percentage of apple drop rates (if AppleRates is on) -#
  26. ApplePercentage: 2
  27.  
  28. variables:
  29. {killboard.enabled} = false
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38. #========================#
  39. #========Options=========#
  40. #========================#
  41. variables:
  42. {option::AppleHeads} = false
  43. {option::Weather} = false
  44. {option::DeathRemove} = true
  45. {option::DeathCoords} = false
  46. {option::DeathMessages} = true
  47. {option::DragonMessage} = true
  48. {option::HealthMessage} = true
  49. {option::JoinTeam} = false
  50. {option::KillboardClear} = true
  51. {option::FlintRates} = false
  52. {option::AppleRates} = false
  53. {option::BlazeSpawns} = false
  54. {option::Lobby} = false
  55. {option::DeathAnnounce} = false
  56. {option::JoinAnnounce} = false
  57.  
  58. {optionDesc::AppleHeads} = "If enabled, upon a head being broken, it will drop 2 red apples instead."
  59. {optionDesc::Weather} = "If disabled, rain and thunderstorms will be unable to occur."
  60. {optionDesc::DeathRemove} = "If enabled, upon death, the player will be removed from the whitelist, and will be kicked after 1 minute."
  61. {optionDesc::DeathCoords} = "If enabled, will broadcast the coordinates of a player immediately after that player's death."
  62. {optionDesc::DeathMessages} = "If disabled, death messages will not be displayed in the chat."
  63. {optionDesc::DragonMessage} = "If enabled, upon death of the ender dragon, a death message similar to player death messages will appear for the dragon."
  64. {optionDesc::HealthMessage} = "If enabled, when a player lands an arrow shot, that player will be messaged the victim's health."
  65. {optionDesc::JoinTeam} = "If disabled, the command /jointeam and any variation will be disabled."
  66. {optionDesc::KillboardClear} = "If enabled, 1 minute after a player dies, their spot in the kill scoreboard will be removed."
  67. {optionDesc::FlintRates} = "If enabled, flint will drop %{@FlintPercentage}% percent of the time on mining gravel."
  68. {optionDesc::AppleRates} = "If enabled, apples will drop from all leaves %{@ApplePercentage}% percent of the time"
  69. {optionDesc::BlazeSpawns} = "If enabled, 1 out of every 50 zombie pigmen will spawn as blazes."
  70. {optionDesc::Lobby} = "Upon a player's first time joining the server, they will be teleported to the set lobby position."
  71. {optionDesc::DeathAnnounce} = "If enabled, will announce the death of players in a more noticeable fashion in chat."
  72. {optionDesc::JoinAnnounce} = "If enabled, will announce players joining in a more noticeable fashion in chat."
  73.  
  74. command /option <text> [<text>]:
  75. permission: {@OpPerm}
  76. permission message: {@PermMess}
  77. usage: "/option <on:off:toggle:list:reset> [option]"
  78. aliases: /opt
  79. trigger:
  80. if arg 1 is "list":
  81. message "{@Pre} List of Possible Options"
  82. loop {option::*}:
  83. wait 15 ticks
  84. message "{@Pre} %loop-index% - %loop-value%"
  85. stop trigger
  86. else if arg 1 is "help":
  87. if {option::%arg 2%} is set:
  88. message "{@PreMess} %arg 2%: %{optionDesc::%arg 2%}%"
  89. else:
  90. message "{@PreMess} %arg 2% is not an option!"
  91. stop trigger
  92. if command sender has permission "{@OpPerm}":
  93. if arg 1 is "reset":
  94. loop {option::*}:
  95. delete {option::%loop-index%}
  96. broadcast "{@Pre} Options Reset. The Skript needs to be reloaded."
  97. stop trigger
  98. if {option::%arg 2%} is set:
  99. if arg 1 is equal to "on":
  100. {option::%arg 2%} is true:
  101. message "{@PreMess} Option %arg 2% is already enabled!"
  102. stop trigger
  103. set {option::%arg 2%} to true
  104. broadcast "{@Pre} Option %arg 2% is now enabled!"
  105. stop trigger
  106. else if arg 1 is equal to "off":
  107. {option::%arg 2%} is false:
  108. message "{@PreMess} Option %arg 2% is already disabled!"
  109. stop trigger
  110. set {option::%arg 2%} to false
  111. broadcast "{@Pre} Option %arg 2% is now disabled!"
  112. stop trigger
  113. else if arg 1 is equal to "toggle":
  114. if {option::%arg 2%} is false:
  115. set {option::%arg 2%} to true
  116. broadcast "{@Pre} Option %arg 2% is now enabled!"
  117. stop trigger
  118. if {option::%arg 2%} is true:
  119. set {option::%arg 2%} to false
  120. broadcast "{@Pre} Option %arg 2% is now disabled!"
  121. stop trigger
  122. else:
  123. message "{@Pre} %arg 2% is not an option!"
  124. stop trigger
  125. else:
  126. message "{@PermMess}"
  127.  
  128. on weather change to rain or thunder:
  129. {option::Weather} is false
  130. cancel event
  131.  
  132. on break of head:
  133. {option::AppleHeads} is true
  134. cancel event
  135. delete the block
  136. drop 2 apples
  137.  
  138. on death of player:
  139. {option::DeathRemove} is true
  140. wait 10 seconds
  141. broadcast "{@Pre} &6GoodGame %player%!"
  142.  
  143. on death of player:
  144. {option::DeathRemove} is true
  145. command "/playsoundall random.explode 2"
  146. {SpecPerm::%player%} is false
  147. player is not op:
  148. execute console command "/whitelist remove %player%"
  149. wait 60 seconds
  150. {option::DeathRemove} is true:
  151. {SpecPerm::%player%} is false
  152. player is not op
  153. kick the player due to "{@PreImpo} GG. Thanks for playing!"
  154.  
  155. on death of player:
  156. {option::DeathRemove} is true
  157. {killboard.enabled} is true
  158. wait 30 seconds
  159. command "/scoreboard players reset %victim%"
  160.  
  161. on death of player:
  162. {option::DeathMessages} is false
  163. set the death message to ""
  164.  
  165. on death of Ender Dragon:
  166. {option::DragonMessage} is true
  167. broadcast "Ender Dragon was killed by %attacker%"
  168.  
  169. on damage of player:
  170. {option::HealthMessage} is true
  171. wait 1 tick
  172. attacker is a player:
  173. projectile exists
  174. wait 1 tick
  175. victim is not dead:
  176. message "{@Pre} %Victim% is now at %health of victim*10% percent." to the attacker
  177.  
  178. on death of player:
  179. {option::DeathAnnounce} is true
  180. broadcast "&c&l--------------------------------"
  181. broadcast "&6&l%death message%"
  182. broadcast "&c&l--------------------------------"
  183. set death message to ""
  184.  
  185. on join:
  186. {option::JoinAnnounce} is true
  187. set join message to ""
  188. broadcast "&l&4<<&3&l%player% joined S&Q&l&4>>"
  189.  
  190. on death of player:
  191. {option::KillboardClear} is true
  192. command "/scoreboard players reset %victim%"
  193.  
  194. on death of player:
  195. {option::DeathCoords} is true
  196. {option::DeathMessages} is true
  197. broadcast "{@Pre} %victim% died at %victim's location%"
  198.  
  199.  
  200.  
  201. #========================#
  202. #======MiscCommands======#
  203. #========================#
  204.  
  205. command /givehead <text>:
  206. permission: {@OpPerm}
  207. permission message: {@PermMess}
  208. usage: "/givehead <player>"
  209. description: "Gives you a head of the specified player."
  210. executable by: players
  211. trigger:
  212. make player execute command "/i 397:3 1 player:%arg 1%"
  213. message "{@Pre} Received the head of %arg 1%" to the player
  214.  
  215. command /tphere <player>:
  216. permission: {@OpPerm}
  217. permission message: {@PermMess}
  218. description: "Teleports the specified player to your location."
  219. usage: "/tphere <player>"
  220. executable by: players
  221. trigger:
  222. teleport (arg 1) to (command sender)
  223. message "{@PreMess} %arg 1% was teleported to your location!"
  224. message "{@PreMess} %command sender% teleported you to them!" to arg 1
  225.  
  226. command /cxp [<player>]:
  227. permission: {@OpPerm}
  228. permission message: {@PermMess}
  229. description: "Clears all experience from everyone online, unless a player is specified."
  230. usage: "/cxp [player]"
  231. trigger:
  232. arg 1 is set:
  233. execute console command "/xp -24791L %arg 1%"
  234. message "{@PreMess} &2Your experience has been cleared!" to arg 1
  235. stop trigger
  236. loop all players:
  237. execute console command "/xp -24791L %loop-player%"
  238. message "{@PreMess} Your experience has been cleared!" to loop-player
  239.  
  240. command /y <text>:
  241. permission: {@OpPerm}
  242. permission message: {@PermMess}
  243. description: "Works the same as /broadcast, but with HostEssentials labelling and colors. Also is a shorter command."
  244. usage: "/y <message>"
  245. trigger:
  246. loop all players:
  247. if loop-player has permission "{@OpPerm}":
  248. message "{@PreImpo} %arg 1% &3- %player%" to loop-player
  249. else:
  250. message "{@PreImpo} %arg 1%" to loop-player
  251.  
  252.  
  253. command /kickuhc:
  254. permission: {@OpPerm}
  255. permission message: {@PermMess}
  256. usage: "/kickuhc"
  257. trigger:
  258. loop all players:
  259. if loop-player does not have permission "{@OpPerm}":
  260. kick loop-player due to "{@PreMess} Join Back Later!"
  261.  
  262.  
  263. command /h [<player>]:
  264. executable by: players
  265. trigger:
  266. arg 1 is not set:
  267. message "{@Pre} Your health is %health of player*10% percent." to the player
  268. stop trigger
  269. message "{@Pre} %arg 1%'s health is %health of arg 1*10% percent." to the player
  270.  
  271. on respawn:
  272. wait 1 tick
  273. execute console command "/xp -24761L %player%"
  274.  
  275.  
  276.  
  277. #========================#
  278. #========MuteChat========#
  279. #========================#
  280.  
  281. command /mutechat:
  282. permission: {@OpPerm}
  283. permission message: {@PermMess}
  284. description: "Mutes all players that are not ops."
  285. usage: "/mutechat"
  286. trigger:
  287. if {mute.chat} is true:
  288. set {mute.chat} to false
  289. broadcast "{@Pre} &6All players Unmuted!"
  290. stop trigger
  291. else:
  292. set {mute.chat} to true
  293. broadcast "{@Pre} &6All players have been muted so that the admins talk!"
  294. stop trigger
  295.  
  296. command /mutehelpop:
  297. permission: {@OpPerm}
  298. permission message: {@PermMess}
  299. description: "Turns off /helpop"
  300. usage: "/mutechat"
  301. trigger:
  302. if {mute.helpop} is true:
  303. set {mute.helpop} to false
  304. broadcast "{@Pre} Helpop Enabled!"
  305. stop trigger
  306. else:
  307. set {mute.helpop} to true
  308. broadcast "{@Pre} Helpop Disabled!"
  309. stop trigger
  310.  
  311. on chat:
  312. {mute.chat} is true
  313. player is not op
  314. cancel event
  315. message "{@PreMess} Chat is disabled!" to the player
  316.  
  317. on command "/helpop":
  318. if {mute.helpop} is true:
  319. player is not op
  320. cancel event
  321. message "{@PreMess} /helpop is disabled!" to the player
  322. else:
  323. player is not op
  324. message "{@PreMess} Helpop Successfuly Delivered. Do not spam."
  325. command "/playsound %command sender% note.pling"
  326.  
  327.  
  328.  
  329. #========================#
  330. #========SpamBot=========#
  331. #========================#
  332.  
  333. on chat:
  334. player is not an op
  335. {spambot.enabled} is true
  336. {spambot.timer::%player%} is set:
  337. difference between {spambot.timer::%player%} and now is less than 1 second:
  338. cancel event
  339. message "{@PreMess} Stop Spamming!" to the player
  340. set {spambot.timer::%player%} to now
  341.  
  342. command /spambot <text>:
  343. permission: {@OpPerm}
  344. permission message: {@PermMess}
  345. usage: "/spambot <on:off>"
  346. trigger:
  347. if arg 1 is "on":
  348. if {spambot.enabled} is not true:
  349. set {spambot.enabled} to true
  350. broadcast "{@Pre} SpamBot Enabled!"
  351. else:
  352. message "{@PreMess} SpamBot is already enabled!"
  353. else if arg 1 is "off":
  354. if {spambot.enabled} is not false:
  355. set {spambot.enabled} to false
  356. broadcast "{@Pre} SpamBot Disabled!"
  357. else:
  358. message "{@PreMess} SpamBot is already disabled!"
  359.  
  360. #========================#
  361. #=========Perma==========#
  362. #========================#
  363.  
  364. command /perma <text> [<world>]:
  365. permission: {@OpPerm}
  366. permission message: {@PermMess}
  367. usage: "/perma <day:night:off> <world>"
  368. trigger:
  369. if arg 2 is set:
  370. if arg 1 is "off":
  371. delete {perma.%arg 2%}
  372. broadcast "{@Pre} &2Perma off in world %arg 2%!"
  373. else if arg 1 is "day":
  374. set {perma.%arg 2%} to "day"
  375. broadcast "{@Pre} &2Permaday on in world %arg 2%!"
  376. command sender command "/butcher"
  377. set time in (arg 2) to 9:00
  378. else if arg 1 is "night":
  379. set {perma.%arg 2%} to "night"
  380. broadcast "{@Pre} &2Permaday on in world %arg 2%!"
  381. set time in (arg 2) to 9:00
  382. else:
  383. loop all worlds:
  384. if arg 1 is "off":
  385. delete {perma.%loop-world%}
  386. else if arg 1 is "day":
  387. set {perma.%loop-world%} to "day"
  388. set time in loop-world to 09:00
  389. command sender command "/butcher"
  390. else if arg 1 is "night":
  391. set {perma.%loop-world%} to "night"
  392. set time in loop-world to 21:00
  393. if arg 1 is "off":
  394. broadcast "{@Pre} &2Perma off in all worlds!"
  395. else:
  396. broadcast "{@Pre} &2Perma%arg 1% on in all worlds!"
  397.  
  398. every 5 minutes:
  399. loop all worlds:
  400. if {perma.%loop-world%} is "day":
  401. set time in loop-world to 9:00
  402. else if {perma.%loop-world%} is "night":
  403. set time in loop-world to 21:00
  404.  
  405.  
  406. #========================#
  407. #======UHCTeamSetup======#
  408. #========================#
  409.  
  410. command /setup-teams:
  411. permission: {@OpPerm}
  412. permission message: {@PermMess}
  413. description: "Setup teams and colors for UHC."
  414. trigger:
  415. execute console command "/uhccreateteam UHC1"
  416. execute console command "/uhccreateteam UHC2"
  417. execute console command "/uhccreateteam UHC3"
  418. execute console command "/uhccreateteam UHC4"
  419. execute console command "/uhccreateteam UHC5"
  420. execute console command "/uhccreateteam UHC6"
  421. execute console command "/uhccreateteam UHC7"
  422. execute console command "/uhccreateteam UHC8"
  423. execute console command "/uhccreateteam UHC9"
  424. execute console command "/uhccreateteam UHC10"
  425. execute console command "/uhccreateteam UHC11"
  426. execute console command "/uhccreateteam UHC12"
  427. execute console command "/uhccreateteam UHC13"
  428. execute console command "/uhccreateteam UHC14"
  429. execute console command "/uhccreateteam UHC15"
  430. execute console command "/uhccreateteam UHC16"
  431. execute console command "/uhccreateteam UHC17"
  432. execute console command "/uhccreateteam UHC18"
  433. execute console command "/uhccreateteam UHC19"
  434. execute console command "/uhccreateteam UHC20"
  435. execute console command "/uhccreateteam UHC21"
  436. execute console command "/uhccreateteam UHC22"
  437. execute console command "/uhccreateteam UHC23"
  438. execute console command "/uhccreateteam UHC24"
  439. execute console command "/uhccreateteam UHC25"
  440. execute console command "/uhccreateteam UHC26"
  441. execute console command "/uhccreateteam UHC27"
  442. execute console command "/uhccreateteam UHC28"
  443. execute console command "/uhccreateteam UHC29"
  444. execute console command "/uhccreateteam UHC30"
  445. execute console command "/uhccreateteam UHCOP"
  446. execute console command "/uhccreateteam UHC31"
  447. execute console command "/uhccreateteam UHC32"
  448. execute console command "/uhccreateteam UHC33"
  449. execute console command "/uhccreateteam UHC34"
  450. execute console command "/uhccreateteam UHC35"
  451. execute console command "/uhccreateteam UHC36"
  452. execute console command "/uhccreateteam UHC37"
  453. execute console command "/uhccreateteam UHC38"
  454. execute console command "/uhccreateteam UHC39"
  455. execute console command "/scoreboard teams option UHC1 color aqua"
  456. execute console command "/scoreboard teams option UHC2 color black"
  457. execute console command "/scoreboard teams option UHC3 color blue"
  458. execute console command "/scoreboard teams option UHC4 color bold"
  459. execute console command "/scoreboard teams option UHC5 color dark_aqua"
  460. execute console command "/scoreboard teams option UHC6 color dark_blue"
  461. execute console command "/scoreboard teams option UHC7 color dark_gray"
  462. execute console command "/scoreboard teams option UHC8 color dark_green"
  463. execute console command "/scoreboard teams option UHC9 color dark_purple"
  464. execute console command "/scoreboard teams option UHC10 color dark_red"
  465. execute console command "/scoreboard teams option UHC11 color gold"
  466. execute console command "/scoreboard teams option UHC12 color gray"
  467. execute console command "/scoreboard teams option UHC13 color green"
  468. execute console command "/scoreboard teams option UHC14 color italic"
  469. execute console command "/scoreboard teams option UHC15 color light_purple"
  470. execute console command "/scoreboard teams option UHC16 color red"
  471. execute console command "/scoreboard teams option UHC17 color strikethrough"
  472. execute console command "/scoreboard teams option UHC18 color underline"
  473. execute console command "/scoreboard teams option UHC19 color yellow"
  474. execute console command "/scoreboard teams option UHC20 color white"
  475. execute console command "/scoreboard teams option UHC21 color aqua"
  476. execute console command "/scoreboard teams option UHC22 color black"
  477. execute console command "/scoreboard teams option UHC23 color blue"
  478. execute console command "/scoreboard teams option UHC24 color dark_green"
  479. execute console command "/scoreboard teams option UHC25 color dark_aqua"
  480. execute console command "/scoreboard teams option UHC26 color dark_blue"
  481. execute console command "/scoreboard teams option UHC27 color dark_gray"
  482. execute console command "/scoreboard teams option UHC28 color gold"
  483. execute console command "/scoreboard teams option UHC29 color dark_purple"
  484. execute console command "/scoreboard teams option UHC30 color dark_red"
  485. execute console command "/scoreboard teams option UHC31 color gray"
  486. execute console command "/scoreboard teams option UHC32 color green"
  487. execute console command "/italic UHC21"
  488. execute console command "/italic UHC22"
  489. execute console command "/italic UHC23"
  490. execute console command "/italic UHC24"
  491. execute console command "/italic UHC25"
  492. execute console command "/italic UHC26"
  493. execute console command "/italic UHC27"
  494. execute console command "/italic UHC28"
  495. execute console command "/italic UHC29"
  496. execute console command "/italic UHC30"
  497. execute console command "/underline UHC21"
  498. execute console command "/underline UHC22"
  499. execute console command "/underline UHC23"
  500. execute console command "/underline UHC24"
  501. execute console command "/underline UHC25"
  502. execute console command "/underline UHC26"
  503. execute console command "/underline UHC27"
  504. execute console command "/underline UHC28"
  505. execute console command "/underline UHC29"
  506. execute console command "/underline UHC30"
  507.  
  508. broadcast "{@Pre} UHC teams have been set up!"
  509.  
  510. #========================#
  511. #========Killboard=======#
  512. #========================#
  513. command /killboard <text>:
  514. permission: {@OpPerm}
  515. permission message: {@PermMess}
  516. usage: "/killboard"
  517. trigger:
  518. if arg 1 is "on":
  519. if {killboard.enabled} is not true:
  520. set {killboard.enabled} to true
  521. set {killboard.temp} to a random integer between 1 and 1000
  522. command "/scoreboard objectives add kb%{killboard.temp}% playerKillCount Kills"
  523. execute console command "/scoreboard objectives setdisplay sidebar kb%{killboard.temp}%"
  524. broadcast "{@Pre} Killboard enabled!"
  525. else:
  526. message "{@PreMess} There is already a killboard enabled! If you cannot see one, you need to delete the scoreboard.dat files."
  527. else if arg 1 is "off":
  528. if {killboard.enabled} is true:
  529. set {killboard.enabled} to false
  530. command "/scoreboard objectives remove kb%{killboard.temp}%"
  531. command "/scoreboard objectives setdisplay sidebar off"
  532. delete {killboard.temp}
  533. broadcast "{@Pre} Killboard disabled!"
  534. else:
  535. message "{@PreMess} There is no killboard! If you can see one, you need to delete the scoreboard.dat files."
  536.  
  537. #========================#
  538. #=====CommandDisable=====#
  539. #========================#
  540.  
  541. on command "/jointeam":
  542. player is not op
  543. cancel event
  544. message "{@PreMess} Nice try!"
  545.  
  546. on command "/uhcjointeam":
  547. player is not op
  548. cancel event
  549. message "{@PreMess} Nice try!"
  550.  
  551. on command "/ultrahardcore:jointeam":
  552. player is not op
  553. cancel event
  554. message "{@PreMess} Nice try!"
  555.  
  556. on command "/ultrahardcore:uhcjointeam":
  557. player is not op
  558. cancel event
  559. message "{@PreMess} Nice try!"
  560.  
  561. on command "/bukkit:me":
  562. player is not op
  563. cancel event
  564. message "{@PreMess} Nice try!"
  565.  
  566. on command "/bukkit:kill":
  567. player is not op
  568. cancel event
  569. message "{@PreMess} Nice try!"
  570.  
  571. on command "/msg **":
  572. player is not op
  573. cancel event
  574. message "{@PreMess} Nice try!"
  575.  
  576. on command "/bukkit:msg":
  577. player is not op
  578. cancel event
  579. message "{@PreMess} Nice try!"
  580.  
  581. on command "/bukkit:w":
  582. player is not op
  583. cancel event
  584. message "{@PreMess} Nice try!"
  585.  
  586. #========================#
  587. #=========RunUHC=========#
  588. #========================#
  589.  
  590. command /startuhc <integer> <integer>:
  591. permission: {@OpPerm}
  592. permission message: {@PermMess}
  593. usage: "/startuhc <time until PVP in minutes> <time until meetup in minutes>"
  594. executable by: players
  595. trigger:
  596. if arg 1 is less than 0:
  597. message "{@PreMess} Times cannot be negative!" to the player
  598. stop trigger
  599. if arg 2 is less than 0:
  600. message "{@PreMess} Times cannot be negative!" to the player
  601. stop trigger
  602. broadcast "{@Pre} Game Starting in: 5"
  603. command "/playsoundall random.bow"
  604. wait 1 second
  605. broadcast "{@Pre} Game Starting in: 4"
  606. command "/playsoundall random.bow"
  607. wait 1 second
  608. broadcast "{@Pre} Game Starting in: 3"
  609. command "/playsoundall random.bow"
  610. wait 1 second
  611. broadcast "{@Pre} Game Starting in: 2"
  612. command "/playsoundall random.bow"
  613. wait 1 second
  614. execute console command "/freeze"
  615. broadcast "{@Pre} Game Starting in: 1"
  616. command "/playsoundall random.bow"
  617. wait 1 second
  618. broadcast "{@Pre} Game Starting Now!"
  619. command "/playsoundall random.levelup"
  620. command "/unfreeze"
  621. command "/killboard"
  622. command "/pvp global off"
  623. command "/heal *"
  624. command "/feed *"
  625. loop 20 times:
  626. command sender command "/butcher"
  627. command "/time set day"
  628. command "/bancycle"
  629. set {_pvpseconds} to arg 1*60
  630. if arg 2 is not 0:
  631. set {_meetup} to (arg 2-arg 1)*60
  632. if arg 1 is not 0:
  633. execute console command "/timer %{_pvpseconds}% PVP"
  634. loop 20 times:
  635. make player execute command "/butcher"
  636. loop ({_pvpseconds}+1)*20 times:
  637. wait 1 tick
  638. broadcast "{@Pre} PVP ON!"
  639. execute console command "/pvp global on"
  640. command "/playsoundall random.levelup"
  641. if arg 2 is not 0:
  642. execute console command "/timer %{_meetup}% Meetup"
  643. loop ({_meetup}+1)*20 times:
  644. wait 1 tick
  645. broadcast "{@Pre} Meetup is now! Go to 0,0 Immediately! Only stop for a fight!"
  646. execute console command "/timer 9999999 MEETUP IS NOW"
  647. command "/playsoundall random.levelup"
  648.  
  649.  
  650. command /unfreeze:
  651. permission: {@OpPerm}
  652. permission message: {@PermMess}
  653. trigger:
  654. loop all players:
  655. command "/effect %loop-player% clear"
  656.  
  657.  
  658.  
  659.  
  660. #========================#
  661. #===FakeJoin/FakeLeave===#
  662. #========================#
  663.  
  664. command /fakejoin <text>:
  665. permission: {@OpPerm}
  666. permission message: {@PermMess}
  667. usage: "/fakejoin <player>"
  668. trigger:
  669. broadcast "%arg 1% joined the game"
  670. set {_player} to arg 1 parsed as player
  671. parse error is set:
  672. stop trigger
  673. command "/reappear %{_player}%"
  674.  
  675. command /fakeleave <player>:
  676. permission: {@OpPerm}
  677. permission message: {@PermMess}
  678. usage: "/fakeleave <player>"
  679. trigger:
  680. broadcast "%arg 1% left the game"
  681. command "/v %arg 1%"
  682. command "/vanflag -chat %arg 1%"
  683.  
  684. #========================#
  685. #=======Spectators=======#
  686. #========================#
  687.  
  688. command /setspec <text> [<player>]:
  689. permission: {@OpPerm}
  690. permission message: {@PermMess}
  691. usage: "/setspec <on:off> [player]"
  692. description: "Sets a player as a spectator"
  693. trigger:
  694. if arg 2 is not set:
  695. set {_specplayer} to (command sender)
  696. else:
  697. set {_specplayer} to (arg 2)
  698. arg 1 is "on":
  699. set ({_specplayer})'s gamemode to creative
  700. command "/vanish %{_specplayer}%"
  701. teleport ({_specplayer}) to (command sender)
  702. command "/vanflag %{_specplayer}% +chat"
  703. command "/jointeam UHCOP %{_specplayer}%"
  704. set {SpecPerm::%{_specplayer}%} to true
  705. message "{@PreMess} You are now a spectator!" to ({_specplayer})
  706. message "{@PreMess} Use /tpto <player>, or /tpcoords <X> <Y> <Z> to teleport!" to ({_specplayer})
  707. give ({_specplayer}) a compass
  708. command "/effect %{_specplayer}% 16 1000000 0 true"
  709. command "/effect %{_specplayer}% 1 1000000 1 true"
  710. message "{@PreMess} You gave %{_specplayer}% spectator powers!"
  711. stop trigger
  712. arg 1 is "off":
  713. set ({_specplayer})'s gamemode to survival
  714. execute console command "/reappear %arg 1%"
  715. ({_specplayer}) command "/spawn"
  716. ({_specplayer}) command "/leaveteam"
  717. remove a compass from ({_specplayer})'s inventory
  718. set {SpecPerm::%{_specplayer}%} to false
  719. command "/effect %{_specplayer}% 16 0 10"
  720. command "/effect %{_specplayer}% 1 0 10"
  721. message "{@PreMess} You are no longer a spectator!" to ({_specplayer})
  722. message "{@PreMess} You removed %{_specplayer}%'s spectator powers!" to command sender
  723. stop trigger
  724. message "{@PreMess} The second argument is not valid!" to the player
  725.  
  726. command /speclist:
  727. trigger:
  728. message "{@PreImpo} Current Online Spectators"
  729. message "&6------------------------"
  730. loop all players:
  731. {SpecPerm::%loop-player%} is true
  732. message "&c%loop-player%"
  733.  
  734. command /specreset:
  735. permission: {@OpPerm}
  736. permission message: {@PermMess}
  737. trigger:
  738. loop {SpecPerm::*}:
  739. delete {SpecPerm::%loop-index%}
  740. message "{@PreMess} Spectator Vars Reset!"
  741.  
  742. command /tpcoords <integer> <integer> <integer>:
  743. description: "Teleports you to the specified coordinates."
  744. usage: "/tpcoords <X> <Y> <Z>"
  745. executable by: players
  746. trigger:
  747. {SpecPerm::%player%} is true:
  748. teleport (command sender) to (the location at (arg 1), (arg 2), (arg 3))
  749. message "{@Pre} You have been teleported to %arg 1%, %arg 2%, %arg 3%" to the player
  750. stop trigger
  751. message "{@NotSpecMess}" to the player
  752.  
  753. command /tpto [<player>]:
  754. description: "Teleports you to the specified player. If no player is specified, teleports you to a random player"
  755. usage: "/tpto <player> (player is random if not specified}"
  756. executable by: players
  757. trigger:
  758. {SpecPerm::%player%} is true:
  759. if arg 1 is not set:
  760. set {_rplayer} to (a random player out of all players)
  761. else:
  762. set {_rplayer} to arg 1
  763. teleport (command sender) to {_rplayer}
  764. message "{@PreMess} You have been teleported to %{_rplayer}%" to the player
  765. stop trigger
  766. message "{@NotSpecMess}" to the player
  767.  
  768. on join:
  769. {SpecPerm::%player%} is not set
  770. set {SpecPerm::%player%} to false
  771.  
  772. #========================#
  773. #======API Commands======#
  774. #========================#
  775.  
  776. command /playsoundfrom <player> <text> [<number>]:
  777. permission: operator
  778. usage: "/playsoundfrom <player> <sound> [pitch]"
  779. trigger:
  780. set {_locx} to the x coordinate of arg 1
  781. set {_locy} to the y coordinate of arg 1
  782. set {_locz} to the z coordinate of arg 1
  783. if arg 3 is set:
  784. loop all players:
  785. command "/playsound %arg 2% %loop-player% %{_locx}% %{_locy}% %{_locz}% 1 %arg 3%"
  786. else:
  787. loop all players:
  788. command "/playsound %arg 2% %loop-player% %{_locx}% %{_locy}% %{_locz}%"
  789.  
  790. command /playsoundall <text> [<number>]:
  791. permission: operator
  792. usage: "/playsoundall <sound> [pitch]"
  793. trigger:
  794. loop all players:
  795. if arg 2 is not set:
  796. command "/playsound %arg 1% %loop-player%"
  797. else:
  798. set {_xloc} to loop-player's x coordinate
  799. set {_yloc} to loop-player's y coordinate
  800. set {_zloc} to loop-player's z coordinate
  801. command "/playsound %arg 1% %loop-player% %{_xloc}% %{_yloc}% %{_zloc}% 1 %arg 2%"
  802.  
  803. #Login
  804.  
  805. variables:
  806. {logincount} = 0
  807.  
  808. on login:
  809. add 1 to {logincount}
  810.  
  811. command /logincount:
  812. description: Find out how many people have ever logged into this server
  813. trigger:
  814. message "Since its beginnings <green>%{logincount}%<reset> people have logged into this server"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement