Class PlayerAvailableCommandsEvent
java.lang.Object
com.velocitypowered.api.event.command.PlayerAvailableCommandsEvent
Allows plugins to modify the packet indicating commands available on the server to a
Minecraft 1.13+ client. The given
RootCommandNode
is mutable. Velocity will wait
for this event to finish firing before sending the list of available commands to the
client.-
Constructor Summary
ConstructorDescriptionPlayerAvailableCommandsEvent
(Player player, com.mojang.brigadier.tree.RootCommandNode<?> rootNode) Constructs an available commands event. -
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.brigadier.tree.RootCommandNode<?>
-
Constructor Details
-
PlayerAvailableCommandsEvent
public PlayerAvailableCommandsEvent(Player player, com.mojang.brigadier.tree.RootCommandNode<?> rootNode) Constructs an available commands event.- Parameters:
player
- the targeted playerrootNode
- the Brigadier root node
-
-
Method Details
-
getPlayer
-
getRootNode
public com.mojang.brigadier.tree.RootCommandNode<?> getRootNode()
-