Skip to main content
Player events allow you to monitor and control all aspects of a player’s interaction with the proxy, from initial connection through authentication, gameplay, and disconnection.

Connection Events

ConnectionEvent

Fired when a client first connects to the proxy, before any protocol handshake occurs. This is the earliest point where you can interact with or modify the connection.
Example: Connection Logging

ConnectionHandshakeEvent

Fired when a handshake is established between a client and the proxy. This occurs after the initial connection but before login.
Example: Log Handshake Intent

Authentication Events

PreLoginEvent

Fired when a player initiates a connection but before authentication with Mojang or before the connection is fully established in offline mode.
PreLoginResult values:
  • AllowedPreLogin: Allow the login to proceed
  • DeniedPreLogin: Deny the login
  • ForceOnlineModePreLogin: Force online mode authentication
  • ForceOfflineModePreLogin: Force offline mode
Example: Whitelist Implementation

GameProfileRequestEvent

Fired after PreLoginEvent to set up the game profile for the user. This can be used to configure a custom profile, such as for skin replacement.
Example: Custom Skin System

LoginEvent

Fired when a player attempts to log in. This is your last chance to deny the login before the player enters the proxy.
Example: Maintenance Mode

PostLoginEvent

Fired after a player has successfully logged in to the proxy but before they are connected to any server.
Example: Welcome Message

Disconnect Event

DisconnectEvent

Fired when a player disconnects from the proxy.
LoginStatus values:
  • SuccessfulLoginStatus: Normal disconnect after successful login
  • ConflictingLoginStatus: Disconnected due to conflicting login
  • CanceledByUserLoginStatus: User canceled the login
  • CanceledByProxyLoginStatus: Proxy canceled the login
  • CanceledByUserBeforeCompleteLoginStatus: User canceled before completion
Example: Cleanup and Logging

Chat and Command Events

PlayerChatEvent

Fired when a player sends a chat message. Messages starting with ”/” trigger CommandExecuteEvent instead.
Example: Chat Filter

CommandExecuteEvent

Fired when someone attempts to execute a command.
Example: Command Logging and Blocking

Player Settings Event

PlayerSettingsChangedEvent

Fired when a player’s client settings are updated or initialized.
Example: Locale-Based Messages

Permission Event

PermissionsSetupEvent

Fired when a permission subject’s permissions are being initialized.
Example: Custom Permission System

Plugin Message Events

PlayerChannelRegisterEvent

Fired when a client sends a plugin message through the register channel.

PlayerChannelUnregisterEvent

Fired when a client sends a plugin message through the unregister channel.

PlayerClientBrandEvent

Fired when a player sends the minecraft:brand plugin message.
Example: Track Client Types

See Also