Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- on quit:
- remove player from {SlideShowQueue::*}
- send "&7%player% &cleft the queue!" to player
- command /playslideshow:
- aliases: /pss
- trigger:
- joinSlideShows(player)
- on load:
- set {SlideShows::info} to "How Chef Rules work: Make food for the chef and get xp to be 1st So good luck and make lots and lots of food for the chef and custormers (Tip: Once you have 50 gold make sure its in a single slot)"
- set {SlideShows::name} to "Slide Shows"
- set {SlideShows::min} to 3
- set {SlideShows::max} to 10
- function joinSlideShows(p: player):
- if {SlideShowQueue::*} contains {_p}:
- send "&cLeaving the queue!" to {_p}
- remove {_p} from {SlideShowQueue::*}
- else:
- if size of {SlideShowQueue::*} is greater than {SlideShows::max}:
- send "&cThe game is currently full! Please wait until a new game starts!" to {_p}
- else:
- add {_p} to {SlideShowQueue::*}
- send "&aYou have joined the Chef Rules&a queue" to {_p}
- broadcast "&7%{_p}% &ejoined the game! (&b%size of {SlideShowQueue::*}%&e/&b%{SlideShows::max}%&e)"
- if size of {games::SlideShowQueue::*} is {SlideShows:min}:
- startSlideShows()
- else:
- remove {_p} from {SlideShowQueue::*}
- if size of {SlideShowQueue::*} is {_required}-1:
- clear {starting::SlideShow}
- function startSlideShows():
- set {_name} to {SlideShows::name}
- set {_info} to {SlideShows:info}
- {starting::SlideShow} is not set
- set {starting::SlideShow} to true
- loop 30 times:
- if {starting::SlideShow} is not true:
- send "&3&lChef Rule &7The queue does not have enough players! &7[Requires %{_min}%&7]" to all players where [{SlideShowQueue::*} contains input]
- stop
- send "&3&lChef Rule &7Game starts in &a%31 - loop-value% &asecond(s)&7!" to all players where [{SlideShowQueue::*} contains input] if (31 - loop-value) is 30 or 20 or 15 or 10 or 5 or 3 or 2 or 1
- wait a second
- delete {SlideShowQueue::*}
- if {starting::SlideShow} is true:
- send "&a____________________________________________________", " &3&l%{_name}%", "", "&e%{_info}%" and "&a____________________________________________________" to all players where [{SlideShowQueue::*} contains input]
- loop 120 times:
- send "&3&l%{_name}% &7Game ends in &a%121 - loop-value% &asecond(s)&7!" to all players where [{SlideShowQueue::*} contains input] if (121 - loop-value) is 60 or 30 or 20 or 15 or 10 or 5 or 3 or 2 or 1
- wait a second
- set block at location(-468, 4, 99, world("ul_SlideShow")) to redstone torch
- delete {starting::SlideShow}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement