Minecraft Client Commands mod 2026 download
logo
minecraft mod Client Commands

Client Commands

Game Version: 1.16.5
Total Downloads: 490
Updated: Mar 4, 2021
Created: Mar 3, 2021
Download Client CommandsDownload Earlier Versions

Earlier Versions

Name Size Uploaded Game Version Downloads
Client Commands - 1.16.5 - v1.1 release 10.58 KB Mar 4, 2021 1.16.5 485 download Client Commands Client Commands - 1.16.5 - v1.1 releaseDownload
Client Commands - 1.16.5 - v1.0 release 10.34 KB Mar 4, 2021 1.16.5 5 download Client Commands Client Commands - 1.16.5 - v1.0 releaseDownload

Description

Share this:

Client Commands is a utility/library mod for other mods to use.
It reintroduces client side only commands to Minecraft (Forge).
This mod doesn't add anything on its own.

The prefix for client side commands is !

 

How to for Modders:
Commands can be registered 2 way, either by sending your commands over with the IMC system,
or by requesting to get the CommandDispatcher over IMC.
The latter is easier to use if you've got multiple commands.

You can just create your commands the same way as you would for normal Commands.
However, both the world and server of the CommandSource will be null!
Here's an example of the IMC system, the event is registered on the Mod Bus:

private static void enqueueIMC(InterModEnqueueEvent event){
    //Registering single commands expects a 'LiteralArgumentBuilder<?>'
    InterModComms.sendTo("clientcommands", "register_command", () -> /* command instance */);


    //Registering commands using a callback expects a 'Consumer<CommandDispatcher<CommandSource>>'
    InterModComms.sendTo("clientcommands", "register_commands", () -> this::registerCommands);

}

 

private static void registerCommands(CommandDispatcher<CommandSource> commandDispatcher){
    //register your commands to the dispatcher
}

 

Feedback as well as Questions can be posted in our Discord

The Discord Logo with a Join Us banner right next to it

Comments

Add a comment