Skip to content

staff.yml

Moderation: staff mode and its toolbar, vanish, staff chat, broadcast, freeze, invsee, lastinv, tickets and strikes: offences, their share of points, the count that disbands.

How it plays: read the guide

Every example on this page is taken from the shipped staff.yml. Changes apply with /hcf reload, the toolbar included.

Switch

staff.yml
# Turns the whole module off: no staff mode, no vanish, no staff channel, and the
# commands answer that the module is disabled. Anybody already in staff mode when
# you reload keeps their toolbar until they leave it - their real inventory is
# still held in the database, and /staff gives it back.
enabled: true

Mining alerts

staff.yml
# "Found Diamonds": a line when a player breaks into a vein of a valuable ore,
# once per vein and with its size - an x-ray client shows as a player who finds
# vein after vein. Ores placed by a player are never reported.
mining-alerts:
  enabled: true
  # The blocks reported, as the server spells them.
  ores:
    - DIAMOND_ORE
    - DEEPSLATE_DIAMOND_ORE
    - ANCIENT_DEBRIS
    - EMERALD_ORE
    - DEEPSLATE_EMERALD_ORE
  # staff: only players with hcfcore.staff (and the console) are told, with the
  # position. everyone: everybody reads "[FD] player found 8 Diamond Ore", staff
  # still get the position on their own line.
  audience: staff
  # The most blocks one vein is counted up to.
  max-vein: 32
  # A player in creative is not reported.
  ignore-creative: true
Key As shipped What it does
enabled true The alerts at all
ores diamond, ancient debris, emerald The blocks reported, as the server spells them; an unknown name is left out with a warning
audience staff staff: only hcfcore.staff and the console, with the position. everyone: everybody reads the "[FD]" line, without the position
max-vein 32 The most blocks one vein is counted up to, 1 to 256
ignore-creative true A player in creative is not reported

Staff mode

staff.yml
staff-mode:
  # Entering staff mode hides you from players who cannot see vanished staff.
  vanish: true
  # Entering staff mode lets you fly.
  flight: true
  # No damage taken, none dealt, no mob aggro, and nothing picked up. The pickup
  # part matters more than it looks: a staff member standing in the drops of the
  # fight they are watching would otherwise collect the loot into an inventory
  # that is emptied when they leave the mode.
  invulnerable: true
  # Tell other staff when somebody enters or leaves the mode.
  announce: true

  # The toolbar, by inventory slot. 0-8 is the hotbar; 0-35 is the whole
  # inventory. Two items cannot share a slot - the first one wins and the second
  # is reported in the console.
  #
  #   material     any item name, e.g. COMPASS, BOOK, BLAZE_ROD
  #   name         display name, & colour codes allowed
  #   lore         optional lines under the name
  #   command      the command run when the item is used, WITHOUT the leading /.
  #                It runs as you, so your own permissions apply.
  #                %player% becomes the player you clicked, %staff% becomes you.
  #   needs-target true if the command needs a player: the item then only works
  #                by right-clicking somebody, and says so if used on air.
  #
  # Any command works here, including one from another plugin - the only rule is
  # that it has to exist, or the slot looks like a tool and answers "unknown
  # command".
  items:
    0:
      material: COMPASS
      name: "{secondary}&lPlayer Tracker"
      lore:
        - "{muted}Teleports you to the nearest player."
      command: "staff tpnearest"
    1:
      material: ENDER_EYE
      name: "{primary}&lRandom Teleport"
      lore:
        - "{muted}Teleports you to a random player."
      command: "staff randomtp"
    2:
      material: BOOK
      name: "{warning}&lInspect"
      lore:
        - "{muted}Right-click a player to see"
        - "{muted}what they are carrying."
      command: "invsee %player%"
      needs-target: true
    3:
      material: PACKED_ICE
      name: "{secondary}&lFreeze"
      lore:
        - "{muted}Right-click a player to hold"
        - "{muted}them for a check."
      command: "freeze %player%"
      needs-target: true
    7:
      # Grey while you can be seen, green while you are vanished.
      material: GRAY_DYE
      vanished-material: LIME_DYE
      name: "{success}&lVanish"
      lore:
        - "{muted}Toggles whether players can see you."
        - "{muted}Grey: seen. Green: vanished."
      command: "vanish"
    8:
      material: BARRIER
      name: "{error}&lLeave Staff Mode"
      lore:
        - "{muted}Gives your own items back."
      command: "staff"
