SHARE
TWEET

Untitled

a guest Dec 11th, 2019 102 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. options:
  2.     chefrulesqueueMin: 3
  3.     chefrulesqueueMax: 10
  4.     slideshowqueueMin: 2
  5.     slideshowqueueMax: 10
  6.        
  7. on join:
  8.     if player's world is "ul_chefrules":
  9.         joinqueue(player, "ChefRules")
  10.     if player's world is "ul_slideshow":
  11.         joinqueue(player, "Slideshow")
  12.        
  13. on quit:
  14.     leavequeue(player, "ChefRules")
  15.     leavequeue(player, "Slideshow")
  16.  
  17. on player world change:
  18.     world is not "ul_chefrules":
  19.         leavequeue(player, "ChefRules")    
  20.     world is not "ul_slideshow":
  21.         leavequeue(player, "Slideshow")
  22.  
  23. on player world change:
  24.     world is "ul_chefrules":
  25.         joinqueue(player, "ChefRules")
  26.     world is "ul_slideshow":
  27.         joinqueue(player, "Slideshow")
  28.  
  29. function joinqueue(p: player, g: text):
  30.     if {_g} is "ChefRules":    
  31.         if {%{_g}%::*} does not contain {_p}:
  32.             if size of {%{_g}%::*} < {@chefrulesqueueMax}:
  33.                 add {_p} to {%{_g}%::*}
  34.                 send "You joined the queue." to {_p}
  35.                 send "&7%{_p}% &ejoined the game! (&b%size of {%{_g}%::*}%&e/&b{@chefrulesqueueMax}&e)" to all players where [{%{_g}%::*} contains input]
  36.                 if size of {%{_g}%::*} >= {@chefrulesqueueMin}:
  37.                     startgame("ChefRules")
  38.             else:
  39.                 send "&7The queue is full!" to {_p}
  40.     if {_g} is "Slideshow":    
  41.         if {%{_g}%::*} does not contain {_p}:
  42.             if size of {%{_g}%::*} < {@slideshowqueueMax}:
  43.                 add {_p} to {%{_g}%::*}
  44.                 send "You joined the queue." to {_p}
  45.                 send "&7%{_p}% &ejoined the game! (&b%size of {%{_g}%::*}%&e/&b{@slideshowqueueMax}&e)" to all players where [{%{_g}%::*} contains input]
  46.                 if size of {%{_g}%::*} >= {@slideshowqueueMin}:
  47.                     startgame("Slideshow")
  48.             else:
  49.                 send "&7The queue is full!" to {_p}
  50.    
  51. function leavequeue(p: player, g: text):
  52.     if {%{_g}%::*} contains {_p}:
  53.         remove {_p} from {%{_g}%::*}
  54.         remove {_p} from {%{_g}%::*}
  55.         send "You left the queue." to {_p}
  56.         send "&7%{_p}% &eleft the game!" to all players where [{%{_g}%::*} contains input]
  57.        
  58. function startgame(g: text):
  59.     if {_g} is "ChefRules":
  60.         send "Game starts in 30 seconds" to all players where [{%{_g}%::*} contains input]
  61.         wait 20 seconds
  62.         send "Game starts in 10 seconds" to all players where [{%{_g}%::*} contains input]
  63.         wait 5 seconds
  64.         send "Game starts in 5 seconds" to all players where [{%{_g}%::*} contains input]
  65.         wait 1 seconds
  66.         send "Game starts in 4 seconds" to all players where [{%{_g}%::*} contains input]
  67.         wait 1 seconds
  68.         send "Game starts in 3 seconds" to all players where [{%{_g}%::*} contains input]
  69.         wait 1 seconds
  70.         send "Game starts in 2 seconds" to all players where [{%{_g}%::*} contains input]
  71.         wait 1 seconds
  72.         send "Game starts in 1 second" to all players where [{%{_g}%::*} contains input]
  73.         wait 1 seconds
  74.         add {chefrulesqueue::*} to {chefrulesgame::*}
  75.         set block at location(-458, 1, 169, world("ul_ChefRules")) to redstone torch
  76.         wait 1 seconds
  77.         send "&a____________________________________________________" to all players where [{%{_g}%::*} contains input]
  78.         send "                               &lChef Rules" to all players where [{%{_g}%::*} contains input]
  79.         send " " to all players where [{%{_g}%::*} contains input]
  80.         send "&eHow 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)" to all players where [{%{_g}%::*} contains input]
  81.         send "&a____________________________________________________" to all players where [{%{_g}%::*} contains input]
  82.         send "You have 2 Minutes to cook as much as possible" to all players where [{%{_g}%::*} contains input]
  83.         wait 1 minute
  84.         send "1 minute remaining!" to all players where [{%{_g}%::*} contains input]
  85.         wait 30 seconds
  86.         send "30 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  87.         wait 10 seconds
  88.         send "10 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  89.         wait 5 seconds
  90.         send "5 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  91.         wait 1 second
  92.         send "4 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  93.         wait 1 second
  94.         send "3 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  95.         wait 1 second
  96.         send "2 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  97.         wait 1 second
  98.         send "1 seconds remaining!" to all players where [{%{_g}%::*} contains input]
  99.         set block at location(-468, 4, 99, world("ul_ChefRules")) to redstone torch
  100.     if {_g} is "Slideshow":
  101.         send "Game starts in 30 seconds" to all players where [{%{_g}%::*} contains input]
  102.         wait 20 seconds
  103.         send "Game starts in 10 seconds" to all players where [{%{_g}%::*} contains input]
  104.         wait 5 seconds
  105.         send "Game starts in 5 seconds" to all players where [{%{_g}%::*} contains input]
  106.         wait 1 seconds
  107.         send "Game starts in 4 seconds" to all players where [{%{_g}%::*} contains input]
  108.         wait 1 seconds
  109.         send "Game starts in 3 seconds" to all players where [{%{_g}%::*} contains input]
  110.         wait 1 seconds
  111.         send "Game starts in 2 seconds" to all players where [{%{_g}%::*} contains input]
  112.         wait 1 seconds
  113.         send "Game starts in 1 second" to all players where [{%{_g}%::*} contains input]
  114.         wait 1 seconds
  115.         set block at location(19, 64, -6, world("ul_SlideShow")) to redstone torch
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top