name: BanX
main: crazicrafter1.banx.Main
version: 3.0
author: crazicrafter1
#api-version:
commands:
  ban:
    description: "ban a player"
    usage: /<command> <player | UUID> [reason] [-a] [-s/-ss]
    permission: banx.ban
  mute:
    description: "mute a player"
    usage: /<command> <player | UUID> [reason] [-a] [-s/-ss]
    permission: banx.mute
  kick:
    description: "kick a player"
    usage: /<command> <player | UUID> [reason] [-a] [-s/-ss]
    permission: banx.kick
  warn:
    description: "warn a player"
    usage: /<command> <player | UUID> [reason] [-a] [-s/-ss]
    permission: banx.warn

  tempban:
    description: "tempban a player"
    usage: /<command> <player | UUID> <number, s|m|h|d|w|M|y> [reason] [-a] [-s/-ss]
    permission: banx.tempban
  tempmute:
    description: "tempmute a player"
    usage: /<command> <player | UUID> <number, s|m|h|d|w|M|y> [reason] [-a] [-s/-ss]
    permission: banx.tempmute
  tempwarn:
    description: "tempwarn a player"
    usage: /<command> <player | UUID> <number, s|m|h|d|w|M|y> [reason] [-a] [-s/-ss]
    permission: banx.tempmute

  ipban:
    description: "ban a player"
    usage: /<command> <player | UUID | IP> [reason] [-a] [-s/-ss]
    permission: banx.ipban
  ipmute:
    description: "mute a player"
    usage: /<command> <player | UUID | IP> [reason] [-a] [-s/-ss]
    permission: banx.ipmute
  ipkick:
    description: "kick a player"
    usage: /<command> <player | UUID | IP> [reason] [-a] [-s/-ss]
    permission: banx.ipkick
  ipwarn:
    description: "warn a player"
    usage: /<command> <player | UUID | IP> [reason] [-a] [-s/-ss]
    permission: banx.ipwarn

  tempipban:
    description: "tempban a player"
    usage: /<command> <player | UUID | IP> <number, s|m|h|d|w|M|y> [reason] [-a] [-s/-ss]
    permission: banx.tempipban
  tempipmute:
    description: "tempmute a player"
    usage: /<command> <player | UUID | IP> <number, s|m|h|d|w|M|y> [reason] [-a] [-s/-ss]
    permission: banx.tempipmute
  tempipwarn:
    description: "tempwarn a player"
    usage: /<command> <player | UUID | IP> <number, s|m|h|d|w|M|y> [reason] [-a] [-s/-ss]
    permission: banx.tempipmute

  ##################### unpunishes

  unban:
    description: "unban a player"
    usage: /<command> <player | UUID> [-a] [-s/-ss]
    permission: banx.ban
  unmute:
    description: "unmute a player"
    usage: /<command> <player | UUID> [-a] [-s/-ss]
    permission: banx.mute
  unwarn:
    description: "unwarn a player"
    usage: /<command> <player | UUID> [-a] [-s/-ss]
    permission: banx.warn

  unipban:
    description: "unban an ip"
    usage: /<command> <player | UUID | IP> [-a] [-s/-ss]
    permission: banx.ban
  unipmute:
    description: "unmute an ip"
    usage: /<command> <player | UUID | IP> [-a] [-s/-ss]
    permission: banx.mute
  unipwarn:
    description: "unwarn an ip"
    usage: /<command> <player | UUID | IP> [-a] [-s/-ss]
    permission: banx.warn


  kickall:
    description: "kick all but certain targets"
    usage: /<command> <player | UUID | IP>... [reason]
    permission: banx.kickall
  getip:
    description: "get the ip of a player"
    usage: /<command> <player | UUID>
    permission: banx.getip
  forcespawn:
    description: "force players to spawn"
    usage: /<command> <all / join> [!identifiers]
    permission: banx.forcespawn
  #lockdown:
  #  description: "lockdown server"
  #  usage: /<command># <all / join> [!identifiers]
  #  permission: banx.lockdown
  #history:
  #  description: "view the punishment history of a player"
  #  usage: /<command> <player | UUID>
  #  permission: banx.history
  getuuid:
    description: "get the uuid of a player"
    usage: /<command> <player>
    permission: banx.getuuid

  #namehistory:
  #  description: "get the username history of a player"
  #  usage: /<command> <player | UUID>
  #  permission: banx.namehistory

  clearbans:
    description: "clear the ban history of a player"
    usage: /<command> <player | UUID>
    permission: banx.clear.bans
  clearkicks:
    description: "clear the kick history of a player"
    usage: /<command> <player | UUID>
    permission: banx.clear.kicks
  clearmutes:
    description: "clear the mute history of a player"
    usage: /<command> <player | UUID>
    permission: banx.clear.mutes
  clearwarns:
    description: "clear the warn history of a player"
    usage: /<command> <player | UUID>
    permission: banx.clear.warns

# maybe should remove these ... :
  #clearipbans:
  #  description: "clear the ban history of an ip"
  #  usage: /<command> <player | UUID | IP>
  #  permission: banx.clear.ipbans
  #clearipkicks:
  #  description: "clear the kick history of an ip"
  #  usage: /<command> <player | UUID | IP>
  #  permission: banx.clear.ipkicks
  #clearipmutes:
  #  description: "clear the mute history of an ip"
  #  usage: /<command> <player | UUID | IP>
  #  permission: banx.clear.ipmutes
  #clearipwarns:
  #  description: "clear the warn history of an ip"
  #  usage: /<command> <player | UUID | IP>
  #  permission: banx.clear.ipwarns