Key As shipped What it does
vanish true Entering staff mode vanishes you
flight true Entering staff mode lets you fly
invulnerable true No damage taken or dealt, no mob aggro, nothing picked up
announce true Tell other staff who enters and leaves
items six slots The toolbar, by inventory slot (0-8 the hotbar)

A toolbar slot:

Key What it does
material The item
name, lore Its name and lines, & colours
command Run as the staff member, without /. %player% is the player clicked, %staff% the staff member. Any command, another plugin's included
needs-target true if the item works only by right-clicking a player
vanished-material The item shown while its holder is vanished, in place of material — the shipped Vanish switch: GRAY_DYE, LIME_DYE when vanished

Vanish and staff chat

staff.yml
vanish:
  # Also remove vanished staff from the player list, not only from sight.
  hide-from-tab: true
  # Who can still see vanished staff. Give this to your senior ranks so they are
  # not invisible to each other; nobody holds it by default, operators included.
  see-permission: "hcfcore.staff.vanish.see"
staff.yml
staff-chat:
  enabled: true
  # %player% is who spoke, %message% is what they said. Their own & codes only
  # work with hcfcore.chat.color.
  format: "{primary}[SC] {secondary}%player%{muted}: {secondary}%message%"
Key As shipped What it does
vanish.hide-from-tab true Also hide vanished staff from the player list
vanish.see-permission hcfcore.staff.vanish.see Who still sees vanished staff; nobody holds it by default
staff-chat.enabled true The staff channel
staff-chat.format &9[SC] ... %player% and %message%

Broadcast and clear chat

staff.yml
broadcast:
  # %message% is the text given to /broadcast; its & codes only work with
  # hcfcore.chat.color.
  format: "{dark}[{error}Broadcast{dark}] {secondary}%message%"
  # How many blank lines /clearchat pushes. There is no API to clear a client's
  # chat - the history lives on the client - so the only way is to push it off
  # the screen. Chat height differs between clients, hence the setting. Staff are
  # skipped: they usually need to read whatever caused the clear.
  clear-chat-lines: 100
Key As shipped What it does
format &8[&cBroadcast&8] ... /broadcast's line, with %message%
clear-chat-lines 100 Blank lines /clearchat pushes; staff are skipped

Freeze

staff.yml
freeze:
  enabled: true
  # Commands a frozen player may still run, without the slash. A check is a
  # conversation: somebody who cannot answer can only sit there or disconnect,
  # and disconnecting is the one thing the hold exists to discourage. An empty
  # list is honoured as a choice - delete the key entirely to get these back.
  allowed-commands:
    - msg
    - r
    - reply
    - tell
    - w
    - whisper
  # Record a ban when somebody disconnects while frozen. This is the standard
  # answer and the only thing that makes a freeze mean anything, but it is a ban,
  # so it is a switch. Lift one with /freeze unban <player>.
  #
  # It is NOT a deathban and does not live in the deathban table: turning
  # deathbans off in pvp.yml must not quietly turn off the enforcement of every
  # freeze as well.
  ban-on-logout: true
  # How often to remind a frozen player that they are held, in seconds.
  # 0 tells them once and then leaves them alone.
  reminder-seconds: 10
Key As shipped What it does
enabled true /freeze
allowed-commands private messages Commands a frozen player may still run, without /
ban-on-logout true Disconnecting while frozen bans, until /freeze unban
reminder-seconds 10 How often the frozen player is reminded; 0 once

Invsee, lastinv and tickets

staff.yml
invsee:
  enabled: true
  # Read-only for everybody; hcfcore.staff.invsee.edit is needed on top of the
  # staff node to change anything. Nobody holds it by default, operators
  # included. On a server where the items are the economy, an accidental drag in
  # somebody's inventory cannot be undone and looks exactly like staff theft.
  #
  # The window shows the 36 storage slots - that is what a player inventory is.
  # Armour and the off-hand are printed as a line of text instead.
