Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- command event <text>:
- usage: &e&lEVENTS &8| &7/event <start/stop/join/leave>
- trigger:
- if arg is "start":
- if player has permission "core.events.manage":
- open virtual chest inventory with size 3 named "Start Event" to player
- format gui slot 13 of player with stick named "&eSumo" with lore "&7Left-click to start and announce event." and "&7Right-click to start event without announcing." to run:
- if click action is left mouse button:
- set {event::*} to "Sumo"
- send "&e&lEVENTS &8| &7A Sumo event is starting! To join, do &e/event join&7." to all players
- else if click action is right mouse button:
- set {event::*} to "Sumo"
- send "&e&lEVENTS &8| &7Successfully started a silent Sumo event."
- else:
- send "&e&lEVENTS &8| &7You do not have permission to start an event."
- else if arg is "stop":
- if player has permission "core.events.manage":
- if {event::*} is set:
- open virtual chest inventory with size 3 named "Stop Event" to player
- format gui slot 13 of player with stick named "&c&lStop Event" with lore "&7Left-click to stop the current event." and "&c&lWARNING &8| &7Only use this if necessary." to run:
- send "&e&lEVENTS &8| &7The event has ended due to a technical fault. Sorry for the inconvienience." to all players
- else:
- send "&e&lEVENTS &8| &7You cannot stop an event if there is no event running."
- else if arg is "join":
- if player doesn't have permission "core.events.blacklist":
- if {event::*} is set:
- send "&e&lEVENTS &8| &7Joining the active %{event::*}% &7event. Please wait."
- set {event::joined::%player%} to true
- else:
- send "&e&lEVENTS &8| &7There are no active events currently."
- else:
- send "&e&lEVENTS &8| &7You have been blacklisted from joining server events. If you believe this is a mistake, please contact an administrator."
- else if arg is "leave":
- if {event::*} is set:
- if {event::joined::%player%} is true:
- send "&e&lEVENTS &8| &7You have successfully left the current event."
- set {event::joined::%player%} to false
- else:
- send "&e&lEVENTS &8| &7You have not joined an active event yet."
- else:
- send "&e&lEVENTS &8| &7There are no active events currently."
- command events:
- trigger:
- if {event::*} is set:
- send "&e&lEVENTS &8| &7%{event::*}% &7is the current active event. To join, do &e/event join&7."
- else:
- send "&e&lEVENTS &8| &7There are no active events currently."
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement