Back to mods
Unruled API project artwork

CurseForge · Minecraft mod

Unruled API

Expands on the vanilla gamerules to add new gamerules types for other mods to use

Choose a version Pick your version below, then grab the matching file.

Quick answer

Which Unruled API release should I use?

Updated 2 years ago
Latest stable file Unruled API 0.4 - Fabric 1.20
Game version 1.20.2, 1.20.3, 1.20.1
Loader Fabric, Quilt

Unruled API 0.4 - Fabric 1.20 targets 1.20.2, 1.20.3, 1.20.1 with Fabric, Quilt. The project page does not say whether this file belongs on the client, dedicated server, or both. No extra mods listed for this file.

Where it goes

Is Unruled API required on the client, server, or both?

The project page does not say whether this file belongs on the client, dedicated server, or both.

Client Source doesn’t say
Dedicated server Source doesn’t say
Loader for this release Fabric, Quilt
Required install it here Optional supported, not mandatory Not supported do not install here Source doesn’t say do not assume

The source does not explicitly classify this release as client-only or server-only.

What else does Unruled API 0.4 - Fabric 1.20 need?

Unruled API 0.4 - Fabric 1.20. Change the file and its required mods may change too.

No extra mods listed for this file

This file does not list any required mods. Do not add a library just because a different file uses it.

This file does not list any required or optional mods.

Before you install it

Add Unruled API without breaking your instance.

Built for Unruled API 0.4 - Fabric 1.20. Pick another file and the loader, install side or required mods may change.

  1. 01

    Stick to this file

    Use Unruled API 0.4 - Fabric 1.20. It targets 1.20.2, 1.20.3, 1.20.1 with Fabric, Quilt; another release may have different loader, side or dependency requirements.

  2. 02

    Bring the mods it needs

    This file does not list any required mods. Do not add a library just because a different file uses it.

  3. 03

    Put it on the correct side

    The project page does not say whether this file belongs on the client, dedicated server, or both.

  4. 04

    Pick the file you checked

    Use the “Get this file” button beside Unruled API 0.4 - Fabric 1.20. It opens that exact file at the source.

About this project

What does Unruled API add?

Unruled API

(for some reason CurseForge doesn't like to properly render the boxed url or code blocks, along other aspects, sorry about that. Don't hesitate to head on to the Modrinth page to see the proper and colored version)


Allows to create new form of gamerules, beyond the restrictive vanilla integers and booleans.

Albeit not registering them automatically, this mod allows you to easily create new floating, long, double, string, text and enum-driven gamerules, using the generative static methods of the mc.recraftors.unruled_api.UnruledApi class.

For consistency, methods have also been created to allow instantiating vanilla gamerules.

Example:

public void gamerulesRegistration() {

    myGameRule = registerGamerule("my_gamerule", category, UnruledApi.createFloat(1.5));

    myOtherGameRule = registerGamerule("my_other_gamerule", category, UnruledApi.createString("some text"));

    myLastGameRule = registerGamerule("my_last_gamerule", category, UnruledApi.createBoolean(false, (server, rule) -> {

        onLastRuleChange(server, rule);

    }));

}

Each rule can also be easily consulted using the IGameRulesProvider interface.

Example:

String value = ((IGameRulesProvider)gamerules).unruled_getString(myStringGameRule);float aFloat = ((IGameRulesProvider)gamerules).unruled_getFloat(myFloatGameRule);

How to use in your project

You can implement this mod in your project using the Modrinth maven.

Don't hesitate to read the official documentation.

Need help

Don't hesitate to join our Discord!

Add the Modrinth maven repository

repositories {
    maven {
        name = "Modrinth"
        url = "https://api.modrinth.com/maven"
    }
}
&nbsp;<br /><br />

Import the mod

loom example:

dependencies {    // using modApi allows your project's dependents to also import dependencies by default    modApi "maven.modrinth:unruled-api:${project.unruled_version}"}

forgeGradle example:

dependencies {    implementation "maven.modrinth:unruled-api:${project.unruled_version}"}

For copyright reasons, we require you to not include (JiJ, jar-in-a-jar, shadow, etc) this mod inside of your own. Thank you for your comprehension.

Project description from CurseForge.

Pick your setup

Unruled API by Minecraft version and loader

Choose the version and loader you play, then open the matching release.

49 available setups

Showing the newest 12 of 13 game versions. Older files are in the list below.

Check the dependencies, then try the file in a copied instance before changing a world you care about.

Recent files

Unruled API versions and loaders

16 of 16 releases match

Looking for an older file? The official CurseForge project page is in Resources.