Mod

Command Actions

Quick rating

Command Actions

No reviews yet

Allows mcfunction files to be executed on various events

API/Library
Mod Loaders
Quilt
Minecraft

Community voices

Reviews

Filter by exact patch versions
Loading exact versions…
Match includes

Click once to include, again to exclude, again to clear

Rating Any
Any 0.5 1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
Min
Max
Play Status
Reviews
Time Played
hrs+
Verified developers only
Has developer response
List view
Grid view
Compact view
Sort by
Date
Rating
Helpful
Unhelpful
Edited
Sort ascending
Delete this review?

This removes your review from the project. You can write a new review after.

Review submitted for moderation

Your updated review is now pending. It has been sent to moderators, who will check that it meets our guidelines before it appears publicly.

No reviews yet. Be the first to review this project!

Get it on

Available Platforms

Compatibility

Supported Environments

Dev Environment
Client Unsupported
Server Required

About

Project Details

Type
Mod
License
MIT License
Latest Version
1.1.0
Authors

For authors

Embed Badge

If you're the author of this project, you can embed a live badge anywhere that supports HTML or Markdown. It updates automatically whenever ratings change.

Custom banner text
ModDex rating badge preview

Use HTML for any page that supports it, or Markdown for README files and Markdown-based descriptions.

Identifiers

Platform IDs

Modrinth ID

Resources

External Links

Source Issues Wiki Discord

About

Description

Created for ModFest: Singularity

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.

How to run functions?

  • Open / create the .minecraft/config/command-actions/functions folder
  • Add function files or folders containing function files with the proper event names
    • Functions are detected either without an extension or with the .mcfunction extension.
    • All files in subdirectories are detected regardless of extension (or lack thereof)
    • Subdirectories are recursed to find functions

Current capabilities

Some preprocessing occurs on the input. All preprocessing directives are preceded with a hash (#), and any line preceded with a hash that is not a preprocessor is marked as a comment.

Preprocessing directives:

  • if, elif, else, endif - check if a given macro evaluates to true or 1, if a number is nonzero, if an equation results in a nonzero answer, or if two values are equal or unequal
  • define - define a replacement to be replaced later. Not recursive
  • undef - remove the definition of an already defined macro. This also works for system-provided macros.

Current events

Built-in macros are listed, and all builtins (including those provided by other mods) are preceded with C_

  • server-ready - called after the server reports it's ready for players
    • serverName
    • isSinglePlayer
    • online
    • motd
    • player-join - called when a player is placed into the server
      • All macros provided by server-ready
      • playerName and player as shorthand
      • playerUUID
      • auth
      • firstJoin

Screenshots

Gallery

  • Player join mcfunction
    Player join mcfunction An example `.mcfunction` file which gets run whenever a player joins the server / their single-player world

Versions

Files

Relations

Project Relations

More like this

Similar Mods

Suggestions use data such as tags, dependencies, dependents, descriptions, titles, and more to rank how much they overlap with this mod.

On ModDex

Community snapshot

0
Reviews
0
Followers
0
In stacks

By the numbers

Statistics

~1,000
Downloads
Last Updated
CurseForge
Created
Last synced
When ModDex last fetched and imported data for this project from CurseForge or Modrinth. High-traffic and active projects are checked more often.
Next pipeline sync