Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command /queue:
- permission: queue.use
- permission message: §cYou shouldn't be seeing this, contact and admin please!
- trigger:
- if {ingame} is not true:
- if {queue::*} != player:
- remove player from {queue::*}
- add player to {queue::*}
- send "&eJoined queue!"
- stop
- if {queue::*} = player:
- remove player from {queue::*}
- send "&eLeft queue!"
- stop
- variables:
- {ingame} = false
- {gametime} = 200
- {tpcountdownannouncement} = 5
- {playing.%player%} = false
- command /gamecontrol [<text>] [<integer>]:
- permission: gamecontrol.use
- aliases: gco
- permission message: §cYou do not have the required permission for this command, &bgamecontrol.use&c!
- trigger:
- if arg-1 is not set:
- send "&7--- &bGamecontrol v.0.1 &7---"
- send "&e/gco start &7Start a game."
- send "&e/gco stop &7Stop a game."
- send "&e/gco queue &7Check current queue."
- send "&e/gco game &7Check current game."
- send "&e/gco setgametime <integer> &7Set game's time limit."
- send "&7--- &bby Elluss &7---"
- if arg-1 is "start":
- set {ingame} to true
- broadcast "&bGamcontrol v.0.1 &7: &eA game has been manually started by &b%player%&e!"
- set {ingametime} to {gametime}
- loop {queue::*}:
- set {gamestart.%loop-value%} to true
- wait 1 second
- clear {queue::*}
- if arg-1 is "stop":
- broadcast "&bGamcontrol v.0.1 &7: &eA game has been manually stopped by &b%player%&e!"
- set {ingame} to false
- set {gameover} to true
- if arg-1 is "setgametime":
- if arg-2 is not set:
- send "&ePlease define a integer for the game time!"
- else:
- set {gametime} to arg-2
- send "&bGametime updated to &f%arg-2%&b seconds!"
- if arg-1 is "queue":
- send "&7--- &bThe Queue &7---"
- loop {queue::*}:
- send "&7- &b%loop-value%"
- if arg-1 is "game":
- send "&7--- &bThe Game &7---"
- loop {game::*}:
- send "&7- &b%loop-value%"
- every second:
- loop all players:
- if {gamestart.%loop-player%} is true:
- set {gamestart.%loop-player%} to false
- add loop-player to {game::*}
- set {playing.%loop-player%} to true
- # add stuff like, giving items and such here! #
- #TELEPORT ANNOUNCEMENT#
- if {playing.%loop-player%} is true:
- if {tpcountdownannouncement} is greater than 0:
- send "&eTeleportation will occur in %{tpcountdownannouncement}% seconds" to loop-player
- #TELEPORT ANNOUNCEMENT#
- #GIVE ITEMS!#
- #GIVE ITEMS!#
- #PICK RANDOM TEAM!#
- #PICK RANDOM TEAM!#
- if {ingame} is true:
- if {ingametime} is greater than 0:
- remove 1 from {ingametime}
- if {ingametime} is 0:
- set {ingame} to false
- set {gameover} to true
- if {gameover.%loop-player%} is true:
- set {gameover.%loop-player%} to false
- remove loop-player from {game::*}
- clear loop-player's inventory
- make console execute "spawn %loop-player%"
- send "&eThe game has ended!" to loop-player
- loop all players:
- set {playing.%loop-player-2%} to false
- set {notAllowedToAnnounce} to false
- set {tpcountdownannouncement} to 5
- every second:
- if {gameover} is true:
- set {gameover} to false
- loop {game::*}:
- set {gameover.%loop-value%} to true
- command /setcountdown <text>:
- permission: not.u
- trigger:
- set {tpcountdownannouncement} to arg-1
- every second:
- if {notAllowedToAnnounce} is true:
- stop
- if {tpcountdownannouncement} is greater than 0:
- remove 1 from {tpcountdownannouncement}
- if {tpcountdownannouncement} is 0:
- set {tpcountdownannouncement} to -1
- loop all players:
- if {playing.%loop-player%} is true:
- send "&eTeleported!" to loop-player
- set {notAllowedToAnnounce} to true
- stop
- command /tpcountdown:
- permission: not.u
- trigger:
- send "%{tpcountdownannouncement}%"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement