Command Actions
by sschr15
Command Actions lets a Quilt server run .mcfunction files automatically when particular events happen, with a preprocessor for the function files it loads.
What it does
Function files are placed in folders named after the event they should run on, and the mod calls them when that event fires. Functions are detected whether they carry the .mcfunction extension or none at all, and subdirectories are scanned recursively, so nested folders are picked up as well. A file-system event triggers a reload so that changes to the files take effect without restarting the server.
The function files can use preprocessing directives. These include conditional blocks with if, elif, else and endif, where a condition is true when a given macro evaluates to a nonzero number or equation result, and comparisons that test two values for equality or inequality. Macros can be defined for later replacement and removed once defined, and the system-provided macros are available as well. A list of built-in macros, including those supplied by other mods, is available under a prefix starting with C.
Command Actions is a server-side mod with no client part, so players join without installing anything and only the server needs the file. It requires Quilt Kotlin Libraries (QKL). The mod is published for Quilt and only for 1.19.2, and it is open source under the MIT License.
Key features
Event-triggered functions
Function files run automatically on the events their folders are named for, without manual commands.
File detection rules
Functions are found with or without the .mcfunction extension, and nested subdirectories are searched recursively.
Conditional preprocessing
Directives such as if, elif, else and endif let a function file choose which lines to include.
Macros and built-ins
Macros can be defined, replaced and removed, and a list of built-in macros is provided along with those from other mods.
Gallery
Compatibility
Latest build for each game version and loader.
Only full game releases are shown. This mod publishes no snapshot builds.
Requirements
Dependencies declared by the latest file for each loader.
Required 1
Use cases
Who it’s for: Server owners who want commands to run automatically on events and who are comfortable writing mcfunction files with preprocessing directives.
Questions
Does Command Actions need to be installed on the client?
What does Command Actions require?
Which game versions does Command Actions support?
Can function files be placed in subfolders?
In the catalog
Command Actions is one of 3,514 Library mods on ModsFinder, and one of 628 Library mods for Quilt. 12,559 mods support Minecraft 1.19.2.
More from sschr15
Similar mods
What the author says
Command Actions provides an interface to automatically run.mcfunction files at particular events. They are loaded from the filesystem on every event call, ensuring that they are as up to date as they can be. Preprocessing directives: - if, elif, else, endif - check if a given macro evaluates to true or 1, if a number…
Official listing
- Modrinth page
- modrinth.com/mod/command-actions
- Owner
- sschr15
- Published
- 2022-08-20
- Updated on Modrinth
- 2022-08-23
- Facts verified
- 2026-10-15