Interface ClientCommandRegistrationCallback


public interface ClientCommandRegistrationCallback
Callback for when client commands are registered to the dispatcher.

To register some commands, you would register an event listener and implement the callback.

See ClientCommands for more details and an example.

  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    register(com.mojang.brigadier.CommandDispatcher<FabricClientCommandSource> dispatcher, net.minecraft.commands.CommandBuildContext buildContext)
    Called when registering client commands.
  • Field Details

  • Method Details

    • register

      void register(com.mojang.brigadier.CommandDispatcher<FabricClientCommandSource> dispatcher, net.minecraft.commands.CommandBuildContext buildContext)
      Called when registering client commands.
      Parameters:
      dispatcher - the command dispatcher to register commands to
      buildContext - object exposing access to the game's holders