UDON_JP

UHC

May 2nd, 2020
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 50.86 KB | None | 0 0
  1.  
  2.  
  3. #UHC Skript by: MatsGaming on SpigotMC and skUnity
  4.  
  5.  
  6. #Dependencies:
  7. #- Skellett
  8. #- SkQuery
  9. #- skRayFall
  10. #- Skript
  11.  
  12.  
  13. #Config
  14.  
  15.  
  16. #Placeholders:
  17.  
  18. #%player% = name of the player (meant to be used in: joinmessage, leavemessage and rejoinmessage)
  19. #%amount of all players% = the amount of players online (meant to be used in: joinmessage)
  20. #%{maxPlayers}% = the max players that can join your server (meant to be used in: joinmessage)
  21. #%victim% = name of the victim (meant to be used in: timebombexplodemessage, playerdeathmessage and deathmessage)
  22. #%attacker% = name of the attacker (meant to be used in: playerdeathmessage)
  23. #%{winner}% = the winner of the game (meant to be used in: winmessage)
  24.  
  25. options:
  26.  
  27. #Prefix for messages of this Skript
  28. prefix : &8[&4UHC&8]
  29.  
  30.  
  31. #Message shown if a user uses a command, but doesn't have permission
  32. noperm : &cYou are not allowed to use this command
  33.  
  34.  
  35. #Minecraft time at the start of the game (day, night, 0, 5000)
  36. time : 0
  37. #Make the time stuck at the option above
  38. eternaltime : false
  39.  
  40.  
  41. #The size of the worldborder
  42. worldborder : 500
  43. #The size of the worldborder at the deathmatch
  44. deathmatchborder : 50
  45.  
  46.  
  47. #The join message when the game hasn't started
  48. joinmessage : &b%player% &6has joined (%amount of all players%/%{maxPlayers}%)
  49. #The leave message
  50. leavemessage : &b%player% &6has quit
  51. #The rejoin message when the game has started
  52. rejoinmessage : &b%player% &6has rejoined!
  53. #Enable or disable rejoin
  54. rejoin : true
  55.  
  56.  
  57. #Enable or disable the starting items the people with the uhc.admin permission get
  58. startingitems : true
  59. #Title of the starting items
  60. scenarios item : &6&lScenarios &7(Right Click)
  61. start item : &6&lStart the Game &7(Right Click)
  62.  
  63.  
  64. #The minimum players required for the game to automatically start
  65. minplayerstostartgame : 8
  66. #The message everyone gets when the game starts
  67. startmessage : &6Game has started!
  68. #The countdown message everyone gets when there are enough players or when someone did /start
  69. startingtimer : &bStarting in
  70. #The amount of seconds players have to wait until the game starts when there are enough players or when someone did /start (in seconds)
  71. timetostart : 15
  72. #Effects players will get when the game starts
  73. Haste II : false
  74. Speed II : false
  75. Night Vision II : false
  76.  
  77.  
  78. #Enable or disable these gamerules modified by this Skript
  79. mobGriefing : true
  80. doFireTick : true
  81. doMobSpawning : true
  82.  
  83.  
  84. #Enable or disable spectating
  85. spectatormode : true
  86. #Kick message you get when spectating is disabled and you die or try to join
  87. kickmessage : &6You can't join!
  88.  
  89.  
  90. #The message that gets broadcasted when a player gets killed by another player
  91. playerdeathmessage : &b%victim% &6was slain by &b%attacker%
  92. #The message that gets broadcasted when a player gets killed by anything other than a player
  93. deathmessage : &b%victim% &6died!
  94.  
  95.  
  96. #The sound that gets played when an event (like the deathmatch) happens (the default sound id is ONLY for 1.9+)
  97. soundid : ENTITY_WITHER_SPAWN
  98. #The sound that gets played when the start countdown starts (the default sound id is ONLY for 1.9+)
  99. startsoundid : BLOCK_NOTE_PLING
  100.  
  101.  
  102. #The name of Golden Heads
  103. goldenheadname : &6Golden Head
  104.  
  105.  
  106. #The time after the game has started until PvP will be enabled (in seconds)
  107. pvptime : 600
  108. #The message everyone gets when PvP gets enabled
  109. pvpenabled : &6PvP has been enabled!
  110. #The message in the action bar before the PvP timer
  111. pvptimer : &cPvP
  112.  
  113.  
  114. #The time after the game has started until the deathmatch will start (in seconds)
  115. deathmatchtime : 900
  116. #The message everyone gets when the deathmatch starts
  117. deathmatchstarted : &6Deathmatch has started!
  118. #The message in the action bar before the deathmatch timer
  119. deathmatchtimer : &cDeathmatch
  120.  
  121.  
  122. #The message a player gets when using the /revive command on an alive player
  123. alreadyalive : &cThis player is already alive!
  124. #The message a player gets when they get revived
  125. revivemessage : &b%arg-1% &6has been revived!
  126.  
  127.  
  128. #The message everyone gets when a TimeBomb corpse explodes
  129. timebombexplodemessage : &b%victim%&6's corpse has exploded!
  130.  
  131.  
  132. #The time someone can't be attacked by a player when they killed someone if NoClean is enabled (in seconds)
  133. nocleanseconds : 10
  134. #The message players get when they try to attack a player that killed someone if NoClean is enabled
  135. nocleanattack : &cYou can't attack this player!
  136.  
  137.  
  138. #The message everyone gets when a scenario gets enabled
  139. scenarioenablemessage : &ahas been enabled
  140. #The message everyone gets when a scenario gets disabled
  141. scenariodisablemessage : &ahas been disabled
  142. #The colour of the scenarios
  143. scenarioprefix : &e
  144. #The title of the scenario GUI
  145. scenariostitle : &6&lScenarios
  146. #The message you get when trying to enable 2 scenarios that aren't compatible with each other
  147. notcompatible : &cis not compatible with
  148.  
  149.  
  150. #BleedingSweets description
  151. bsline1 : &eWhen a player dies, they drop 1 diamond,
  152. bsline2 : &e5 gold, 16 arrows and 1 string
  153. bsline3 : &e
  154. #BloodDiamonds description
  155. bdline1 : &eYou'll take half a heart of damage when mining a diamond
  156. bdline2 : &e
  157. bdline3 : &e
  158. #Bowless description
  159. bowlessline1 : &ePlayers can't use or craft bows
  160. bowlessline2 : &e
  161. bowlessline3 : &e
  162. #CutClean description
  163. ccline1 : &eOres and animal drops are automatically
  164. ccline2 : &esmelted, no furnaces needed
  165. ccline3 : &e
  166. #Fireless description
  167. firelessline1 : &ePlayers don't take fire damage, but still take lava damage
  168. firelessline2 : &e
  169. firelessline3 : &e
  170. #FlowerPower description
  171. fpline1 : &eWhen a player breaks any random flower,
  172. fpline2 : &ethe flower will drop a random item
  173. fpline3 : &e
  174. #GoldenHeads description
  175. ghline1 : &eWhen a player dies, they will drop their head.
  176. ghline2 : &eWhen you put gold around it, you will get a Golden Head
  177. ghline3 : &e
  178. #GoneFishing description
  179. gfline1 : &eEach player starts with an Unbreaking and Luck of the Sea
  180. gfline2 : &efishing rod along with 64 anvils and 1000 experience levels.
  181. gfline3 : &ePlayers also can't use or craft enchantment tables
  182. #HasteyBoys description
  183. hbline1 : &eWhen you craft a tool, it will automatically
  184. hbline2 : &ebe enchanted with Efficiency III and Unbreaking I
  185. hbline3 : &e
  186. #Horseless description
  187. horselessline1 : &ePlayers can't ride horses
  188. horselessline2 : &e
  189. horselessline3 : &e
  190. #LuckyLeaves description
  191. llline1 : &eLeaves have a 1%% chance of dropping golden apples.
  192. llline2 : &eNormal apples still drop
  193. llline3 : &e
  194. #NoClean description
  195. ncline1 : &eAfter killing someone you'll
  196. ncline2 : &ebe invincible for 10 seconds
  197. ncline3 : &e
  198. #NoFall description
  199. nfline1 : &ePlayers don't take fall damage
  200. nfline2 : &e
  201. nfline3 : &e
  202. #Rodless description
  203. rodlessline1 : &ePlayers can't use or craft fishing rods
  204. rodlessline2 : &e
  205. rodlessline3 : &e
  206. #SkyHigh description
  207. shline1 : &eAny player below Y-101 will begin to take
  208. shline2 : &ehalf a heart of damage every 30 seconds
  209. shline3 : &e
  210. #Timber description
  211. timberline1 : &eBreaking a log of a tree will cause
  212. timberline2 : &ethe whole tree to fall down
  213. timberline3 : &e
  214. #TimeBomb description
  215. tbline1 : &eAfter killing a player, their loot will drop
  216. tbline2 : &einto a chest. 30 seconds later, the chest will explode
  217. tbline3 : &e
  218. #TripleOres description
  219. toline1 : &eOres drop in threes
  220. toline2 : &e
  221. toline3 : &e
  222.  
  223.  
  224. #The apple rate (in percentages)
  225. applerate : 10
  226.  
  227.  
  228. #The message that gets broadcasted when someone wins the game
  229. winmessage : &b%{winner}% &6won the game!
  230. #The message that gets broadcasted when no one wins the game (instead of %{winner}%)
  231. nowinner : &6No one
  232. #The time for your server to stop after someone wins the game (set to 1 to disable) (in seconds)
  233. timetostop : 1
  234. #The message players get when the game ends and they get kicked
  235. endmsg : &6The game has ended!
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.  
  269.  
  270.  
  271.  
  272.  
  273.  
  274.  
  275.  
  276.  
  277.  
  278.  
  279.  
  280.  
  281.  
  282.  
  283.  
  284.  
  285.  
  286.  
  287.  
  288.  
  289.  
  290.  
  291.  
  292.  
  293. #Don't touch anything down here, unless you know what you're doing!
  294.  
  295. command /start:
  296. description: Starts the game
  297. usage: /start
  298. permission: uhc.admin
  299. permission message: {@prefix} {@noperm}
  300. trigger:
  301. if {startused} is false:
  302. set {startused} to true
  303. set action bar of all players to "{@startingtimer} {@timetostart}"
  304. loop {@timetostart} times:
  305. play "{@startsoundid}" to all players at volume 100
  306. wait 1 second
  307. reduce {timestart} by 1
  308. set action bar of all players to "{@startingtimer} %{timestart}%"
  309. set action bar of all players to ""
  310. set {start} to true
  311. play "{@soundid}" to all players at volume 100
  312. if {@eternaltime} is true:
  313. execute console command "/minecraft:gamerule doDaylightCycle false"
  314. execute console command "/minecraft:time set 0 {@time}"
  315. clear all items of all players
  316. execute console command "/minecraft:worldborder set {@worldborder}"
  317. broadcast "{@prefix} {@startmessage}"
  318. clear all effects from all players
  319. if {@Haste II} is true:
  320. execute console command "/minecraft:effect @a minecraft:haste 10000 1 true"
  321. if {@Speed II} is true:
  322. execute console command "/minecraft:effect @a minecraft:speed 10000 1 true"
  323. if {@Night Vision II} is true:
  324. execute console command "/minecraft:effect @a minecraft:night_vision 10000 1 true"
  325. if {gonefishing} is true:
  326. give (fishing rod of luck of the sea 32767 and lure 8) to be unbreakable to all players
  327. give 64 anvil to all players
  328. set level of all players to 1000
  329. loop all players:
  330. add 1 to {totalalive}
  331. set {alive::%loop-player's uuid%} to true
  332. send loop-player title "{@prefix} {@startmessage}" for 3 seconds
  333. execute console command "/minecraft:spreadplayers 0 0 %{spreaddistance}% %{maxrange}% false @a"
  334. execute console command "/minecraft:tp @a ~ 256 ~"
  335. set gamemode of all players to survival
  336. set weather to clear
  337. if {@doFireTick} is true:
  338. execute console command "/minecraft:gamerule doFireTick true"
  339. if {@mobGriefing} is true:
  340. execute console command "/minecraft:gamerule mobGriefing true"
  341. if {@doMobSpawning} is true:
  342. execute console command "/minecraft:gamerule doMobSpawning true"
  343. if {@pvptime} is higher than {@deathmatchtime}:
  344. loop {@pvptime} times:
  345. wait 1 second
  346. reduce {deathmatch} by 1
  347. reduce {pvp} by 1
  348. set action bar of all players to "{@deathmatchtimer}: %{deathmatch}% {@pvptimer}: %{pvp}%"
  349. if {deathmatch} is higher than 0:
  350. set action bar of all players to "{@deathmatchtimer}: %{deathmatch}% {@pvptimer}: %{pvp}%"
  351. else:
  352. set action bar of all players to "{@pvptimer}: %{pvp}%"
  353. if {dmdone} is false:
  354. set {dmdone} to true
  355. execute console command "/minecraft:worldborder set {@deathmatchborder}"
  356. execute console command "/minecraft:spreadplayers 0 0 %{spreaddistancedm}% %{maxrangedm}% false @a"
  357. execute console command "/minecraft:tp @a ~ 256 ~"
  358. broadcast "{@prefix} {@deathmatchstarted}"
  359. loop all players:
  360. send loop-player title "{@prefix} {@deathmatchstarted}" for 3 seconds
  361. set {deathmatchstart} to true
  362. play "{@soundid}" to all players at volume 100
  363. if {pvp} is less than 1:
  364. set action bar of all players to ""
  365. enable pvp in all worlds
  366. broadcast "{@prefix} {@pvpenabled}"
  367. play "{@soundid}" to all players at volume 100
  368. loop all players:
  369. send loop-player title "{@prefix} {@pvpenabled}" for 3 seconds
  370. else:
  371. loop {@deathmatchtime} times:
  372. wait 1 second
  373. reduce {deathmatch} by 1
  374. reduce {pvp} by 1
  375. if {pvp} is higher than 0:
  376. set action bar of all players to "{@deathmatchtimer}: %{deathmatch}% {@pvptimer}: %{pvp}%"
  377. else:
  378. set action bar of all players to "{@deathmatchtimer}: %{deathmatch}%"
  379. enable pvp in all worlds
  380. if {pvpdone} is false:
  381. set {pvpdone} to true
  382. play "{@soundid}" to all players at volume 100
  383. broadcast "{@prefix} {@pvpenabled}"
  384. loop all players:
  385. send loop-player title "{@prefix} {@pvpenabled}" for 3 seconds
  386. if {deathmatch} is less than 1:
  387. set action bar of all players to ""
  388. execute console command "/minecraft:worldborder set {@deathmatchborder}"
  389. execute console command "/minecraft:spreadplayers 0 0 %{spreaddistancedm}% %{maxrangedm}% false @a"
  390. execute console command "/minecraft:tp @a ~ 256 ~"
  391. broadcast "{@prefix} {@deathmatchstarted}"
  392. play "{@soundid}" to all players at volume 100
  393. loop all players:
  394. send loop-player title "{@prefix} {@deathmatchstarted}" for 3 seconds
  395. set {deathmatchstart} to true
  396.  
  397. on command "/minecraft:tp @a ~ 256 ~":
  398. set {falldamage} to false
  399. wait 10 seconds
  400. set {falldamage} to true
  401.  
  402. on command "/minecraft:tp @a ~ 256 ~":
  403. if {deathmatchstart} is false:
  404. set {firedamage} to false
  405. wait 30 seconds
  406. set {firedamage} to true
  407.  
  408. command /revive <player>:
  409. description: Revives a player
  410. usage: /revive [player]
  411. permission: uhc.admin
  412. permission message: {@prefix} {@noperm}
  413. aliases: /resurrect
  414. trigger:
  415. if {start} is true:
  416. if {deathmatchstart} is false:
  417. if {alive::%arg-1's uuid%} is false:
  418. clear all effects from player
  419. if {@Haste II} is true:
  420. execute console command "minecraft:effect %arg-1% minecraft:haste 10000 1 true"
  421. if {@Speed II} is true:
  422. execute console command "minecraft:effect %arg-1% minecraft:speed 10000 1 true"
  423. if {@Night Vision II} is true:
  424. execute console command "minecraft:effect %arg-1% minecraft:night_vision 10000 1 true"
  425. add 1 to {totalalive}
  426. set {alive::%arg-1's uuid%} to true
  427. set arg-1's gamemode to survival
  428. execute console command "/spreadplayers 0 0 %{spreaddistance}% %{maxrange}% false %arg-1%"
  429. send "{@prefix} {@revivemessage}" to arg-1 and player
  430. send arg-1 and player title "{@prefix} {@revivemessage}" for 3 seconds
  431. play "{@soundid}" to arg-1 and player at volume 100
  432. if {gonefishing} is true:
  433. give (fishing rod of luck of the sea 32767 and lure 8) to be unbreakable to arg-1
  434. give 64 anvil to arg-1
  435. set level of arg-1 to 1000
  436. else:
  437. message "{@prefix} {@alreadyalive}"
  438. else:
  439. if {alive::%arg-1's uuid%} is false:
  440. clear all effects from player
  441. if {@Haste II} is true:
  442. execute console command "minecraft:effect %arg-1% minecraft:haste 10000 1 true"
  443. if {@Speed II} is true:
  444. execute console command "minecraft:effect %arg-1% minecraft:speed 10000 1 true"
  445. if {@Night Vision II} is true:
  446. execute console command "minecraft:effect %arg-1% minecraft:night_vision 10000 1 true"
  447. add 1 to {totalalive}
  448. set {alive::%arg-1's uuid%} to true
  449. set arg-1's gamemode to survival
  450. execute console command "/spreadplayers 0 0 %{spreaddistancedm}% %{maxrangedm}% false %arg-1%"
  451. send "{@prefix} {@revivemessage}" to arg-1 and player
  452. send arg-1 and player title "{@prefix} {@revivemessage}" for 3 seconds
  453. if {gonefishing} is true:
  454. give (fishing rod of luck of the sea 32767 and lure 8) to be unbreakable to arg-1
  455. give 64 anvil to arg-1
  456. set level of arg-1 to 1000
  457. else:
  458. message "{@prefix} {@alreadyalive}"
  459.  
  460. on death of a player:
  461. if attacker is a player:
  462. set the death message to "{@prefix} {@playerdeathmessage}"
  463. else:
  464. set the death message to "{@prefix} {@deathmessage}"
  465.  
  466. on Skript start:
  467. set {start} to false
  468. execute console command "/worldborder set 60000000"
  469. execute console command "/gamerule mobGriefing false"
  470. execute console command "/gamerule doFireTick false"
  471. execute console command "/gamerule doMobSpawning false"
  472. set {maxrange} to {@worldborder} / 2
  473. set {spreaddistance} to {maxrange} / 2
  474. set {maxrangedm} to {@deathmatchborder} / 2
  475. set {spreaddistancedm} to {maxrangedm} / 5
  476. set {startused} to false
  477. set {pvp} to {@pvptime}
  478. set {deathmatch} to {@deathmatchtime}
  479. set {timestart} to {@timetostart}
  480. set {pvpdone} to false
  481. set {dmdone} to false
  482. set {nf} to false
  483. set {cc} to false
  484. set {timber} to false
  485. set {Timebomb} to false
  486. set {flowerpower} to false
  487. set {goldenheads} to false
  488. set {hb} to false
  489. set {fireless} to false
  490. set {bowless} to false
  491. set {horseless} to false
  492. set {rodless} to false
  493. set {skyhigh} to false
  494. set {gonefishing} to false
  495. set {luckyleaves} to false
  496. set {noclean} to false
  497. set {bleedingsweets} to false
  498. set {blooddiamonds} to false
  499. set {tripleores} to false
  500. set {winnerbroadcasted} to false
  501. set {totalalive} to 0
  502. set {playercount} to 0
  503. set {damagecounter} to {@timetostart}
  504. add 30 to {damagecounter}
  505. set {falldamage} to true
  506. set {firedamage} to true
  507. set {damage} to true
  508. set {deathmatchstart} to false
  509. set {awinner} to false
  510. execute console command "/gamerule doDaylightCycle true"
  511. clear {winner}
  512. clear {alive::*}
  513. clear {invincible::*}
  514. clear {diamondblock}
  515. disable pvp in all worlds
  516.  
  517. on join:
  518. if {start} is false:
  519. clear player's inventory
  520. set the player's level to 0
  521. if {@startingitems} is true:
  522. if player has permission "uhc.admin":
  523. set slot 2 of player to compass named "{@scenarios item}"
  524. set slot 6 of player to paper named "{@start item}"
  525.  
  526. on rightclick with compass:
  527. if {start} is false:
  528. if {@startingitems} is true:
  529. if name of tool of player is "{@scenarios item}":
  530. make player execute command "/scenarios"
  531.  
  532. on rightclick with paper:
  533. if {start} is false:
  534. if {@startingitems} is true:
  535. if name of tool of player is "{@start item}":
  536. make player execute command "/start"
  537.  
  538. on damage of player:
  539. if {falldamage} is false:
  540. damage cause is fall:
  541. cancel event
  542.  
  543. on damage of player:
  544. if {firedamage} is false:
  545. damage cause is burning:
  546. cancel event
  547.  
  548. on damage of player:
  549. if {damage} is false:
  550. cancel event
  551.  
  552. on death of a player:
  553. if {start} is true:
  554. set {alive::%player's uuid%} to false
  555. remove 1 from {totalalive}
  556. if {totalalive} is less than 2:
  557. set {damage} to false
  558. set {alive::%player's uuid%} to false
  559. loop all players:
  560. if {alive::%loop-player's uuid%} is true:
  561. set {winner} to loop-player
  562. set {awinner} to true
  563. if {awinner} is false:
  564. set {winner} to "{@nowinner}"
  565. if {winnerbroadcasted} is false:
  566. wait 1 tick
  567. play "{@soundid}" to all players at volume 100
  568. broadcast "{@prefix} {@winmessage}"
  569. loop all players:
  570. send loop-player title "{@prefix} {@winmessage}" for 3 seconds
  571. set {winnerbroadcasted} to true
  572. if {@timetostop} is not 1:
  573. wait {@timetostop} seconds
  574. kick all players due to "{@prefix} {@endmsg}"
  575. execute console command "/stop"
  576.  
  577. on kick:
  578. if {start} is true:
  579. if {alive::%player's uuid%} is true:
  580. remove 1 from {totalalive}
  581. if {totalalive} is less than 2:
  582. set {damage} to false
  583. set {alive::%player's uuid%} to false
  584. loop all players:
  585. if {alive::%loop-player's uuid%} is true:
  586. set {winner} to loop-player
  587. set {awinner} to true
  588. if {awinner} is false:
  589. set {winner} to "{@nowinner}"
  590. if {winnerbroadcasted} is false:
  591. wait 1 tick
  592. play "{@soundid}" to all players at volume 100
  593. broadcast "{@prefix} {@winmessage}"
  594. loop all players:
  595. send loop-player title "{@prefix} {@winmessage}" for 3 seconds
  596. set {winnerbroadcasted} to true
  597. if {@timetostop} is not 1:
  598. wait {@timetostop} seconds
  599. kick all players due to "{@prefix} {@endmsg}"
  600. execute console command "/stop"
  601.  
  602. on quit:
  603. if {start} is true:
  604. if {alive::%player's uuid%} is true:
  605. remove 1 from {totalalive}
  606. if {totalalive} is less than 2:
  607. set {damage} to false
  608. set {alive::%player's uuid%} to false
  609. loop all players:
  610. if {alive::%loop-player's uuid%} is true:
  611. set {winner} to loop-player
  612. set {awinner} to true
  613. if {awinner} is false:
  614. set {winner} to "{@nowinner}"
  615. if {winnerbroadcasted} is false:
  616. wait 1 tick
  617. play "{@soundid}" to all players at volume 100
  618. broadcast "{@prefix} {@winmessage}"
  619. loop all players:
  620. send loop-player title "{@prefix} {@winmessage}" for 3 seconds
  621. set {winnerbroadcasted} to true
  622. if {@timetostop} is not 1:
  623. wait {@timetostop} seconds
  624. kick all players due to "{@prefix} {@endmsg}"
  625. execute console command "/stop"
  626.  
  627. on damage:
  628. if {start} is false:
  629. cancel event
  630.  
  631. on death:
  632. if {@spectatormode} is true:
  633. set player's gamemode to spectator
  634. else:
  635. kick player due to "{@prefix} {@kickmessage}"
  636.  
  637. on heal:
  638. if heal cause is not magic_regen or magic:
  639. cancel event
  640.  
  641. on break:
  642. if {start} is false:
  643. cancel event
  644.  
  645. on entity block modify:
  646. if {start} is false:
  647. cancel event
  648.  
  649. on vehicle destroy:
  650. if {start} is false:
  651. cancel event
  652.  
  653. on shoot:
  654. if {start} is false:
  655. cancel event
  656.  
  657. on vehicle enter:
  658. if {start} is false:
  659. cancel event
  660.  
  661. on burn:
  662. if {start} is false:
  663. cancel event
  664.  
  665. on click:
  666. if {start} is false:
  667. cancel event
  668.  
  669. on entity target:
  670. if {start} is false:
  671. cancel event
  672.  
  673. on inventory click:
  674. if {start} is false:
  675. cancel event
  676.  
  677. on join:
  678. if {start} is false:
  679. set player's gamemode to adventure
  680. set player's health to 10
  681. set the player's food level to 10
  682. set join message to "{@prefix} {@joinmessage}"
  683. remove all effects from player
  684. set level of player to 0
  685. add 1 to {playercount}
  686. if {playercount} is equal to {@minplayerstostartgame}:
  687. execute console command "/start"
  688. if {playercount} is more than {@minplayerstostartgame}:
  689. execute console command "/start"
  690.  
  691. on quit:
  692. if {start} is false:
  693. remove 1 from {playercount}
  694.  
  695. on kick:
  696. if {start} is false:
  697. remove 1 from {playercount}
  698.  
  699. on quit:
  700. set quit message to "{@prefix} {@leavemessage}"
  701.  
  702. on server ping:
  703. set {maxPlayers} to max player count
  704.  
  705. on join:
  706. if {@rejoin} is true:
  707. if {start} is true:
  708. if {alive::%player's uuid%} is true:
  709. if {totalalive} is more than 1:
  710. set join message to "{@rejoinmessage}"
  711. add 1 to {totalalive}
  712. else:
  713. if {@spectatormode} is true:
  714. set player's gamemode to spectator
  715. clear inventory of player
  716. set player's health to 10
  717. set the player's food level to 10
  718. set join message to ""
  719. remove all effects from player
  720. set level of player to 0
  721. else:
  722. kick player due to "{@prefix} {@kickmessage}"
  723.  
  724. on join:
  725. if {@rejoin} is false:
  726. if {start} is true:
  727. if {@spectatormode} is true:
  728. set player's gamemode to spectator
  729. clear inventory of player
  730. set player's health to 10
  731. set the player's food level to 10
  732. set join message to ""
  733. remove all effects from player
  734. set level of player to 0
  735. else:
  736. kick player due to "{@prefix} {@kickmessage}"
  737.  
  738. on quit:
  739. if {start} is true:
  740. if {alive::%player's uuid%} is not true:
  741. set quit message to ""
  742.  
  743. on pick up:
  744. if {start} is false:
  745. cancel event
  746.  
  747. on hunger meter change:
  748. if {start} is false:
  749. cancel event
  750.  
  751. on drop:
  752. if {start} is false:
  753. cancel event
  754.  
  755. command /cutclean <text="toggle">:
  756. description: CutClean scenario
  757. usage: /cutclean
  758. permission message: {@prefix} {@noperm}
  759. aliases: /kutklean, /kk, /cc
  760. permission: uhc.admin
  761. trigger:
  762. if arg 1 is "toggle":
  763. if {cc} is true:
  764. set {cc} to false
  765. broadcast "{@prefix} {@scenarioprefix}CutClean {@scenariodisablemessage}"
  766. else:
  767. set {cc} to true
  768. broadcast "{@prefix} {@scenarioprefix}CutClean {@scenarioenablemessage}"
  769.  
  770. on mine of emerald ore:
  771. if {cc} is true:
  772. if {tripleores} is false:
  773. cancel event
  774. set block to air
  775. drop 1 emerald at (location 0.5 above player)
  776. drop 5 xp at (location 0.5 above player)
  777. if player's gamemode is survival:
  778. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  779. damage player's tool by 1
  780. stop
  781.  
  782. on mine of diamond ore:
  783. if {cc} is true:
  784. if {tripleores} is false:
  785. cancel event
  786. set block to air
  787. drop 1 diamond at (location 0.5 above player)
  788. drop 5 xp at (location 0.5 above player)
  789. if player's gamemode is survival:
  790. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  791. damage player's tool by 1
  792. stop
  793.  
  794. on mine of iron ore:
  795. if {cc} is true:
  796. if {tripleores} is false:
  797. cancel event
  798. set block to air
  799. drop 1 iron ingot at (location 0.5 above player)
  800. drop 1 xp at (location 0.5 above player)
  801. if player's gamemode is survival:
  802. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  803. damage player's tool by 1
  804. stop
  805.  
  806. on mine of gold ore:
  807. if {cc} is true:
  808. if {tripleores} is false:
  809. cancel event
  810. set block to air
  811. drop 1 gold ingot at (location 0.5 above player)
  812. drop 1 xp at (location 0.5 above player)
  813. if player's gamemode is survival:
  814. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  815. damage player's tool by 1
  816. stop
  817.  
  818. on mine of redstone ore:
  819. if {cc} is true:
  820. if {tripleores} is false:
  821. cancel event
  822. set block to air
  823. drop 5 redstone at (location 0.5 above player)
  824. drop 3 xp at (location 0.5 above player)
  825. if player's gamemode is survival:
  826. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  827. damage player's tool by 1
  828. stop
  829.  
  830. on mine of nether quartz ore:
  831. if {cc} is true:
  832. if {tripleores} is false:
  833. cancel event
  834. set block to air
  835. drop 1 nether quartz at (location 0.5 above player)
  836. drop 4 xp at (location 0.5 above player)
  837. if player's gamemode is survival:
  838. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  839. damage player's tool by 1
  840. stop
  841.  
  842. on mine of coal ore:
  843. if {cc} is true:
  844. if {tripleores} is false:
  845. cancel event
  846. set block to air
  847. drop 1 coal at (location 0.5 above player)
  848. drop 1 xp at (location 0.5 above player)
  849. if player's gamemode is survival:
  850. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  851. damage player's tool by 1
  852. stop
  853.  
  854. on mine of lapis ore:
  855. if {cc} is true:
  856. if {tripleores} is false:
  857. cancel event
  858. set block to air
  859. drop 6 lapis lazuli at (location 0.5 above player)
  860. drop 2 xp at (location 0.5 above player)
  861. if player's gamemode is survival:
  862. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  863. damage player's tool by 1
  864. stop
  865.  
  866. on mine of gravel:
  867. if {cc} is true:
  868. cancel event
  869. clear dropped items
  870. set block to air
  871. drop 1 flint at (location 0.5 above player)
  872. if player's gamemode is survival:
  873. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  874. damage player's tool by 1
  875. stop
  876.  
  877. on death of a pig:
  878. if {cc} is true:
  879. clear drops
  880. drop (random integer between 1 and 3) of cooked porkchop at the pig
  881.  
  882. on death of a chicken:
  883. if {cc} is true:
  884. clear drops
  885. drop 1 cooked chicken at the chicken
  886. drop (random integer between 0 and 2) of feather at the chicken
  887.  
  888. on death of a cow:
  889. if {cc} is true:
  890. clear drops
  891. drop (random integer between 1 and 3) of steak at the cow
  892. drop (random integer between 0 and 2) of leather at the cow
  893.  
  894. on death of a sheep:
  895. if {cc} is true:
  896. clear drops
  897. drop (random integer between 1 and 2) of cooked mutton at the sheep
  898.  
  899. on death of a rabbit:
  900. if {cc} is true:
  901. clear drops
  902. drop (random integer between 0 and 1) of cooked rabbit at the rabbit
  903. drop (random integer between 0 and 1) of rabbit hide at the rabbit
  904.  
  905. on death of a mooshroom:
  906. if {cc} is true:
  907. clear drops
  908. drop (random integer between 1 and 3) of steak at the mooshroom
  909. drop (random integer between 0 and 2) of leather at the mooshroom
  910.  
  911. command /nofall <text="toggle">:
  912. aliases: /nf
  913. description: NoFall scenario
  914. usage: /nofall
  915. permission message: {@prefix} {@noperm}
  916. permission: uhc.admin
  917. trigger:
  918. if arg 1 is "toggle":
  919. if {nf} is true:
  920. set {nf} to false
  921. broadcast "{@prefix} {@scenarioprefix}NoFall {@scenariodisablemessage}"
  922. else:
  923. set {nf} to true
  924. broadcast "{@prefix} {@scenarioprefix}NoFall {@scenarioenablemessage}"
  925.  
  926. on damage of a player:
  927. damage cause is fall:
  928. if {nf} is true:
  929. cancel event
  930.  
  931. on mine:
  932. event-block is oak log or birch log or acacia log or dark oak log or spruce log:
  933. {timber} is true:
  934. if player's gamemode is survival:
  935. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  936. damage player's tool by 1
  937. set {_tloc.%player's uuid%.1} to location 20 meters below event-block
  938. set {_tloc.%player's uuid%.2} to location 20 meters above event-block
  939. set {_tloc.%player's uuid%.3} to location 5 meters above event-block
  940. loop blocks within {_tloc.%player's uuid%.1} to {_tloc.%player's uuid%.2}:
  941. block below loop-block is dirt or grass block:
  942. block above loop-block is oak log or birch log or acacia log or dark oak log or spruce log:
  943. set {_tloc.%player's uuid%.1} to location 20 meters below event-block
  944. set {_tloc.%player's uuid%.2} to location 20 meters above loop-block
  945. set {_tloc.%player's uuid%.3} to location 5 meters above loop-block
  946. loop blocks within {_tloc.%player's uuid%.1} to {_tloc.%player's uuid%.2}:
  947. loop-block is oak log or birch log or acacia log or dark oak log or spruce log:
  948. break loop-block naturally
  949. play raw sound "dig.wood" at player with pitch 1 volume 5
  950. wait 1 tick
  951. loop blocks in radius 3 of loop-block:
  952. loop-block-2 is oak log or birch log or acacia log or dark oak log or spruce log:
  953. break loop-block-2 naturally
  954. play raw sound "dig.wood" at player with pitch 1 volume 5
  955. wait 1 tick
  956.  
  957.  
  958. on mine of jungle log:
  959. block above event-block is jungle log:
  960. block below event-block is dirt or grass block:
  961. {timber} is true:
  962. if player's gamemode is survival:
  963. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  964. damage player's tool by 1
  965. set {tloc.%player's uuid%.1} to location of event-block
  966. set {tloc.%player's uuid%.2} to location 40 meters above event-block
  967. set {tloc.%player's uuid%.3} to location 23 meters above event-block
  968. loop blocks within {tloc.%player's uuid%.1} to {tloc.%player's uuid%.2}:
  969. wait 1 ticks
  970. loop-block is jungle log:
  971. break loop-block naturally
  972. play raw sound "dig.wood" at player with pitch 1 volume 5
  973. loop blocks in radius 10 around {tloc.%player's uuid%.3}:
  974. wait 1 tick
  975. loop-block is jungle leaves:
  976. break loop-block naturally
  977. play raw sound "dig.wood" at player with pitch 1 volume 5
  978. delete {tloc.%player's uuid%.1}
  979. delete {tloc.%player's uuid%.2}
  980. delete {tloc.%player's uuid%.3}
  981.  
  982. command /timber <text="toggle">:
  983. description: Timber scenario
  984. usage: /timber
  985. permission message: {@prefix} {@noperm}
  986. permission: uhc.admin
  987. trigger:
  988. if arg 1 is "toggle":
  989. if {timber} is true:
  990. set {timber} to false
  991. broadcast "{@prefix} {@scenarioprefix}Timber {@scenariodisablemessage}"
  992. else:
  993. set {timber} to true
  994. broadcast "{@prefix} {@scenarioprefix}Timber {@scenarioenablemessage}"
  995.  
  996. command /timebomb <text="toggle">:
  997. description: TimeBomb scenario
  998. usage: /timebomb
  999. permission message: {@prefix} {@noperm}
  1000. permission: uhc.admin
  1001. aliases: /tb
  1002. trigger:
  1003. if arg 1 is "toggle":
  1004. if {Timebomb} is true:
  1005. set {Timebomb} to false
  1006. broadcast "{@prefix} {@scenarioprefix}TimeBomb {@scenariodisablemessage}"
  1007. else:
  1008. set {Timebomb} to true
  1009. broadcast "{@prefix} {@scenarioprefix}TimeBomb {@scenarioenablemessage}"
  1010.  
  1011. on death of player:
  1012. {Timebomb} is true
  1013. set block at block at victim's location to chest
  1014. set {_loc} to the block at victim's location
  1015. set {_chest} to block at victim's location
  1016. set block at block left of {_chest} to chest
  1017. if {bleedingsweets} is true:
  1018. add 1 diamond, 5 gold ingots, 16 arrows and 1 string to the block at {_chest}
  1019. if {goldenheads} is true:
  1020. add victim's skull to the block at {_chest}
  1021. add victim's inventory to the block at {_chest}
  1022. add the victim's helmet slot to the inventory of the block at {_chest}
  1023. add the victim's chestplate slot to the inventory of the block at {_chest}
  1024. add the victim's leggings slot to the inventory of the block at {_chest}
  1025. add the victim's boots slot to the inventory of the block at {_chest}
  1026. clear drops
  1027. set {_time.%victim%} to 30
  1028. loop 30 times:
  1029. add -1 to {_time.%victim%}
  1030. wait 1 second
  1031. set block at {_chest} to air
  1032. set block at {_loc} to air
  1033. wait 3 ticks
  1034. create an explosion of force 20 at {_chest}
  1035. strike lightning effect at {_chest}
  1036. broadcast "{@prefix} {@timebombexplodemessage}"
  1037.  
  1038. command /flowerpower <text="toggle">:
  1039. description: FlowerPower scenario
  1040. usage: /flowerpower
  1041. permission message: {@prefix} {@noperm}
  1042. aliases: /fp
  1043. permission: uhc.admin
  1044. trigger:
  1045. if arg 1 is "toggle":
  1046. if {flowerpower} is true:
  1047. set {flowerpower} to false
  1048. broadcast "{@prefix} {@scenarioprefix}FlowerPower {@scenariodisablemessage}"
  1049. else:
  1050. set {flowerpower} to true
  1051. broadcast "{@prefix} {@scenarioprefix}FlowerPower {@scenarioenablemessage}"
  1052.  
  1053. on item spawning of all flowers:
  1054. if {flowerpower} is true:
  1055. cancel event
  1056. drop (random number between 1 and 9) of random item out of all items at (location 0.5 above)
  1057. drop 1 xp
  1058.  
  1059. on break of dead bush:
  1060. if {flowerpower} is true:
  1061. cancel event
  1062. set block to air
  1063. drop (random number between 1 and 9) of random item out of all items at (location 0.5 above)
  1064. drop 1 xp
  1065.  
  1066. on script load:
  1067. register new shaped recipe for golden apple named "{@goldenheadname}" using gold ingot, gold ingot, gold ingot, gold ingot, player head, gold ingot, gold ingot, gold ingot, gold ingot
  1068.  
  1069. command /goldenheads <text="toggle">:
  1070. description: GoldenHeads scenario
  1071. usage: /goldenheads
  1072. permission message: {@prefix} {@noperm}
  1073. aliases: /gh, /goldenhead, /goldhead
  1074. permission: uhc.admin
  1075. trigger:
  1076. if arg 1 is "toggle":
  1077. if {goldenheads} is true:
  1078. set {goldenheads} to false
  1079. broadcast "{@prefix} {@scenarioprefix}GoldenHeads {@scenariodisablemessage}"
  1080. else:
  1081. set {goldenheads} to true
  1082. broadcast "{@prefix} {@scenarioprefix}GoldenHeads {@scenarioenablemessage}"
  1083.  
  1084. on craft of golden apple:
  1085. name of item contains "{@goldenheadname}":
  1086. {goldenheads} is false
  1087. cancel event
  1088.  
  1089. on consume of golden apple:
  1090. name of player's tool contains "{@goldenheadname}":
  1091. apply regeneration 2 to the player for 10 seconds
  1092.  
  1093. command /hasteyboys <text="toggle">:
  1094. description: HasteyBoys scenario
  1095. usage: /hasteyboys
  1096. permission message: {@prefix} {@noperm}
  1097. aliases: /hb
  1098. permission: uhc.admin
  1099. trigger:
  1100. if arg 1 is "toggle":
  1101. if {hb} is true:
  1102. set {hb} to false
  1103. broadcast "{@prefix} {@scenarioprefix}HasteyBoys {@scenariodisablemessage}"
  1104. else:
  1105. set {hb} to true
  1106. broadcast "{@prefix} {@scenarioprefix}HasteyBoys {@scenarioenablemessage}"
  1107.  
  1108. on inventory click:
  1109. {hb} is true
  1110. wait 1 tick
  1111. loop all items in the player's inventory:
  1112. loop-item is axe or pickaxe or shovel
  1113. enchant loop-item with efficiency 3 and unbreaking 1
  1114.  
  1115. command /fireless <text="toggle">:
  1116. permission: uhc.admin
  1117. description: Fireless scenario
  1118. usage: /fireless
  1119. permission message: {@prefix} {@noperm}
  1120. trigger:
  1121. if arg 1 is "toggle":
  1122. if {fireless} is true:
  1123. set {fireless} to false
  1124. broadcast "{@prefix} {@scenarioprefix}Fireless {@scenariodisablemessage}"
  1125. else:
  1126. set {fireless} to true
  1127. broadcast "{@prefix} {@scenarioprefix}Fireless {@scenarioenablemessage}"
  1128.  
  1129. on death of player:
  1130. wait 0.2 seconds
  1131. force victim to respawn
  1132.  
  1133. on death of player:
  1134. if {goldenheads} is true:
  1135. if {Timebomb} is false:
  1136. drop victim's skull at location of victim
  1137.  
  1138. on damage of a player:
  1139. damage cause is burning:
  1140. if {fireless} is true:
  1141. cancel event
  1142.  
  1143. on damage of a player:
  1144. damage cause is lava:
  1145. if {fireless} is true:
  1146. cancel event
  1147.  
  1148. command /bowless <text="toggle">:
  1149. permission: uhc.admin
  1150. description: Bowless scenario
  1151. usage: /bowless
  1152. permission message: {@prefix} {@noperm}
  1153. trigger:
  1154. if arg 1 is "toggle":
  1155. if {bowless} is true:
  1156. set {bowless} to false
  1157. broadcast "{@prefix} {@scenarioprefix}Bowless {@scenariodisablemessage}"
  1158. else:
  1159. set {bowless} to true
  1160. broadcast "{@prefix} {@scenarioprefix}Bowless {@scenarioenablemessage}"
  1161.  
  1162. on right click:
  1163. if {bowless} is true:
  1164. if player's tool is a bow:
  1165. remove bow from player's inventory
  1166.  
  1167. on crafting of bow:
  1168. if {bowless} is true:
  1169. cancel event
  1170.  
  1171. command /rodless <text="toggle">:
  1172. permission: uhc.admin
  1173. description: Rodless scenario
  1174. usage: /rodless
  1175. permission message: {@prefix} {@noperm}
  1176. trigger:
  1177. if arg 1 is "toggle":
  1178. if {rodless} is true:
  1179. set {rodless} to false
  1180. broadcast "{@prefix} {@scenarioprefix}Rodless {@scenariodisablemessage}"
  1181. else:
  1182. if {gonefishing} is false:
  1183. set {rodless} to true
  1184. broadcast "{@prefix} {@scenarioprefix}Rodless {@scenarioenablemessage}"
  1185. else:
  1186. set {rodless} to false
  1187. broadcast "{@prefix} {@scenarioprefix}Rodless {@notcompatible} {@scenarioprefix}GoneFishing"
  1188.  
  1189. on right click:
  1190. if {rodless} is true:
  1191. if player's tool is a fishing rod:
  1192. remove fishing rod from player's inventory
  1193.  
  1194. on crafting of fishing rod:
  1195. if {rodless} is true:
  1196. cancel event
  1197.  
  1198. command /horseless <text="toggle">:
  1199. permission: uhc.admin
  1200. description: Horseless scenario
  1201. usage: /horseless
  1202. permission message: {@prefix} {@noperm}
  1203. trigger:
  1204. if arg 1 is "toggle":
  1205. if {horseless} is true:
  1206. set {horseless} to false
  1207. broadcast "{@prefix} {@scenarioprefix}Horseless {@scenariodisablemessage}"
  1208. else:
  1209. set {horseless} to true
  1210. broadcast "{@prefix} {@scenarioprefix}Horseless {@scenarioenablemessage}"
  1211.  
  1212. on rightclick on horse:
  1213. if {horseless} is true:
  1214. cancel event
  1215.  
  1216. command /gonefishing <text="toggle">:
  1217. aliases: /gf
  1218. permission: uhc.admin
  1219. description: GoneFishing scenario
  1220. usage: /gonefishing
  1221. permission message: {@prefix} {@noperm}
  1222. trigger:
  1223. if arg 1 is "toggle":
  1224. if {gonefishing} is true:
  1225. set {gonefishing} to false
  1226. broadcast "{@prefix} {@scenarioprefix}GoneFishing {@scenariodisablemessage}"
  1227. if {start} is true:
  1228. remove (fishing rod of luck of the sea 32767 and lure 8) to be unbreakable from all players
  1229. remove 64 anvil from all players
  1230. set level of all players to 0
  1231. else:
  1232. set {gonefishing} to true
  1233. if {rodless} is false:
  1234. broadcast "{@prefix} {@scenarioprefix}GoneFishing {@scenarioenablemessage}"
  1235. if {start} is true:
  1236. give (fishing rod of luck of the sea 32767 and lure 8) to be unbreakable to all players
  1237. give 64 anvil to all players
  1238. set level of all players to 1000
  1239. else:
  1240. set {gonefishing} to false
  1241. broadcast "{@prefix} {@scenarioprefix}GoneFishing {@notcompatible} {@scenarioprefix}Rodless"
  1242.  
  1243. on right click on enchantment table:
  1244. if {gonefishing} is true:
  1245. cancel event
  1246.  
  1247. on place of enchantment table:
  1248. if {gonefishing} is true:
  1249. cancel event
  1250. remove enchantment table from player's inventory
  1251.  
  1252. on crafting of enchantment table:
  1253. if {gonefishing} is true:
  1254. cancel event
  1255.  
  1256. command /luckyleaves <text="toggle">:
  1257. permission: uhc.admin
  1258. description: LuckyLeaves scenario
  1259. usage: /luckyleaves
  1260. aliases: /ll
  1261. permission message: {@prefix} {@noperm}
  1262. trigger:
  1263. if arg 1 is "toggle":
  1264. if {luckyleaves} is true:
  1265. set {luckyleaves} to false
  1266. broadcast "{@prefix} {@scenarioprefix}LuckyLeaves {@scenariodisablemessage}"
  1267. else:
  1268. set {luckyleaves} to true
  1269. broadcast "{@prefix} {@scenarioprefix}LuckyLeaves {@scenarioenablemessage}"
  1270.  
  1271. on break of leaves:
  1272. if {luckyleaves} is true:
  1273. chance of 1%:
  1274. drop 1 golden apple
  1275.  
  1276. on leaves decay:
  1277. if {luckyleaves} is true:
  1278. chance of 1%:
  1279. drop 1 golden apple
  1280.  
  1281. on break of leaves:
  1282. chance of {@applerate}%:
  1283. drop 1 apple
  1284.  
  1285. on leaves decay:
  1286. chance of {@applerate}%:
  1287. drop 1 apple
  1288.  
  1289. command /noclean <text="toggle">:
  1290. permission: uhc.admin
  1291. description: NoClean scenario
  1292. usage: /noclean
  1293. aliases: /nc
  1294. permission message: {@prefix} {@noperm}
  1295. trigger:
  1296. if arg 1 is "toggle":
  1297. if {noclean} is true:
  1298. set {noclean} to false
  1299. broadcast "{@prefix} {@scenarioprefix}NoClean {@scenariodisablemessage}"
  1300. else:
  1301. set {noclean} to true
  1302. broadcast "{@prefix} {@scenarioprefix}NoClean {@scenarioenablemessage}"
  1303.  
  1304. on death:
  1305. if {noclean} is true:
  1306. if victim is a player:
  1307. set {invincible::%attacker%} to true
  1308. wait {@nocleanseconds} seconds
  1309. set {invincible::%attacker%} to false
  1310.  
  1311. on damage:
  1312. if {noclean} is true:
  1313. if attacker is player:
  1314. if victim is player:
  1315. if {invincible::%attacker%} is true:
  1316. cancel event
  1317. message "{@prefix} {@nocleanattack}"
  1318.  
  1319. on damage:
  1320. if {noclean} is true:
  1321. if attacker is player:
  1322. if victim is player:
  1323. if {invincible::%victim%} is true:
  1324. cancel event
  1325. message "{@prefix} {@nocleanattack}"
  1326.  
  1327. command /blooddiamonds <text="toggle">:
  1328. permission: uhc.admin
  1329. description: BloodDiamonds scenario
  1330. usage: /blooddiamonds
  1331. aliases: /bd
  1332. permission message: {@prefix} {@noperm}
  1333. trigger:
  1334. if arg 1 is "toggle":
  1335. if {blooddiamonds} is true:
  1336. set {blooddiamonds} to false
  1337. broadcast "{@prefix} {@scenarioprefix}BloodDiamonds {@scenariodisablemessage}"
  1338. else:
  1339. set {blooddiamonds} to true
  1340. broadcast "{@prefix} {@scenarioprefix}BloodDiamonds {@scenarioenablemessage}"
  1341.  
  1342. on mine of diamond ore:
  1343. if {blooddiamonds} is true:
  1344. damage player by 1/2 hearts
  1345.  
  1346. command /bleedingsweets <text="toggle">:
  1347. permission: uhc.admin
  1348. description: BleedingSweets scenario
  1349. usage: /bleedingsweets
  1350. aliases: /bs
  1351. permission message: {@prefix} {@noperm}
  1352. trigger:
  1353. if arg 1 is "toggle":
  1354. if {bleedingsweets} is true:
  1355. set {bleedingsweets} to false
  1356. broadcast "{@prefix} {@scenarioprefix}BleedingSweets {@scenariodisablemessage}"
  1357. else:
  1358. set {bleedingsweets} to true
  1359. broadcast "{@prefix} {@scenarioprefix}BleedingSweets {@scenarioenablemessage}"
  1360.  
  1361. on death of player:
  1362. if {bleedingsweets} is true:
  1363. if {Timebomb} is false:
  1364. drop 1 diamond, 5 gold ingots, 16 arrows and 1 string at the victim
  1365.  
  1366. command /tripleores <text="toggle">:
  1367. description: TripleOres scenario
  1368. usage: /tripleores
  1369. permission message: {@prefix} {@noperm}
  1370. aliases: /to
  1371. permission: uhc.admin
  1372. trigger:
  1373. if arg 1 is "toggle":
  1374. if {tripleores} is true:
  1375. set {tripleores} to false
  1376. broadcast "{@prefix} {@scenarioprefix}TripleOres {@scenariodisablemessage}"
  1377. else:
  1378. set {tripleores} to true
  1379. broadcast "{@prefix} {@scenarioprefix}TripleOres {@scenarioenablemessage}"
  1380.  
  1381. command /timeleft:
  1382. description: Shows the timers in chat
  1383. usage: /timeleft
  1384. aliases: /tl
  1385. trigger:
  1386. if {start} is true:
  1387. if {deathmatchstart} is false:
  1388. message "{@deathmatchtimer}: %{deathmatch}%"
  1389. if {pvpdone} is false:
  1390. message "{@pvptimer}: %{pvp}%"
  1391. else:
  1392. if {startused} is true:
  1393. message "{@startingtimer} %{timestart}%"
  1394.  
  1395. on mine of emerald ore:
  1396. if {tripleores} is true:
  1397. cancel event
  1398. set block to air
  1399. drop 3 emeralds at (location 0.5 above player)
  1400. drop 5 xp at (location 0.5 above player)
  1401. if player's gamemode is survival:
  1402. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1403. damage player's tool by 1
  1404. stop
  1405.  
  1406. on mine of diamond ore:
  1407. if {tripleores} is true:
  1408. cancel event
  1409. set block to air
  1410. drop 3 diamonds at (location 0.5 above player)
  1411. drop 5 xp at (location 0.5 above player)
  1412. if player's gamemode is survival:
  1413. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1414. damage player's tool by 1
  1415. stop
  1416.  
  1417. on mine of iron ore:
  1418. if {tripleores} is true:
  1419. if {cc} is true:
  1420. cancel event
  1421. set block to air
  1422. drop 3 iron ingots at (location 0.5 above player)
  1423. drop 1 xp at (location 0.5 above player)
  1424. if player's gamemode is survival:
  1425. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1426. damage player's tool by 1
  1427. stop
  1428. else:
  1429. cancel event
  1430. set block to air
  1431. drop 3 iron ore at (location 0.5 above player)
  1432. if player's gamemode is survival:
  1433. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1434. damage player's tool by 1
  1435. stop
  1436.  
  1437. on mine of gold ore:
  1438. if {tripleores} is true:
  1439. if {cc} is true:
  1440. cancel event
  1441. set block to air
  1442. drop 3 gold ingots at (location 0.5 above player)
  1443. drop 1 xp at (location 0.5 above player)
  1444. if player's gamemode is survival:
  1445. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1446. damage player's tool by 1
  1447. stop
  1448. else:
  1449. cancel event
  1450. set block to air
  1451. drop 3 gold ore at (location 0.5 above player)
  1452. if player's gamemode is survival:
  1453. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1454. damage player's tool by 1
  1455. stop
  1456.  
  1457. on mine of redstone ore:
  1458. if {tripleores} is true:
  1459. cancel event
  1460. set block to air
  1461. drop 3 redstone at (location 0.5 above player)
  1462. drop 3 xp at (location 0.5 above player)
  1463. if player's gamemode is survival:
  1464. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1465. damage player's tool by 1
  1466. stop
  1467.  
  1468. on mine of nether quartz ore:
  1469. if {tripleores} is true:
  1470. cancel event
  1471. set block to air
  1472. drop 3 nether quartz at (location 0.5 above player)
  1473. drop 4 xp at (location 0.5 above player)
  1474. if player's gamemode is survival:
  1475. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1476. damage player's tool by 1
  1477. stop
  1478.  
  1479. on mine of coal ore:
  1480. if {tripleores} is true:
  1481. cancel event
  1482. set block to air
  1483. drop 3 coal at (location 0.5 above player)
  1484. drop 1 xp at (location 0.5 above player)
  1485. if player's gamemode is survival:
  1486. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1487. damage player's tool by 1
  1488. stop
  1489.  
  1490. on mine of lapis ore:
  1491. if {tripleores} is true:
  1492. cancel event
  1493. set block to air
  1494. drop 3 lapis lazuli at (location 0.5 above player)
  1495. drop 2 xp at (location 0.5 above player)
  1496. if player's gamemode is survival:
  1497. if player's tool is a sword, a shovel, a pickaxe, an axe or a hoe:
  1498. damage player's tool by 1
  1499. stop
  1500.  
  1501. command /skyhigh <text="toggle">:
  1502. description: SkyHigh scenario
  1503. usage: /skyhigh
  1504. permission message: {@prefix} {@noperm}
  1505. aliases: /sh
  1506. permission: uhc.admin
  1507. trigger:
  1508. if arg 1 is "toggle":
  1509. if {skyhigh} is true:
  1510. set {skyhigh} to false
  1511. broadcast "{@prefix} {@scenarioprefix}SkyHigh {@scenariodisablemessage}"
  1512. else:
  1513. set {skyhigh} to true
  1514. broadcast "{@prefix} {@scenarioprefix}SkyHigh {@scenarioenablemessage}"
  1515.  
  1516. every 30 seconds:
  1517. if {skyhigh} is true:
  1518. loop all players:
  1519. if loop-player is in "world":
  1520. if loop-player's y-coordinate is between 0 and 101:
  1521. damage loop-player by 0.5 hearts
  1522.  
  1523. command /scenarios:
  1524. description: Enable and disable the scenarios
  1525. usage: /scenarios
  1526. permission: uhc.admin
  1527. permission message: {@prefix} {@noperm}
  1528. aliases: /scenario
  1529. trigger:
  1530. open chest with 3 rows named "{@scenariostitle}" to player
  1531. wait 1 tick
  1532. format slot 0 of player with sugar named "{@scenarioprefix}BleedingSweets" with lore "{@bsline1}", "{@bsline2}" and "{@bsline3}" to run "bs"
  1533. format slot 1 of player with diamond named "{@scenarioprefix}BloodDiamonds" with lore "{@bdline1}", "{@bdline2}" and "{@bdline3}" to run "bd"
  1534. format slot 2 of player with bow named "{@scenarioprefix}Bowless" with lore "{@bowlessline1}", "{@bowlessline2}" and "{@bowlessline3}" to run "bowless"
  1535. format slot 3 of player with iron ingot named "{@scenarioprefix}CutClean" with lore "{@ccline1}", "{@ccline2}" and "{@ccline3}" to run "cc"
  1536. format slot 4 of player with flint and steel named "{@scenarioprefix}Fireless" with lore "{@firelessline1}" and "{@firelessline2}", "{@firelessline3}" to run "fireless"
  1537. format slot 5 of player with dandelion named "{@scenarioprefix}FlowerPower" with lore "{@fpline1}", "{@fpline2}" and "{@fpline3}" to run "fp"
  1538. format slot 6 of player with golden apple named "{@scenarioprefix}GoldenHeads" with lore "{@ghline1}", "{@ghline2}" and "{@ghline3}" to run "gh"
  1539. format slot 7 of player with raw fish named "{@scenarioprefix}GoneFishing" with lore "{@gfline1}", "{@gfline2}" and "{@gfline3}" to run "gf"
  1540. format slot 8 of player with iron pickaxe named "{@scenarioprefix}HasteyBoys" with lore "{@hbline1}", "{@hbline2}" and "{@hbline3}" to run "hb"
  1541. format slot 9 of player with saddle named "{@scenarioprefix}Horseless" with lore "{@horselessline1}", "{@horselessline2}" and "{@horselessline3}" to run "horseless"
  1542. format slot 10 of player with oak leaves named "{@scenarioprefix}LuckyLeaves" with lore "{@llline1}", "{@llline2}" and "{@llline3}" to run "ll"
  1543. format slot 11 of player with nether quartz named "{@scenarioprefix}NoClean" with lore "{@ncline1}", "{@ncline2}" and "{@ncline3}" to run "nc"
  1544. format slot 12 of player with diamond boots named "{@scenarioprefix}NoFall" with lore "{@nfline1}", "{@nfline2}" and "{@nfline3}" to run "nf"
  1545. format slot 13 of player with fishing rod named "{@scenarioprefix}Rodless" with lore "{@rodlessline1}", "{@rodlessline2}" and "{@rodlessline3}" to run "rodless"
  1546. format slot 14 of player with grass block named "{@scenarioprefix}SkyHigh" with lore "{@shline1}", "{@shline2}" and "{@shline3}" to run "skyhigh"
  1547. format slot 15 of player with diamond axe named "{@scenarioprefix}Timber" with lore "{@timberline1}", "{@timberline2}" and "{@timberline3}" to run "timber"
  1548. format slot 16 of player with tnt named "{@scenarioprefix}TimeBomb" with lore "{@tbline1}", "{@tbline2}" and "{@tbline3}" to run "tb"
  1549. format slot 17 of player with gold ore named "{@scenarioprefix}TripleOres" with lore "{@toline1}", "{@toline2}" and "{@toline3}" to run "to"
Add Comment
Please, Sign In to add comment