Overview
Hubbly provides two commands for chat moderation: clearing chat history and locking/unlocking chat for non-privileged players./clearchat
Clears the chat for all online players by sending blank messages.Syntax
Aliases
/cc/clearc/cchat
Permission
Required to use the
/clearchat command.Default: opDescription: Clears the chatBehavior
- Verifies the sender has the required permission
- Sends 100 blank messages to every online player
- Effectively clears chat history from their screen
- Logs the action with the sender’s name to the debug log
Examples
This command sends blank messages to all players, regardless of their world or location. Players with chat logging plugins may still see the message history.
Technical Details
The command sends exactly 100 blank messages to ensure chat is fully cleared on most client configurations:/lockchat
Toggles chat lock status, preventing non-privileged players from sending messages.Syntax
Aliases
/lc
Permission
Required to use the
/lockchat command and bypass the chat lock.Default: Not set (must be granted manually)Behavior
- Checks if the sender has the required permission
- Toggles the global chat lock state
- Broadcasts a message to all players (except those in disabled worlds)
- Prevents non-privileged players from sending chat messages when locked
Examples
Locking chat:Chat has been locked by <player_name>
Unlocking chat:
Chat has been unlocked by <player_name>
Chat Lock Behavior
When chat is locked:
- Players without the bypass permission cannot send messages
- Players with
hubbly.bypass.chator operator status can still send messages - Commands are not affected by chat lock
When chat is unlocked:
- All players can send messages normally
Disabled Worlds
The lock/unlock broadcast respects the disabled worlds configuration:Players in disabled worlds will not see the lock/unlock broadcast message.
Messages
Messages are configurable inlanguages/en.yml:
%player_name%- The name of the player who locked/unlocked chat
Permissions Summary
| Permission | Description | Default |
|---|---|---|
hubbly.command.clearchat | Use /clearchat command | op |
hubbly.command.lockchat | Use /lockchat command | (not set) |
hubbly.bypass.chat | Bypass chat lock restrictions | (not set) |
hubbly.command.* | All command permissions | op |
Source Reference
Implemented in:ClearChatCommand.java:42- Chat clearing handlerLockChatCommand.java:40- Chat lock toggle handlerLockChat.java- Chat lock state manager