Meteor commands are triggered by the player typing a prefix character (Documentation Index
Fetch the complete documentation index at: https://mintlify.com/qualk/take-care/llms.txt
Use this file to discover all available pages before exploring further.
. by default) followed by the command name in the chat box. Under the hood they use the Brigadier command dispatcher, the same library Minecraft itself uses for server commands. Each command extends meteordevelopment.meteorclient.commands.Command, builds a tree of literals and arguments by overriding build(), and is registered with Commands.add() in TakeCare.onInitialize().
Creating a command
Create a class extending Command
Add a new Java class inside the
commands/ package (kpn.qualk.takecare.commands). The class must extend meteordevelopment.meteorclient.commands.Command:commands/YourCommand.java
Call super() with the name and description
The
Command constructor takes two arguments:| Argument | Value |
|---|---|
name | A kebab-case string used after the prefix, e.g. "example" → .example |
description | A plain-text sentence shown in .help output |
The
name parameter must be in kebab-case. The prefix character (default .) is configured by the user in Meteor Client settings and cannot be overridden by the addon.Override build() and define the Brigadier command tree
The This produces two usable invocations:
build() method receives a LiteralArgumentBuilder pre-seeded with the command name. Use .executes() to attach an action to the current node, and .then() to add sub-literals or arguments.The base class exposes helper methods:info(String message)— sends a styled info message to the player’s chat.error(String message)— sends an error-styled message.literal(String name)— shorthand forCommands.literal(name).argument(String name, ArgumentType<?> type)— shorthand forCommands.argument(name, type).SINGLE_SUCCESS— the Brigadier constant for a successful execution (1).
commands/CommandExample.java
.example→ sendshi.example name <word>→ sendshi, <word>
Full working example
Below is the completeCommandExample class from the Take Care source (shown uncommented and ready to use):
commands/CommandExample.java