staff.yml
last-inventory:
  enabled: true
  # How many deaths to keep per player. Each row is a whole inventory, so this is
  # the difference between an archive and a table that grows for ever.
  keep: 3
staff.yml
tickets:
  # /report <player> <reason> and /request <message>. They share one queue,
  # because they are the same act with a different word on the front: somebody
  # wants staff attention, and here is why.
  #
  # Staff use /tickets, a menu of the queue, oldest first: left-click takes a
  # ticket and teleports to it (to the reported player, or else to whoever asked),
  # right-click closes it. /tickets list|view|claim|close <id> do the same by id,
  # from the console too. Whoever raised a ticket is told when it is taken and
  # when it is closed - without the staff member's name.
  enabled: true
  # How long one player waits between raising tickets. Without it, one person can
  # fill the queue faster than staff can read it.
  cooldown-seconds: 60
Key As shipped What it does
invsee.enabled true /invsee, read-only without hcfcore.staff.invsee.edit
last-inventory.enabled true /lastinv
last-inventory.keep 3 Deaths kept per player
tickets.enabled true /report, /request, /tickets
tickets.cooldown-seconds 60 Wait between two tickets from one player

Strikes

staff.yml
# Strikes punish a TEAM for what one of its members did - a member banned for
# cheating, typically. Staff strike a team by its name, or by a member's name,
# which also records the member:
#
#   /strike add <team|player> <reason>   (hcfcore.staff.strike)
#   /strike pardon <id>                  (hcfcore.staff.strike) - points taken and
#                                        a disband are not given back
#   /strike list [team|player]           (everybody; your own team by default)
#
# A strike is announced to the whole server.
strikes:
  enabled: true
  # How long a strike counts towards disband-at below. 0 means for the whole map.
  valid-seconds: 0

  # A team is disbanded when its ACTIVE strikes reach this number, whatever they
  # were for. 0: never.
  disband-at: 3

  # What a team can be struck for: /strike add <team|player> <offence> [details].
  # Each offence takes its share of the team's points (rounded down); everybody
  # sees a strike and the team's count, and the offence in /strike list - the
  # details staff add are for staff. Each offence takes:
  #   name                 how messages write it
  #   points-loss-percent  share of the team's points taken, 0 to 100
  #   commands: [...]      console commands, with %team%, %strikes% and %offence%
  offences:
    cheating:
      name: "Cheating"
      points-loss-percent: 50
    bug-abuse:
      name: "Bug abuse"
      points-loss-percent: 40
    boosting:
      name: "Kill boosting"
      points-loss-percent: 40
    teaming:
      name: "Teaming"
      points-loss-percent: 35
    other:
      name: "Other"
      points-loss-percent: 25
Key As shipped What it does
enabled true Strikes
valid-seconds 0 How long a strike counts; 0 for the whole map
disband-at 3 A team is disbanded when its active strikes reach this, whatever they were for; 0 for never
offences.<id>.name How messages write the offence
offences.<id>.points-loss-percent 25 to 50 Share of the team's points a strike for it takes, rounded down
offences.<id>.commands none Console commands run with it: %team%, %strikes%, %offence%

The shipped offences are cheating (50%), bug-abuse and boosting (40%), teaming (35%) and other (25%). Add, rename or remove any: the id is what staff type after /strike add <team>.

A staff.yml from before offences, with a ladder, keeps working with the shipped offences and a warning: move its numbers to offences and disband-at.

The whole shipped file

View it on GitHub.

staff.yml
# ---------------------------------------------------------------------------
# staff.yml - moderation tools
#
# Everything here can be changed without restarting: /hcf reload re-reads this
# file and the new values apply at once, including the toolbar.
#
# Lines "# --8<-- [start:...]" and "# --8<-- [end:...]" mark the parts the online
# documentation quotes from this file. They are comments and change nothing.
# ---------------------------------------------------------------------------

# Turns the whole module off: no staff mode, no vanish, no staff channel, and the
# commands answer that the module is disabled. Anybody already in staff mode when
# you reload keeps their toolbar until they leave it - their real inventory is
# still held in the database, and /staff gives it back.
enabled: true

# "Found Diamonds": a line when a player breaks into a vein of a valuable ore,
# once per vein and with its size - an x-ray client shows as a player who finds
# vein after vein. Ores placed by a player are never reported.
mining-alerts:
  enabled: true
  # The blocks reported, as the server spells them.
  ores:
    - DIAMOND_ORE
    - DEEPSLATE_DIAMOND_ORE
    - ANCIENT_DEBRIS
    - EMERALD_ORE
    - DEEPSLATE_EMERALD_ORE
  # staff: only players with hcfcore.staff (and the console) are told, with the
  # position. everyone: everybody reads "[FD] player found 8 Diamond Ore", staff
  # still get the position on their own line.
  audience: staff
  # The most blocks one vein is counted up to.
  max-vein: 32
  # A player in creative is not reported.
  ignore-creative: true

staff-mode:
  # Entering staff mode hides you from players who cannot see vanished staff.
  vanish: true
  # Entering staff mode lets you fly.
  flight: true
  # No damage taken, none dealt, no mob aggro, and nothing picked up. The pickup
  # part matters more than it looks: a staff member standing in the drops of the
  # fight they are watching would otherwise collect the loot into an inventory
  # that is emptied when they leave the mode.
  invulnerable: true
  # Tell other staff when somebody enters or leaves the mode.
  announce: true

  # The toolbar, by inventory slot. 0-8 is the hotbar; 0-35 is the whole
  # inventory. Two items cannot share a slot - the first one wins and the second
  # is reported in the console.
  #
  #   material     any item name, e.g. COMPASS, BOOK, BLAZE_ROD
  #   name         display name, & colour codes allowed
  #   lore         optional lines under the name
  #   command      the command run when the item is used, WITHOUT the leading /.
  #                It runs as you, so your own permissions apply.
  #                %player% becomes the player you clicked, %staff% becomes you.
  #   needs-target true if the command needs a player: the item then only works
  #                by right-clicking somebody, and says so if used on air.
  #
  # Any command works here, including one from another plugin - the only rule is
  # that it has to exist, or the slot looks like a tool and answers "unknown
  # command".
  items:
    0:
      material: COMPASS
      name: "{secondary}&lPlayer Tracker"
      lore:
        - "{muted}Teleports you to the nearest player."
      command: "staff tpnearest"
    1:
      material: ENDER_EYE
      name: "{primary}&lRandom Teleport"
      lore:
        - "{muted}Teleports you to a random player."
      command: "staff randomtp"
    2:
      material: BOOK
      name: "{warning}&lInspect"
      lore:
        - "{muted}Right-click a player to see"
        - "{muted}what they are carrying."
      command: "invsee %player%"
      needs-target: true
    3:
      material: PACKED_ICE
      name: "{secondary}&lFreeze"
      lore:
        - "{muted}Right-click a player to hold"
        - "{muted}them for a check."
      command: "freeze %player%"
      needs-target: true
    7:
      # Grey while you can be seen, green while you are vanished.
      material: GRAY_DYE
      vanished-material: LIME_DYE
      name: "{success}&lVanish"
      lore:
        - "{muted}Toggles whether players can see you."
        - "{muted}Grey: seen. Green: vanished."
      command: "vanish"
    8:
      material: BARRIER
      name: "{error}&lLeave Staff Mode"
      lore:
        - "{muted}Gives your own items back."
      command: "staff"

vanish:
  # Also remove vanished staff from the player list, not only from sight.
  hide-from-tab: true
  # Who can still see vanished staff. Give this to your senior ranks so they are
  # not invisible to each other; nobody holds it by default, operators included.
  see-permission: "hcfcore.staff.vanish.see"

staff-chat:
  enabled: true
  # %player% is who spoke, %message% is what they said. Their own & codes only
  # work with hcfcore.chat.color.
  format: "{primary}[SC] {secondary}%player%{muted}: {secondary}%message%"

