Back to mods
SolLib project artwork

Modrinth · Minecraft mod

SolLib

Lets mods shine by bringing a constellation of (mostly) data utilities.

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

Quick answer

Which SolLib release should I use?

Updated last month
Latest stable file neo-1.21.1-1.3
Game version 1.21.1, 1.21.2, 1.21.3
Loader NeoForge

SolLib neo-1.21.1-1.3 targets 1.21.1, 1.21.2, 1.21.3 with NeoForge. Installation on the client is optional. Installation on the dedicated server is optional. No extra mods listed for this file.

Where it goes

Is SolLib required on the client, server, or both?

Installation on the client is optional. Installation on the dedicated server is optional.

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

The source marks this as usable on both the client and server.

What else does SolLib neo-1.21.1-1.3 need?

neo-1.21.1-1.3. 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 SolLib without breaking your instance.

Built for SolLib neo-1.21.1-1.3. Pick another file and the loader, install side or required mods may change.

  1. 01

    Stick to this file

    Use neo-1.21.1-1.3. It targets 1.21.1, 1.21.2, 1.21.3 with NeoForge; 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

    Installation on the client is optional. Installation on the dedicated server is optional.

  4. 04

    Pick the file you checked

    Use the “Get this file” button beside neo-1.21.1-1.3. It opens that exact file at the source.

About this project

What does SolLib add?

Banner

This is a core library for Minecraft mods. Yes, we know, very original.

Believe it or not, copy-pasting a bunch of classes across every project is neither the most efficient nor the most stable idea.


Sol offers a whole constellation of common code for mod developpement.

Most of them orbit around data, multiloader and rendering helpers. A few key highlights being:

Easy config system.

Loaded as soon as you want it, easy to setup and accessible from other mods without the need for hard dependencies.

SolConfig config = MOD.createConfig("sollib/test", 1.0, builder -> builder
    .addObject("category", category -> category
        .comment("This is a comment")
        .add("hello", "world")
        .add("easyconfig", true)
    )
);

MOD.getLogger().info(config.get("category.hello", ""));
// world

Runtime data, controlled by code.

This lets you edit datapack files at runtime, potentially allowing to change recipes depending on config values, edit or disable compat recipes if their target mods are not loaded, automatically generate models for dynamically defined items, and much more.

SolRegistries.Data.RUNTIME.addJson(Identifier.of("minecraft", "recipe/dropper.json"), json -> {
    if (json == null) return null;
    if (!config.get("recipe.copper_dropper", false)) return null;
    
    json.getAsJsonObject("key")
            .getAsJsonObject("#")
            .addProperty("item", "minecraft:copper_ingot");
    return json;
});

Rendering helpers.

Centralized and loader agnostic. No need to make more mixins, either.

ResourceLocation TEXTURE = MOD.makeID("textures/models/sword_overlay.png");

SolClientRegistries.Render.ITEM.register(stack -> stack.is(Items.DIAMOND_SWORD) && stack.isEnchanted(),
        (stack, context, matrices, bufferSource, light, overlay) -> {
    matrices.scale(1.005f, 1.005f, 1.005f);
    matrices.translate(0, 0.995, 0.4975);
    matrices.mulPose(Axis.XP.rotationDegrees(180));

    MockItemRenderer.renderItem(matrices, bufferSource, light, TEXTURE);
});

Simplified registry.

That you can call in the common code, complete with all the syntax sugar you need: define models, burn time, stripping results and everything about a feature at the same time.

MOD.register(BlockHolder.class, "block_block", () -> new Block(BlockBehaviour.Properties.of()))
    .withItem(item -> item.withFuel(200)).dropsSelf()
    .withSlab().withStairs().withWall()
    .withFlammability(20, 5);

For the average user, making this page as flashy as we can won't really matter. It's only a library after all.

But if you are a developer and are curious about it, the best way to learn is to read the (wip) Wiki or join the Discord.

Project description from Modrinth.

Pick your setup

SolLib by Minecraft version and loader

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

14 available setups

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

Recent files

SolLib versions and loaders

14 of 14 releases match

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