Interface ClientSendMessageEvents.ModifyCommand

Enclosing class:
ClientSendMessageEvents
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface ClientSendMessageEvents.ModifyCommand
  • Method Summary

    Modifier and Type
    Method
    Description
    Called when the client sends a command, which is whenever the player executes a command including client commands registered with fabric-command-api.
  • Method Details

    • modifySendCommandMessage

      String modifySendCommandMessage(String command)
      Called when the client sends a command, which is whenever the player executes a command including client commands registered with fabric-command-api. Is not called when command messages are blocked. The command string does not include a slash at the beginning. Use ClientSendMessageEvents.COMMAND if not modifying the command.
      Parameters:
      command - the command that will be sent to the server, without a slash at the beginning.
      Returns:
      the modified command that will be sent to the server, without a slash at the beginning.