permissions:
  banx.*:
    default: op
    description: "give players with op everything by default."
    children:
      banx.ban: true
      banx.mute: true
      banx.kick: true
      banx.warn: true

      banx.tempban: true
      banx.tempmute: true
      banx.tempwarn: true

      banx.ipban: true
      banx.ipmute: true
      banx.ipkick: true
      banx.ipwarn: true

      banx.tempipban: true
      banx.tempipmute: true
      banx.tempipwarn: true

      banx.unban: true
      banx.unmute: true
      banx.unwarn: true
      banx.unipban: true
      banx.unipmute: true
      banx.unipwarn: true

      banx.kickall: true
      banx.getip: true
      #forcespawn
      #lockdown
      banx.history: true
      banx.getuuid: true
      banx.namehistory: true
      banx.clear.*: true

      banx.bypass.*: true

      banx.see.*: true


  # PUNISHES

  banx.ban:
    default: op
    description: "ban player."
  banx.mute:
    default: op
    description: "mute player."
  banx.kick:
    default: op
    description: "kick player."
  banx.warn:
    default: op
    description: "warn player."

  banx.tempban:
    default: op
    description: "tempban player."
  banx.tempmute:
    default: op
    description: "tempmute player."
  banx.tempwarn:
    default: op
    description: "tempwarn player."

  banx.ipban:
    default: op
    description: "ban ip."
  banx.ipmute:
    default: op
    description: "mute ip."
  banx.ipkick:
    default: op
    description: "kick ip."
  banx.ipwarn:
    default: op
    description: "warn ip."

  banx.tempipban:
    default: op
    description: "tempban ip."
  banx.tempipmute:
    default: op
    description: "tempmute ip."
  banx.tempipwarn:
    default: op
    description: "tempwarn ip."

  # UNPUNISHES

  banx.unban:
    default: op
    description: "unban player."
  banx.unmute:
    default: op
    description: "unmute player."
  banx.unwarn:
    default: op
    description: "unwarn player."

  banx.unipban:
    default: op
    description: "unban ip."
  banx.unipmute:
    default: op
    description: "unmute ip."
  banx.unipwarn:
    default: op
    description: "unwarn ip."

  banx.kickall:
    default: op
    description: "kick certain players."
  banx.getip:
    default: op
    description: "get the ip of a player."
  #forcespawn
  #lockdown
  banx.history:
    default: op
    description: "view the punishment history of a player."
  banx.getuuid:
    default: op
    description: "get the uuid of a player."
  banx.namehistory:
    default: op
    description: "get the username history of a player."

  banx.clear.*:
    default: op
    description: "clear punishments of a player"
    children:
      banx.clear.bans: true
      banx.clear.warns: true
      banx.clear.kicks: true
      banx.clear.mutes: true
      banx.clear.ipbans: true
      banx.clear.ipwarns: true
      banx.clear.ipkicks: true
      banx.clear.ipmutes: true

  banx.clear.bans:
    default: op
    description: "clear the ban history of a player."
  banx.clear.kicks:
    default: op
    description: "clear the kick history of a player."
  banx.clear.mutes:
    default: op
    description: "clear the mute history of a player."
  banx.clear.warns:
    default: op
    description: "clear the warn history of a player."
  banx.clear.ipbans:
    default: op
    description: "clear the ban history of a ip."
  banx.clear.ipkicks:
    default: op
    description: "clear the kick history of a ip."
  banx.clear.ipmutes:
    default: op
    description: "clear the mute history of a ip."
  banx.clear.ipwarns:
    default: op
    description: "clear the warn history of a ip."

  # BYPASS PERMS

  banx.bypass.*:
    default: op
    description: "bypass all punishments inflicted upon yourself."
    children:
      banx.bypass.kick: true
      banx.bypass.mute: true
      banx.bypass.warn: true
      banx.bypass.ban: true
      #banx.bypass.forcespawn: true
      #banx.bypass.lockdown: true

  banx.bypass.kick:
    default: op
    description: "ignore kicks inflicted upon yourself"
  banx.bypass.mute:
    default: op
    description: "ignore mutes inflicted upon yourself"
  banx.bypass.warn:
    default: op
    description: "ignore warns inflicted upon yourself"
  banx.bypass.ban:
    default: op
    description: "ignore bans inflicted upon yourself"

  # SEEING

  banx.see.*:
    default: false
    description: "see all attempted punishments 'overrides' by players"
    children:
      #banx.see.ban: true
      #banx.see.mute: true
      banx.see.ip: true
      banx.see.anonymous: true
      banx.see.silent: true
  banx.see.ban: # default: false because is spam
    default: false
    description: "see when a banned player attempts to join"
  banx.see.mute: # default: false because is spam
    default: false
    description: "see when a muted player attempts to join"
  banx.see.ip:
    default: op
    description: "see punish message ips."
  banx.see.anonymous:
    default: op
    description: "see the source of punishment if flagged with [-a]."
  banx.see.silent:
    default: op
    description: "see the punishment if flagged with [-s]."