Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- options:
- P: [&2UHC&r]
- variables:
- {timer.going} = false
- command /startuhc <integer> <integer> <world> <world>:
- usage: /startuhc <PvP> <MU> <world> <netherworld>
- permission: skript.op
- trigger:
- if {timer.going} is true:
- message "{@P} &7The timer is currently going. Use &7/stopuhc &7to stop the current timer!"
- else if {timer.going} is false:
- set {timer.going} to true
- set {first.time} to true
- set {pvp} to arg 1
- set {mu} to arg 2
- set {_loc} to location of command sender
- if {gamemode} is set:
- command sender command "/setmotd %{gamemode}% %{teamsize}% | %{utc}% UTC"
- command sender command "/ks off"
- command sender command "/ks on"
- command sender command "/spectatorinfo reset"
- command sender command "/gm 1"
- command sender command "/mw goto %arg-3%"
- command sender command "/butcher"
- command sender command "/difficulty HARD"
- command sender command "/tppos 0 242 0 "
- command sender command "//pos1 6,239,-6"
- command sender command "//pos2 -6,228,6"
- command sender command "//set air"
- command sender command "/rg delete box"
- loop all players:
- set the loop-player's food level to 10
- heal the loop-player
- execute console command "/xp -50000L %loop-player%"
- execute console command "/feature on PotionNerfs"
- execute console command "/feature on PlayerHeads"
- execute console command "/feature on PortalRanges"
- execute console command "/feature on DeathLightning"
- execute console command "/mw setflag %arg-3% PvP deny"
- execute console command "/timer cancel"
- command sender command "/mw link %arg-3% %arg-4%"
- command sender command "/mw link %arg-4% %arg-3%"
- broadcast "{@P} &7Game starting in..."
- wait 1 second
- broadcast "{@P} &43!"
- wait 1 second
- broadcast "{@P} &c2!"
- wait 1 second
- broadcast "{@P} &e1!"
- wait 1 second
- broadcast "{@P} &aGo!"
- command sender command "/day"
- command sender command "/gm 0"
- execute console command "/freeze"
- execute console command "/timer %({pvp}*60)% &7PvP:&a"
- teleport the command sender to {_loc}
- delete {_loc}
- heal all players
- loop all players:
- execute console command "/effect %loop-player% clear"
- apply saturation to all players for 2 minutes
- apply resistance 10 to all players for 10 seconds
- wait 1 seconds
- broadcast "&7-----------------&r{@P}&7-----------------"
- broadcast " &aPvP will be enabled in %{pvp}% minutes"
- broadcast " &aMeetup is in %{mu}% minutes"
- broadcast "&7-----------------&r{@P}&7-----------------"
- command sender command "/gamerule doDaylightCycle true"
- command sender command "/gamerule doMobSpawning true"
- while {timer.going} is true:
- if {first.time} is false:
- if {pvp} is equal to 20 or 15 or 10:
- broadcast "{@P} &a%{pvp}% &7minutes until PvP is enabled!"
- else if {pvp} is equal to 5:
- broadcast "{@P} &a%{pvp}% &7minutes until PvP is enabled!"
- set {rain} to true
- else if {pvp} is equal to 2:
- broadcast "{@P} &a%{pvp}% &7minutes until PvP is enabled!"
- else if {pvp} is equal to 0:
- execute console command "/timer cancel"
- execute console command "/timer %({mu}*60)% &7Meetup:&a"
- execute console command "/mw setflag %arg-3% PvP allow"
- broadcast "{@P} &7PvP is now enabled&7!"
- exit loop
- else:
- message "&a%{pvp}% minutes until PvP!"
- subtract 1 from {pvp}
- subtract 1 from {mu}
- wait 1 minute
- else:
- set {first.time} to false
- subtract 1 from {pvp}
- subtract 1 from {mu}
- wait 1 minute
- while {timer.going} is true:
- if {mu} is equal to 80 or 70 or 60 or 50 or 40 or 30 or 10:
- broadcast "{@P} &7MeetUp is in &a%{mu}% &7minutes!"
- else if {mu} is equal to 15:
- broadcast "{@P} &7MeetUp is in &a%{mu}% &7minutes!"
- else if {mu} is equal to 20:
- broadcast "{@P} &7MeetUp is in &a%{mu}% &7minutes!"
- set {_loc} to location of command sender
- command sender command "/mw goto %arg-3%"
- command sender command "/time set day %arg-3%"
- command sender command "/gamerule doDaylightCycle false"
- teleport the command sender to {_loc}
- delete {_loc}
- else if {mu} is equal to 5 or 2:
- broadcast "{@P} &a%{mu}% &7minutes until MeetUp!"
- else if {mu} is equal to 0:
- broadcast "&7-----------------&r{@P}&7-----------------"
- broadcast " &aMeetUp is now!"
- broadcast "&7-----------------&r{@P}&7-----------------"
- command sender command "/time set 6000"
- exit loop
- else:
- message "&c%{mu}% minutes until Meetup!"
- subtract 1 from {mu}
- wait 1 minute
- if {timer.going} is true:
- set {timer.going} to false
- else:
- stop
- delete {rain}
- message "{@P} &7Timer is done." to player
- command /timeleft:
- trigger:
- if {pvp} is greater than 0:
- if {pvp} is equal to 1:
- message "{@P} &7PvP: &a%{pvp}% minute &2&l| &7MeetUp: &a%{mu}% minutes"
- else:
- message "{@P} &7PvP: &a%{pvp}% minutes &2&l| &7MeetUp: &a%{mu}% minutes"
- else if {mu} is greater than 0:
- if {mu} is equal to 1:
- message "{@P} &7MeetUp is in &a1 minute&7."
- if {mu} is equal to 0:
- message "{@P} &7It's now MeetUp!"
- else:
- message "{@P} &7MeetUp is in &a%{mu}% minutes&7."
- else if {pvp} is less than 1:
- message "{@P} &7MeetUp is in &a%{mu}% minutes&7."
- command /stopuhc:
- permission: skript.op
- trigger:
- set {timer.going} to false
- set {pvp} to 0
- set {mu} to 0
- delete {rain}
- command sender command "/team reset"
- command sender command "/wl remove all"
- command sender command "/wl off"
- execute console command "/timer cancel"
- command sender command "/killscoreboard off"
- command sender command "/wl remove all"
- command sender command "/link"
- loop all players:
- teleport the loop-player to the spawn point of "world"
- clear the loop-player's inventory
- heal the loop-player
- wait 1 tick
- message "{@P} &7You have &cstopped &7the timer." to player
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement