Skip to content

Moderation

Reece Williams edited this page Sep 2, 2026 · 2 revisions

Moderation

Staff and chat control tools: mute chat, freeze players, clear chat, spy on commands, protect dangerous commands, reports, and more. Everything lives under the Moderation: section of config.yml.

Requires: none for most. StaffAFK relies on LuckPerms (it swaps groups by running lp commands and reads the player's primary group from the LuckPerms API).

MuteChat

Toggles global chat on/off with /mutechat. While muted, anyone without the bypass perm gets their chat messages cancelled.

  • Config: Moderation.MuteChat
  • Default enabled: yes
  • Perms: mutechat.use (run the command), mutechat.bypass (talk while muted)
  • Notes: broadcasts the enable/disable message to everyone, %player% gets replaced with who toggled it.

CommandSpy

Lets staff watch other players' commands live. Toggle it per-staffer with /commandspy enable|disable. Watchers see CMDSPY name> /cmd for every command run (except their own).

  • Config: Moderation.CommandSpy
  • Default enabled: no
  • Perms: commandspy.use (toggle), commandspy.exempt (your commands don't show up to watchers)
  • Notes: ignored_commands skips certain commands from being spied (matches the first word or the whole command). PlaceholderAPI: %stools_commandspy% returns on or off for whether you're watching.
CommandSpy:
  Enabled: false
  permission: commandspy.use
  ignored_commands:
  - 'msg'

CommandProtect

Blocks a configurable list of dangerous commands (think /op, /pl, /lp, /reload-style stuff) so random players can't run them. Uses a separate CommandProtect.yml file, not the main config.

  • Config: Moderation.CommandProtect (just the on/off toggle), rest in CommandProtect.yml
  • Default enabled: yes
  • Notes: CommandProtect.yml holds:
    • ProtectedCommands - the commands to block (defaults include /op, /pl, /ver, /about, /icanhasbukkit, /lp, /luckperms)
    • AllowedPlayers - IGNs or UUIDs that can still run them
    • password - players run /commandprotect login <password> to add themselves to the allow-list at runtime (/commandprotect logout to remove). 15 failed attempts kicks them.
    • Command detection strips the plugin: prefix, so /servertools:op still gets caught as /op.

ClearChat

/clearchat spams blank lines to push chat history off everyone's screen, then broadcasts a "cleared by X" message.

  • Config: Moderation.ClearChat
  • Default enabled: yes
  • Perms: clearchat.use
  • Notes: lines is how many blank lines to send (default 100). msg is the broadcast, %player% is who cleared it.

NoColonInCommands

Blocks the plugin:command namespace bypass. Normally a player could run /essentials:fly to dodge a /fly override, this stops that. If the part after the colon is a command ServerTools itself aliases, it lets it through.

  • Config: Moderation.NoColonInCommands
  • Default enabled: yes
  • Perms: colon.use bypasses the block
  • Notes: only blocks when the colon is in the first word of the command (the namespace part), not in later arguments.

Freeze

/freeze <player> (alias /ss) locks a player in place. While frozen they can't move, drop or pick up items, take damage, chat, or teleport. Run it again to unfreeze.

  • Config: Moderation.Freeze
  • Default enabled: no
  • Perms: Freeze.use
  • Notes: sends the configured Message lines to the frozen player. Supports the %SUPPORT% variable (e.g. your discord link). Broadcasts to staff (holders of the freeze perm) if a frozen player logs out or back in. Works on offline players too (from cache).

WhitelistBypass

Lets perm-holders join even when the server whitelist would kick them, and optionally blocks /whitelist add from being run in-game.

  • Config: Moderation.WhitelistBypass
  • Default enabled: yes
  • Perms: whitelist.bypass (join past the whitelist)
  • Notes: DisableWhitelistCMDInGame: true stops players running /whitelist add in-game (console still works). Message is the kick message for non-whitelisted players, %player% supported.

Report

/report <player> <reason> pings online staff. Has a per-player cooldown.

  • Config: Moderation.Report
  • Default enabled: no
  • Perms: report.notify (receive the reports)
  • Notes: Cooldown in seconds (default 30), CooldownMSG shown while on cooldown (%timeleft%), ReportSuccess is the staff broadcast (%reporter%, %offender%, %reason%). Can't report yourself.

StaffAFK

/staffafk swaps a staffer into a dedicated AFK LuckPerms group (so they visually go "offline" from staff rank) and back. It saves their real primary group and OP status, then runs the GiveAFK console commands. Running it again restores them via RemoveAFK.

  • Config: Moderation.StaffAFK
  • Default enabled: no
  • Perms: staffafk.use
  • Requires: LuckPerms. It calls the LuckPerms API for the primary group and the default GiveAFK/RemoveAFK commands are lp user ... parent add/remove console commands.
  • Notes: StaffAFKGroup is the AFK group name, StaffGroups is which ranks count as staff. Strips OP while AFK and reapplies it after. State is stored in DATA/StaffAFKDatabase.yml and cleaned up on quit. PlaceholderAPI: %stools_staffafk% returns true/false.
StaffAFK:
  Enabled: false
  StaffAFKGroup: staffafk
  Permission: staffafk.use
  GiveAFK:
  - 'lp user %player% parent add %StaffAFKGroupName% server=global'
  - 'lp user %player% parent remove %UsersPrimaryGroup% server=global'
  RemoveAFK:
  - 'lp user %player% parent add %PlayerConfigPrimarygroup% server=global'
  - 'lp user %player% parent remove %StaffAFKGroupName% server=global'

TPAll

/tpall teleports every online player to you, with a slight random stagger so it's not all at once.

  • Config: Moderation.TPAll
  • Default enabled: yes
  • Perms: tools.tpall
  • Notes: no config beyond the toggle. Broadcasts a message when triggered.

Clone this wiki locally