broadcast:
  # %message% is the text given to /broadcast; its & codes only work with
  # hcfcore.chat.color.
  format: "{dark}[{error}Broadcast{dark}] {secondary}%message%"
  # How many blank lines /clearchat pushes. There is no API to clear a client's
  # chat - the history lives on the client - so the only way is to push it off
  # the screen. Chat height differs between clients, hence the setting. Staff are
  # skipped: they usually need to read whatever caused the clear.
  clear-chat-lines: 100

freeze:
  enabled: true
  # Commands a frozen player may still run, without the slash. A check is a
  # conversation: somebody who cannot answer can only sit there or disconnect,
  # and disconnecting is the one thing the hold exists to discourage. An empty
  # list is honoured as a choice - delete the key entirely to get these back.
  allowed-commands:
    - msg
    - r
    - reply
    - tell
    - w
    - whisper
  # Record a ban when somebody disconnects while frozen. This is the standard
  # answer and the only thing that makes a freeze mean anything, but it is a ban,
  # so it is a switch. Lift one with /freeze unban <player>.
  #
  # It is NOT a deathban and does not live in the deathban table: turning
  # deathbans off in pvp.yml must not quietly turn off the enforcement of every
  # freeze as well.
  ban-on-logout: true
  # How often to remind a frozen player that they are held, in seconds.
  # 0 tells them once and then leaves them alone.
  reminder-seconds: 10

invsee:
  enabled: true
  # Read-only for everybody; hcfcore.staff.invsee.edit is needed on top of the
  # staff node to change anything. Nobody holds it by default, operators
  # included. On a server where the items are the economy, an accidental drag in
  # somebody's inventory cannot be undone and looks exactly like staff theft.
  #
  # The window shows the 36 storage slots - that is what a player inventory is.
  # Armour and the off-hand are printed as a line of text instead.

last-inventory:
  enabled: true
  # How many deaths to keep per player. Each row is a whole inventory, so this is
  # the difference between an archive and a table that grows for ever.
  keep: 3

tickets:
  # /report <player> <reason> and /request <message>. They share one queue,
  # because they are the same act with a different word on the front: somebody
  # wants staff attention, and here is why.
  #
  # Staff use /tickets, a menu of the queue, oldest first: left-click takes a
  # ticket and teleports to it (to the reported player, or else to whoever asked),
  # right-click closes it. /tickets list|view|claim|close <id> do the same by id,
  # from the console too. Whoever raised a ticket is told when it is taken and
  # when it is closed - without the staff member's name.
  enabled: true
  # How long one player waits between raising tickets. Without it, one person can
  # fill the queue faster than staff can read it.
  cooldown-seconds: 60

# Strikes punish a TEAM for what one of its members did - a member banned for
# cheating, typically. Staff strike a team by its name, or by a member's name,
# which also records the member:
#
#   /strike add <team|player> <reason>   (hcfcore.staff.strike)
#   /strike pardon <id>                  (hcfcore.staff.strike) - points taken and
#                                        a disband are not given back
#   /strike list [team|player]           (everybody; your own team by default)
#
# A strike is announced to the whole server.
strikes:
  enabled: true
  # How long a strike counts towards disband-at below. 0 means for the whole map.
  valid-seconds: 0

  # A team is disbanded when its ACTIVE strikes reach this number, whatever they
  # were for. 0: never.
  disband-at: 3

  # What a team can be struck for: /strike add <team|player> <offence> [details].
  # Each offence takes its share of the team's points (rounded down); everybody
  # sees a strike and the team's count, and the offence in /strike list - the
  # details staff add are for staff. Each offence takes:
  #   name                 how messages write it
  #   points-loss-percent  share of the team's points taken, 0 to 100
  #   commands: [...]      console commands, with %team%, %strikes% and %offence%
  offences:
    cheating:
      name: "Cheating"
      points-loss-percent: 50
    bug-abuse:
      name: "Bug abuse"
      points-loss-percent: 40
    boosting:
      name: "Kill boosting"
      points-loss-percent: 40
    teaming:
      name: "Teaming"
      points-loss-percent: 35
    other:
      name: "Other"
      points-loss-percent: 25