Advertisement
Kukky

MyParty

Jul 21st, 2016
320
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #Party Mode##################
  2.  
  3. variables:
  4.     {party.%player%.chat} = false
  5.     {pchatView::%player%} = false
  6.     {partyNumber.%player%} = 0
  7.     {dungeon2Active} = false
  8.     {pWater.%player%} = false
  9.     {pEarth.%player%} = false
  10.     {party.%player%.spy} = false
  11.  
  12. aliases:
  13.     glass = 20
  14.     pane = 160:15
  15.     snowball = 332
  16.     endereye = 381
  17.     prismarine shard = 409
  18.     dragon egg = 122
  19.     barrier = 166
  20.  
  21. function pEarth(p: player):
  22.     format slot 1 of {_p} with shiny endereye named "&2The Legend of Alkheim" with lore "&6The Dunhym Temple is a sacred temple where the parents||&6of Renhelm Dunhym were buried. Many people died trying to||&6find the Mysterious Eye of Dunhym, and return back, alive.||&7Party Size: &5Unlimited||&0&k1&d&lCURRENTLY SELECTED&0&k1" to be unstealable
  23.     format slot 2 of {_p} with prismarine shard named "&9The Creeper's Cove" with lore "&6The Sunriders always have their plans. This time, they have decided||&6it's finally time to summon the Kraken and bring it back to the world.||&6What could be lurking deep down beneath the Creeper's Cove?||&7Party Size: &5Two Players" to be unstealable
  24.     format slot 3 of {_p} with snowball named "&7Whitepeak Ruins" with lore "&6Coming Soon!" to be unstealable
  25.     format slot 4 of {_p} with dragon egg named "&4Altar of Fire" with lore "&6Coming Soon!" to be unstealable
  26.     format slot 5 of {_p} with barrier named "&4Coming Soon!" with lore "&6Coming Soon!" to be unstealable
  27.     format slot 7 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  28.     if {pEarth.%{_p}%} is true:
  29.         stop
  30.     loop {party.%{_p}%::*}:
  31.         send "&f[&5Party&f] &6%{_p}% &7has chosen &2The Legend of Alkheim &7as your Party Quest." to loop-value
  32.     set {pEarth.%{_p}%} to true
  33.     set {pWater.%{_p}%} to false
  34.  
  35. function pWater(p: player):
  36.     format slot 1 of {_p} with endereye named "&2The Legend of Alkheim" with lore "&6The Dunhym Temple is a sacred temple where the parents||&6of Renhelm Dunhym were buried. Many people died trying to||&6find the Mysterious Eye of Dunhym, and return back, alive.||&7Party Size: &5Unlimited" to be unstealable
  37.     format slot 2 of {_p} with shiny prismarine shard named "&9The Creeper's Cove" with lore "&6The Sunriders always have their plans. This time, they have decided||&6it's finally time to summon the Kraken and bring it back to the world.||&6What could be lurking deep down beneath the Creeper's Cove?||&7Party Size: &5Two Players||&0&k1&d&lCURRENTLY SELECTED&0&k1" to be unstealable
  38.     format slot 3 of {_p} with snowball named "&7Whitepeak Ruins" with lore "&6Coming Soon!" to be unstealable
  39.     format slot 4 of {_p} with dragon egg named "&4Altar of Fire" with lore "&6Coming Soon!" to be unstealable
  40.     format slot 5 of {_p} with barrier named "&4Coming Soon!" with lore "&6Coming Soon!" to be unstealable
  41.     format slot 7 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  42.     if {pWater.%{_p}%} is true:
  43.         stop
  44.     loop {party.%{_p}%::*}:
  45.         send "&f[&5Party&f] &6%{_p}% &7has chosen &9The Creeper's Cove &7as your Party Quest." to loop-value
  46.     set {pWater.%{_p}%} to true
  47.     set {pEarth.%{_p}%} to false
  48.  
  49. function pAir(p: player):
  50.     format slot 1 of {_p} with endereye named "&2The Legend of Alkheim" with lore "&6The Dunhym Temple is a sacred temple where the parents||&6of Renhelm Dunhym were buried. Many people died trying to||&6find the Mysterious Eye of Dunhym, and return back, alive.||&7Party Size: &5Unlimited" to be unstealable
  51.     format slot 2 of {_p} with prismarine shard named "&9The Creeper's Cove" with lore "&6The Sunriders always have their plans. This time, they have decided||&6it's finally time to summon the Kraken and bring it back to the world.||&6What could be lurking deep down beneath the Creeper's Cove?||&7Party Size: &5Two Players" to be unstealable
  52.     format slot 3 of {_p} with shiny snowball named "&7Whitepeak Ruins" with lore "&6Coming Soon!" to be unstealable
  53.     format slot 4 of {_p} with dragon egg named "&4Altar of Fire" with lore "&6Coming Soon!" to be unstealable
  54.     format slot 5 of {_p} with barrier named "&4Coming Soon!" with lore "&6Coming Soon!" to be unstealable
  55.     format slot 7 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  56.  
  57. function pFire(p: player):
  58.     format slot 1 of {_p} with endereye named "&2The Legend of Alkheim" with lore "&6The Dunhym Temple is a sacred temple where the parents||&6of Renhelm Dunhym were buried. Many people died trying to||&6find the Mysterious Eye of Dunhym, and return back, alive.||&7Party Size: &5Unlimited" to be unstealable
  59.     format slot 2 of {_p} with prismarine shard named "&9The Creeper's Cove" with lore "&6The Sunriders always have their plans. This time, they have decided||&6it's finally time to summon the Kraken and bring it back to the world.||&6What could be lurking deep down beneath the Creeper's Cove?||&7Party Size: &5Two Players" to be unstealable
  60.     format slot 3 of {_p} with snowball named "&7Whitepeak Ruins" with lore "&6Coming Soon!" to be unstealable
  61.     format slot 4 of {_p} with shiny dragon egg named "&4Altar of Fire" with lore "&6Coming Soon!" to be unstealable
  62.     format slot 5 of {_p} with barrier named "&4Coming Soon!" with lore "&6Coming Soon!" to be unstealable
  63.     format slot 7 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  64.  
  65. function pMain(p: player):
  66.     open chest with 2 rows named "&5Party Quest" to {_p}
  67.     format slot 10 of {_p} with paper named "&6Click here to select this Dungeon" to run [pEarth({_p})]
  68.     format slot 11 of {_p} with paper named "&6Click here to select this Dungeon" to run [pWater({_p})]
  69.     format slot 12 of {_p} with paper named "&6Click here to select this Dungeon" to run [pAir({_p})]
  70.     format slot 13 of {_p} with paper named "&6Click here to select this Dungeon" to run [pFire({_p})]
  71.     format slot 14 of {_p} with barrier named "&4Coming Soon!" to be unstealable
  72.     format slot 16 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  73.     if {pEarth.%{_p}%} is true:
  74.         pEarth({_p})
  75.     else if {pWater.%{_p}%} is true:
  76.         pWater({_p})
  77.     else:
  78.         format slot 1 of {_p} with endereye named "&2The Legend of Alkheim" with lore "&6The Dunhym Temple is a sacred temple where the parents||&6of Renhelm Dunhym were buried. Many people died trying to||&6find the Mysterious Eye of Dunhym, and return back, alive.||&7Party Size: &5Unlimited" to be unstealable
  79.         format slot 2 of {_p} with prismarine shard named "&9The Creeper's Cove" with lore "&6The Sunriders always have their plans. This time, they have decided||&6it's finally time to summon the Kraken and bring it back to the world.||&6What could be lurking deep down beneath the Creeper's Cove?||&7Party Size: &5Two Players" to be unstealable
  80.         format slot 3 of {_p} with snowball named "&7Whitepeak Ruins" with lore "&6Coming Soon!" to be unstealable
  81.         format slot 4 of {_p} with dragon egg named "&4Altar of Fire" with lore "&6Coming Soon!" to be unstealable
  82.         format slot 5 of {_p} with barrier named "&4Coming Soon!" with lore "&6Coming Soon!" to be unstealable
  83.         format slot 7 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  84.  
  85. function pMainL(p: player):
  86.     open chest with 2 rows named "&5Party Quest" to {_p}
  87.     format slot 10 of {_p} with paper named "&6Click here to select this Dungeon" to run [pEarth({_p})]
  88.     format slot 11 of {_p} with paper named "&4Not Available" with lore "&4Too many people in your Party" to be unstealable
  89.     format slot 12 of {_p} with paper named "&6Click here to select this Dungeon" to run [pAir({_p})]
  90.     format slot 13 of {_p} with paper named "&6Click here to select this Dungeon" to run [pFire({_p})]
  91.     format slot 14 of {_p} with barrier named "&4Coming Soon!" to be unstealable
  92.     format slot 16 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  93.     if {pEarth.%{_p}%} is true:
  94.         pEarth({_p})
  95.     else if {pWater.%{_p}%} is true:
  96.         pWater({_p})
  97.     else:
  98.         format slot 1 of {_p} with endereye named "&2The Legend of Alkheim" with lore "&6The Dunhym Temple is a sacred temple where the parents||&6of Renhelm Dunhym were buried. Many people died trying to||&6find the Mysterious Eye of Dunhym, and return back, alive.||&7Party Size: &5Unlimited" to be unstealable
  99.         format slot 2 of {_p} with prismarine shard named "&9The Creeper's Cove" with lore "&6The Sunriders always have their plans. This time, they have decided||&6it's finally time to summon the Kraken and bring it back to the world.||&6What could be lurking deep down beneath the Creeper's Cove?||&7Party Size: &5Two Players" to be unstealable
  100.         format slot 3 of {_p} with snowball named "&7Whitepeak Ruins" with lore "&6Coming Soon!" to be unstealable
  101.         format slot 4 of {_p} with dragon egg named "&4Altar of Fire" with lore "&6Coming Soon!" to be unstealable
  102.         format slot 5 of {_p} with barrier named "&4Coming Soon!" with lore "&6Coming Soon!" to be unstealable
  103.         format slot 7 of {_p} with wool named "&6Party Quests" with lore "&6Coming Soon!" to be unstealable
  104.  
  105. on left click:
  106.     player is holding paper with lore "&7Quest Type: &3Dungeon||&7Raid Difficulty: &4Hard||&7Recommended: &a2 Players||&9Left Click at Dungeon Door to Enter.||&9Right Click to start the Quest." named "&3The Legend Beneath the Waves"
  107.     set {_region} to "%region at location of player%"
  108.     if {_region} contains "coveenter":
  109.         if {dungeon2Active} is true:
  110.             send "&8[&3Quest&8] &7A Party is currently going through the dungeon!"
  111.             stop
  112.         else if {party.%player%} is not set:
  113.             send "&8[&3Quest&8] &7You are not in a party!"
  114.             stop
  115.         else if {party.%player%} is not equal to player:
  116.             send "&8[&3Quest&8] &7You are not the Party Leader! Have &6%{party.%player%}% &7use the item to enter the dungeon."
  117.             stop
  118.         else if {party.%player%} is equal to player:
  119.             if {pWater.%player%} is true:
  120.                 loop {party.%player%::*}:
  121.                     send "&8[&3Quest&8] &7You are now entering &9The Creeper's Cove&7." to loop-value
  122.                     execute console command "/warp coveroom1 %loop-value%"
  123.                     set {dungeon2Active.%loop-value%} to true
  124.                 remove 1 paper with lore "&7Quest Type: &3Dungeon||&7Raid Difficulty: &4Hard||&7Recommended: &a2 Players||&9Left Click at Dungeon Door to Enter.||&9Right Click to start the Quest." named "&3The Legend Beneath the Waves" from the player
  125.                 set {dungeon2Active} to true
  126.             else:
  127.                 send "&8[&3Quest&8] &7You must have &9The Creeper's Cove &7selected as your Party Quest!"
  128.                 stop
  129.         else:
  130.             stop
  131.     else:
  132.         stop
  133.  
  134.  
  135. command /partyfix:
  136.     trigger:
  137.         set {partyac.%player%} to false
  138.  
  139. command /party [<text>] [<player>]:
  140.     description: Party Mode
  141.     trigger:
  142.         if arg 1 is not set:
  143.             if {party.%player%} is not set:
  144.                 message "&f[&5Party&f] &7You are not in a party!"
  145.                 stop
  146.             else:
  147.                 message "&f[&5Party&f] &7Party Leader: &6%{party.%player%}%"
  148.                 loop {party.%{party.%player%}%::*}:
  149.                     if {_show} is not set:
  150.                         set {_show} to loop-value
  151.                     else:
  152.                         set {_show} to "%{_show}%, %loop-value%"
  153.                 send "&f[&5Party&f] &7Party Members: &6%{_show}%"
  154.                 message "&f[&5Party&f] &7Party Size: &6%{partyNumber.%{party.%player%}%}% members"
  155.         else if arg 1 is "help":
  156.             play raw sound "random.pop" at player with pitch 0.1 volume 0.3
  157.             message "&f[&5Party&f] &c/party &7- Shows who is in the Party."
  158.             message "&f[&5Party&f] &c/party create &7- Creates a new Party."
  159.             message "&f[&5Party&f] &c/party help &7- Shows the commands you can do for /party."
  160.             message "&f[&5Party&f] &c/party invite [player] &7- Invites the player you specified. Party Leaders Only."
  161.             message "&f[&5Party&f] &c/party accept [player] &7- Accepts an invite from the player you specified."
  162.             message "&f[&5Party&f] &c/party decline [player] &7- Declines an invite from the player you specified."
  163.             message "&f[&5Party&f] &c/party kick [player] &7-Kicks the specified player from the Party. Party Leaders Only."
  164.             message "&f[&5Party&f] &c/party promote [player] &7-Makes the specified player the leader. Party Leaders Only."
  165.             message "&f[&5Party&f] &c/party leave &7- Leaves the Party you are in."
  166.             message "&f[&5Party&f] &c/party disband &7- Disbands the Party you created. Party Leaders Only."
  167.             message "&f[&5Party&f] &c/party quest &7- Opens the Party Quest Menu. Party Leaders Only."
  168.             message "&f[&5Party&f] &c/party surrender &7- Ends your Dungeon Run. Party Leaders Only."
  169.             message "&f[&5Party&f] &c/party chat &7- Toggles Party Chat."
  170.         else if arg 1 is "create":
  171.             if {party.%player%} is set:
  172.                 send "&f[&5Party&f] &7You are already in a party!"
  173.                 stop
  174.             else:
  175.                 send "&f[&5Party&f] &7You created a party!"
  176.                 play raw sound "random.pop" at player with pitch 1 volume 0.3
  177.                 play raw sound "random.orb" at player with pitch 1 volume 0.3
  178.                 set {party.%player%} to player
  179.                 add player to {party.%player%::*}
  180.                 set {partyNumber.%player%} to 1
  181.                 stop
  182.         else if arg 1 is "invite":
  183.             {partyac.%player arg%} is true:
  184.                 send "&f[&5Party&f] &7You already sent a request to &6%player arg%! &7Wait for a response."
  185.                 stop
  186.             loop {party.%player%::*}:
  187.                 player arg is equal to loop-value:
  188.                     send "&f[&5Party&f] &6%player arg% &cis already in your party!"
  189.                     stop
  190.             {party.%player arg%} is set:
  191.                 send "&f[&5Party&f] &6%player arg% &7is already in a party."
  192.                 stop
  193.             {party.%player%} is not player:
  194.                 send "&f[&5Party&f] &cOnly Party Leaders can use this command!"  
  195.                 stop
  196.             {party.%player%} is player:
  197.                 {party.%player%} is equal to player arg:
  198.                     send "&f[&5Party&f] &cYou can't invite yourself to your party."
  199.                     stop
  200.                 play raw sound "random.pop" at player with pitch 0.1 volume 0.3
  201.                 play raw sound "random.orb" at player with pitch 0.1 volume 0.3
  202.                 play raw sound "random.pop" at player arg with pitch 0.1 volume 0.3
  203.                 play raw sound "random.orb" at player arg with pitch 0.1 volume 0.3
  204.                 loop {party.%player%::*}:
  205.                     send "&f[&5Party&f] &7%player% sent a party invite to &6%player arg%&7. Waiting on a response..." to loop-value
  206.                 send "&f[&5Party&f] &7You were invited to &6%player%'s &7Party. Accept or Decline?" to player arg
  207.                 execute console command "/tellraw %player arg% ["""",{""text"":""["",""clickEvent"":{""action"":""run_command"",""value"":""""}},{""text"":""Accept"",""color"":""dark_green"",""clickEvent"":{""action"":""run_command"",""value"":""/party accept %player%""},""hoverEvent"":{""action"":""show_text"",""value"":{""text"":"""",""extra"":[{""text"":""Join the Party"",""color"":""dark_green""}]}}},{""text"":""]"",""color"":""none""}]"
  208.                 execute console command "/tellraw %player arg% ["""",{""text"":""["",""clickEvent"":{""action"":""run_command"",""value"":""""}},{""text"":""Decline"",""color"":""red"",""clickEvent"":{""action"":""run_command"",""value"":""/party decline %player%""},""hoverEvent"":{""action"":""show_text"",""value"":{""text"":"""",""extra"":[{""text"":""Decline the Party"",""color"":""red""}]}}},{""text"":""]"",""color"":""none""}]"
  209.                 set {partyac.%player arg%} to true
  210.                 set {partyClick::%{button.%player%}%} to false
  211.                 wait 30 seconds
  212.                 {partyClick::%{button.%player%}%} is false:
  213.                     send "&f[&5Party&f] &6%player arg% &7did not take any action within 30 seconds. Cancelling..."
  214.                     make arg 2 execute command "/party decline %player%"
  215.                     stop
  216.                 stop
  217.         else if arg 1 is "accept":
  218.             {partyClick::%{button.%player arg%}%} is true:
  219.                 send "&f[&5Party&f] &7You don't have a pending invite."
  220.                 stop
  221.             {party.%player arg%.leader} is player:
  222.                 send "&f[&5Party&f] &7You can't join your own party!" to player arg
  223.                 stop
  224.             {party.%player%} is set:
  225.                 send "&f[&5Party&f] &7You are already in &6%player arg%'s &7party!"
  226.                 stop
  227.             {party.%player%} is not set:
  228.                 set {partyClick::%{button.%player%}%} to true
  229.                 {partyac.%player%} is not true:
  230.                     send "&f[&5Party&f] &7You don't have a party to join."
  231.                     stop
  232.                 send "&f[&5Party&f] &7You joined &6%player arg%'s &7party!"
  233.                 loop {party.%player arg%::*}:
  234.                     send "&f[&5Party&f] &6%player% joined your party!" to loop-value
  235.                 play raw sound "random.pop" at player with pitch 0.1 volume 0.3
  236.                 play raw sound "random.orb" at player with pitch 0.1 volume 0.3
  237.                 play raw sound "random.pop" at player arg with pitch 0.1 volume 0.3
  238.                 play raw sound "random.orb" at player arg with pitch 0.1 volume 0.3
  239.                 set {party.%player%} to player arg
  240.                 add player to {party.%player arg%::*}
  241.                 add 1 to {partyNumber.%player arg%}
  242.                 set {partyClick::%{button.%player arg%}%} to true
  243.                 set {partyac.%player%} to false
  244.                 stop
  245.         else if arg 1 is "decline":
  246.             {partyClick::%{button.%player arg%}%} is true:
  247.                 send "&f[&5Party&f] &7You don't have a pending invite."
  248.                 stop
  249.             {partyac.%player%} is not true:
  250.                 send "&f[&5Party&f] &7You don't have a party invite to decline."
  251.                 stop
  252.             send "&f[&5Party&f] &7You declined to join &6%player arg%'s &7party."
  253.             loop {party.%player arg%::*}:
  254.                 send "&f[&5Party&f] &6%player% &7has declined to join the party." to loop-value
  255.             set {partyac.%player%} to false
  256.             set {partyClick::%{button.%player arg%}%} to true
  257.             stop
  258.         else if arg 1 is "disband":
  259.             {party.%player%} is not equal to player:
  260.                 send "&f[&5Party&f] &cOnly Party Leaders can use this command!"
  261.                 stop
  262.             {party.%player%} is not set:
  263.                 send "&f[&5Party&f] &7You are not in a party!"
  264.                 stop    
  265.             loop {party.%player%::*}:
  266.                 send "&f[&5Party&f] &6%player% &chas disbanded the party." to loop-value
  267.                 play raw sound "random.pop" at loop-value with pitch 0.1 volume 0.3
  268.                 play raw sound "random.orb" at loop-value with pitch 0.1 volume 0.3
  269.                 delete {party.%loop-value%}
  270.                 delete {party.%loop-value%.chat}
  271.                 delete {party.%loop-value%.leader}
  272.             delete {party.%player%::*}
  273.             delete {partyNumber.%player%}
  274.             delete {pWater.%player%}
  275.             delete {pEarth.%player%}
  276.             stop
  277.         else if arg 1 is "promote":
  278.             if {party.%player%} is not set:
  279.                 message "&f[&5Party&f] &cYou are not in a party!"
  280.                 stop
  281.             else:
  282.                 {party.%player%} is not player:
  283.                     message "&f[&5Party&f] &cOnly Party Leaders can use this command!"
  284.                     stop   
  285.                 {party.%player%::*} doesn't contain player arg:
  286.                     message "&f[&5Party&f] &6%player arg% &cis not in your party."
  287.                     stop   
  288.                 send "&f[&5Party&f] &7You promoted &6%player arg% &7to Party Leader."  
  289.                 send "&f[&5Party&f] &7You have been promoted by &6%player% &7to Party Leader." to player arg
  290.                 loop {party.%player%::*}:
  291.                     set {party.%loop-value%} to player arg
  292.                     add loop-value to {party.%player arg%::*}
  293.                     add 1 to {partyNumber.%player arg%}
  294.                     loop-value is not player or player arg:
  295.                         message "&f[&5Party&f] &6%player arg% &7has been promoted to Party Leader." to loop-value
  296.                 delete {party.%player%::*}
  297.                 delete {partyNumber.%player%}
  298.                 delete {pWater.%player%}
  299.                 delete {pWater.%player%}
  300.         else if arg 1 is "leave":
  301.             if {party.%player%} is not set:
  302.                 message "&f[&5Party&f] &cYou are not in a party!"
  303.             else:
  304.                 if {party.%player%} is player:
  305.                     message "&f[&5Party&f] &cYou are the Party Leader! Type /party leader [player] if you want to make someone else leader."
  306.                     stop
  307.                 message "&f[&5Party&f] &cYou left the party."
  308.                 loop {party.%{party.%player%}%::*}:
  309.                     if loop-value = player:
  310.                         delete {party.%{party.%player%}%::%loop-index%}
  311.                     message "&f[&5Party&f] &6%player% &chas left your party." to loop-value
  312.                 remove 1 from {partyNumber.%{party.%player%}%}
  313.                 wait 1 tick
  314.                 delete {party.%player%}
  315.                 delete {party.%player%.chat}
  316.                 delete {pWater.%player%}
  317.                 delete {pWater.%player%}
  318.         else if arg 1 is "kick":
  319.             if {party.%player%} is not set:
  320.                 message "&f[&5Party&f] &cYou are not in a party!"
  321.             else:
  322.                 if {party.%player%} is not player:
  323.                     message "&f[&5Party&f] &cOnly Party Leaders can use this command!"
  324.                     stop   
  325.                 if player arg is not set:
  326.                     message "&f[&5Party&f] &cYou did not specify a player to kick."
  327.                 if {party.%player%} = player arg:
  328.                     message "&f[&5Party&f] &cYou can't kick yourself from the party!"
  329.                     stop
  330.                 else:
  331.                     if {party.%player%::*} doesn't contain player arg:
  332.                         message "&f[&5Party&f] &6%player arg% &cis not in your party."
  333.                         stop   
  334.                     message "&f[&5Party&f] &cYou kicked &6%player arg% &cfrom the party."  
  335.                     message "&f[&5Party&f] &cYou've been kicked from the party by &6%player%&c." to player arg
  336.                     remove 1 from {partyNumber.%player%}
  337.                     wait 1 tick
  338.                     loop {party.%player%::*}:
  339.                         if loop-value = player arg:
  340.                             delete {party.%player%::%loop-index%}
  341.                         send "&f[&5Party&f] &6%player arg% &chas been kicked from the party by &6%player%&c." to loop-value
  342.                     delete {party.%player arg%}
  343.                     delete {party.%player arg%.chat}
  344.                     delete {pWater.%player arg%}
  345.                     delete {pEarth.%player arg%}
  346.         else if arg 1 is "quest":
  347.             if {party.%player%} is not set:
  348.                 message "&f[&5Party&f] &cYou are not in a party!"
  349.             else:
  350.                 if {party.%player%} is not player:
  351.                     message "&f[&5Party&f] &cOnly Party Leaders can use this command!"
  352.                     stop
  353.                 else if {partyNumber.%player%} is greater than 2:
  354.                     pMainL(player)
  355.                 else if {partyNumber.%player%} is less than 3:
  356.                     pMain(player)
  357.         else if arg 1 is "surrender":
  358.             if {party.%player%} is not set:
  359.                 message "&f[&5Party&f] &cYou are not in a party!"
  360.             else:
  361.                 if {party.%player%} is not player:
  362.                     message "&f[&5Party&f] &cOnly Party Leaders can use this command!"
  363.                     stop
  364.                 else if {dungeon2Active.%player%} is false:
  365.                     message "&f[&5Party&f] &cYou are not in a Dungeon!"
  366.                     stop                
  367.                 else:    
  368.                     loop {party.%player%::*}:
  369.                         send "&f[&5Party&f] &6%player% &7has decided to stop your Dungeon Run." to loop-value
  370.                         make loop-value execute command "/spawn"
  371.                     set {dungeon2Active} to false
  372.                     set {dungeon2Active.%player%} to false
  373.         else if arg 1 is "up":
  374.             player has permission "kukky.perms"
  375.             make player execute command "/partyupdate"
  376.            
  377.                            
  378.         else:
  379.             send "&f[&5Party&f] &cThat is not a command! Type /party help for a list of things you can do."
  380.  
  381. on quit:
  382.     {party.%player%} is set:
  383.         if {party.%player%} is player:
  384.             loop {party.%player%::*}:
  385.                 send "&f[&5Party&f] &cYour party leader has quit. Disbanding the party..." to loop-value
  386.             make player execute command "/party disband"
  387.             make player execute command "/party surrender"
  388.         else if {party.%player%} is not player:
  389.             loop {party.%{party.%player%}%::*}:
  390.                 send "&f[&5Party&f] &6%player% &chas disconnected. They have &4one minute &cto reconnect before they get kicked from the party." to loop-value
  391.             set {party.%player%.chat} to false
  392.             wait 1 minute
  393.             player is offline:
  394.                 loop {party.%{party.%player%}%::*}:
  395.                     send "&f[&5Party&f] &6%player% &chas failed to reconnect within one minute. Kicking from the party..." to loop-value
  396.                     make player execute command "/party leave"
  397.                     stop
  398.  
  399. on join:
  400.     {party.%player%} is set:
  401.         loop {party.%{party.%player%}%::*}:
  402.             send "&f[&5Party&f] &6%player% &chas reconnected." to loop-value
  403.         loop {party.%{party.%player%}%::*}:
  404.             if loop-value = player:
  405.                 delete {party.%{party.%player%}%::%loop-index%}
  406.         wait 1 tick
  407.         add player to {party.%{party.%player%}%::*}
  408.  
  409. command /partyoff:
  410.     trigger:
  411.         message "%{relog::*}%"
  412.         delete {relog::*}
  413.         message "%{party.%player%::*}%"
  414.  
  415. command /partyop [<text>] [<player>]:
  416.     permission: kukky.perms
  417.     trigger:
  418.         arg 1 is "join":
  419.             {party.%player arg%} is not set:
  420.                 send "&f[&5Party&f] &cThat player is not in a party!"
  421.                 stop
  422.             {party.%player arg%} is not equal to player arg:
  423.                 send "&f[&5Party&f] &cThat player doesn't have a party!"
  424.                 stop
  425.             set {party.%player%} to player arg
  426.             add player to {party.%player arg%::*}
  427.             add 1 to {partyNumber.%player arg%}
  428.             send "&f[&5Party&f] &7You joined &6%player arg%'s &7party."
  429.             wait 1 tick
  430.             loop {party.%player arg%::*}:
  431.                 send "&f[&5Party&f] &6%player% &cjoined your party without permission." to loop-value
  432.         arg 1 is "usurp":
  433.             {party.%player arg%} is not equal to player arg:
  434.                 send "&f[&5Party&f] &cThat player isn't the leader of a party!"
  435.                 stop
  436.             {party.%player%} is equal to player arg:
  437.                 set {partyNumber.%player%} to 1
  438.                 loop {party.%player arg%::*}:
  439.                     set {party.%loop-value%} to player
  440.                     add loop-value to {party.%player%::*}
  441.                     add 1 to {partyNumber.%player%}
  442.                 wait 2 ticks
  443.                 delete {party.%player arg%::*}
  444.                 delete {partyNumber.%player arg%}
  445.                 loop {party.%player%::*}:
  446.                     send "&f[&5Party&f] &6%player% &chas usurped the Party Leadership!" to loop-value
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement