Command Registration Callback
public interface CommandRegistrationCallback
Content copied to clipboard
Callback for when a server registers all commands.
To register some commands, you would register an event listener and implement the callback.
CommandRegistrationCallback.EVENT.register((dispatcher, dedicated) -> { // For example, this command is only registered on an integrated server if (!dedicated) dispatcher.register(CommandManager.literal("integrated_command").executes(context -> {...})); })};