a guest Nov 17th, 2019 59 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. options:
  2.     prefix: &8[&eGANGS&8] &f
  3.     version: 1.0
  4.     author: jeelzzz & SupremeDarty
  5.     broadcastNewGangs: true
  6.     customChatFormat: true
  7.     noFriendlyPvP: true
  9. Command /gang [<text>] [<text>]:
  10.     aliases: g
  11.       trigger:
  12.         arg-1 is set:
  13.             arg-1 is "create":
  14.                 {gang.%uuid of player%} is set:
  15.                     send "{@prefix} &c&lERROR! &7You're already in a gang!"
  16.                 else:
  17.                     {gangowner.%arg-2%} is set:
  18.                         send "{@prefix} &c&lERROR! &7A gang with this name already exists."
  19.                     else:
  20.                         arg-2 is set:
  21.                             set {gang.%uuid of player%} to arg-2
  22.                             set {gangowner.%arg-2%} to uuid of player
  23.                             send "{@prefix} &a&lSUCCESS! &7You created a gang!"
  24.                             {@broadcastNewGangs} is true
  25.                             broadcast "{@prefix} &7%player% created new gang &a%arg-2%"
  26.             else if arg-1 is "join":
  27.                 {gangowner.%arg-2%} is set:
  28.                     {gang.isOpen.%arg-2%} is true:
  29.                         {gang.%uuid of player%} is set:
  30.                             send "{@prefix} &c&lERROR! &7You are already in a gang."
  31.                         else:
  32.                             loop all players:
  33.                                 {gang.%uuid of loop-player%} is arg-2
  34.                                 send "{@prefix} &a%player% &7joined the gang." to loop-player
  35.                             set {gang.%uuid of player%} to arg-2
  36.                             add uuid of player to {gangmembers.%{gang.%uuid of player%}%::*}
  37.                             {gang.%{gang.%uuid of player%}%.motd} is set
  38.                             send "%{gang.%{gang.%uuid of player%}%.motd}%"
  39.                     else:
  40.                         send "{@prefix} &c&lERROR! &7This gang requires invitiation to join."
  41.                 else:
  42.                     send "{@prefix} &c&lERROR! &7That gang does not exist!"
  43.             else if arg-1 is "invite":
  44.                 arg-2 is set:
  45.                     send "{@prefix} &c&lERROR! &7You must specify a player."
  46.                 else:
  47.                     set {gang.%{gang.%uuid of player%}%.invited.%arg-2%} to true
  48.                     send "{@prefix} &aYou've been invited to join %{gang.%uuid of player%}%. Type /gang join %{gang.%uuid of player%}% to join. (You have 5 minutes until this invite expires.)" to arg-2 parsed as player
  49.                     send "{@prefix} &aInvite successfully sent. Expires in 5 minutes."
  50.                     wait 5 minutes
  51.                     set {gang.%{gang.%uuid of player%}%.invited.%arg-2%} to false
  52.                     {gang.%arg-2%} is not {gang.%uuid of player%}
  53.                     send "{@prefix} &aYour invite has expired." to arg-2 parsed as player
  54.                     send "{@prefix} &aInvite sent to %arg-2% has expired."
  55.             else if arg-1 is "disband":
  56.                 {gangowner.%{gang.%uuid of player%}%} is uuid of player:
  57.                     loop {gangmembers.%{gang.%uuid of player%}%::*}:
  58.                         delete {gang.%uuid of loop-value parsed as offlineplayer%}
  59.                     {@broadcastNewGangs} is true:
  60.                         broadcast "{@prefix} &7%player% disbanded gang &a%{gang.%uuid of player%}%"
  61.                     else:
  62.                         send "{@prefix} &7You disbanded your gang."
  63.                     delete {gang.%uuid of player%}
  64.                     delete {gangowner.%{gang.%uuid of player%}%}
  65.                 else:
  66.                     send "{@prefix} &c&lERROR! &7Only the guild owner can disband the guild."
  67.             else if arg-1 is "settings":
  68.                 send "&a&lGANG SETTINGS &8:: {@version}"
  69.                 send ""
  70.                 send "{@prefix}&7 /gang joinoption (open/closed)"
  71.                 send "{@prefix}&7 /gang motd (text)"
  72.                 send ""
  73.                 send "&7Created by {@author}"
  75.             # settings subcommands VV
  76.             else if arg-1 is "joinoption":
  77.                 {gangowner.%{gang.%uuid of player%}%} is uuid of player:
  78.                     arg-2 is "open":
  79.                         set {gang.isOpen.%{gang.%uuid of player%}%} to true
  80.                         send "{@prefix} &7Gang is now open!"
  81.                     else if arg-2 is "closed":
  82.                         set {gang.isOpen.%{gang.%uuid of player%}%} to false
  83.                         send "{@prefix} &7Gang is now closed!"
  84.                     else:
  85.                         send "{@prefix} &c&lERROR! &7Available argument(s): open, closed"
  86.                 else:
  87.                     send "{@prefix} &c&lERROR! &7Only the gang owner can edit this option!"
  88.             else if arg-1 is "motd":
  89.                 {gangowner.%{gang.%uuid of player%}%} is uuid of player:
  90.                     set {gang.%{gang.%uuid of player%}%.motd} to arg-2
  91.                     send "{@prefix} Gang MOTD updated successfully"
  92.                 else:
  93.                     send "{@prefix} &c&lERROR! &7Only the gang owner can edit this option!"
  94.             else if arg-1 is "kick":
  95.                 {gangowner.%{gang.%uuid of player%}%} is uuid of player:
  96.                     arg-2 is player:
  97.                         send "{@prefix} &c&lERROR! &7You cannot kick yourself from the gang."
  98.                     else:
  99.                         remove (uuid of arg-2 parsed as offline player) from {gangmembers.%{gang.%uuid of player%}%::*}
  100.                         clear {gang.%uuid of arg-2 parsed as offline player%}
  101.                         send "{@prefix} &aSuccessfully kicked player."
  102.                 else:
  103.                     send "{@prefix} &c&lERROR! &7Only the gang owner can run this command!"
  104.             else:
  105.                 send "{@prefix} &c&lERROR! &7Invalid argument. Type &o/gang &cfor more information"
  106.             else if arg-1 is "chat":
  107.                 arg-2 is set:
  108.                     loop all players:
  109.                         {gang.%uuid of player%} = {gang.%uuid of loop-player%}
  110.                         send "&8[&2&l%{gang.%uuid of player%}%&8] &7%player% &8: &f%message%"
  111.                 else:
  112.                     send "{@prefix} &c&lERROR! &7You have to be in a gang to execute this command"
  113.         else:
  114.             send "&a&lGANG COMMANDS &8:: {@version}"
  115.             send ""
  116.             send "{@prefix}&b /gang create (name)"
  117.             send "{@prefix}&b /gang join (name)"
  118.             send "{@prefix}&b /gang invite (player)"
  119.             send "{@prefix}&b /gang disband"
  120.             send "{@prefix}&b /gang kick (player)"
  121.             send "{@prefix}&b /gang settings"
  122.             send "{@prefix}&b /gang chat (message)"
  123. on damage:
  124.     {gang.%uuid of attacker%} = {gang.%uuid of victim%}
  125.     {@noFriendlyPvp} is true
  126.     cancel event
  127.     send "&c&lERROR! &7You can't attack your gang members" to attacker
  128.     send "&7%attacker% tried to attack you." to victim
  129. on join:
  130.     {gang.%{gang.%uuid of player%}%.motd} is set
  131.     send "%{gang.%{gang.%uuid of player%}%.motd}%"
  133. on chat:
  134.     {@customChatFormat} is true
  135.     cancel event
  136.     if {gang.%uuid of player%} is set:
  137.         broadcast "&8[&7%{gang.%uuid of player%}%&8] &7%player%&f: %message%"
  138.     else if {gangowner.%{gang.%uuid of player%}%} is uuid of player:
  139.         broadcast "&8[&6&l✰&7%{gang.%uuid of player%}%&8] &7%player%&f: %message%"
  140.     else if {gang.%uuid of player%} is not set:
  141.         broadcast "&7%player%&f: %message%"
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