Mods
Resource Packs
Data Packs
Modpacks
Shaders
Plugins
Mods Resource Packs Data Packs Plugins Shaders Modpacks
Get Modrinth App Upgrade to Modrinth+
Sign in
ModsPluginsData PacksShadersResource PacksModpacks
Sign in
Settings
Loot Table Modifier

Loot Table Modifier

Makes it possible to modify instead of replace loot tables through datapacks.

233.1k
21
Library

Compatibility

Minecraft: Java Edition

1.21.x
1.20.5–1.20.6

Platforms

Fabric

Supported environments

Server-side

90% of ad revenue goes to creators

Support creators and Modrinth ad-free with Modrinth+

Links

Report issues View source Join Discord server
Donate on Ko-fi

Creators

OffsetMonkey538
OffsetMonkey538 Member

Details

Licensed MIT
Published 11 months ago
Updated 4 months ago
DescriptionChangelogVersions

Loot Table Modifier

discord-singular modrinth
Requires Fabric API

todo: good readme for alpha version

Allows datapacks to modify loot tables, instead of just overwriting them.
Version 2 of the mod is currently in alpha. v2 adds more ways to modify loot tables than just adding to them
v2 will be backwards-compatible with v1 modifiers, so no need to worry about them breaking.

If you want to use v1, then see the original description below. If you do decide to try out the alpha version of v2 (please do), then please go ahead and read the documentation here and if you encounter any problems, have suggestions for new actions/predicates or just want to say literally anything about the mod, please please please join my discord and tell me about it. I want to make this as good as I can and any sort of feedback really helps.

Original Description

Allows datapacks (and thus mods as well) to add to loot tables, instead of just overwriting them.

This mod shouldn't impact performance while playing the game, but only when datapacks are reloading (joining a world, starting a server, /reload command, whatever else).
Performance impact during pack reloading varies depending on the datapacks.
The mod writes how long applying modifiers took in the console.

Also provides a datagen provider for creating loot table modifiers in mods.

A modifier json file includes two components:

  1. "modifies" - string or array, which defines the loot tables to modify. For example "minecraft:entities/creeper" or "minecraft:chests/abandoned_mineshaft"
  2. "pools" - array of loot pools. This works exactly the same as the "pools" in a vanilla loot table, thus you can generate a loot table online with a tool like misode.github.io and copy over the "pools" from the generated json. (I may fork it and add a generator for specifically this mod in the futureâ„¢)
    An example json file:
// example_pack/data/example/loot-table-modifier/loot_modifier/drop_tnt.json
{
    // Can also be a single identifier without an array
    // "modifies": "minecraft:entities/creeper",
    "modifies": [
        "minecraft:entities/creeper",
        "minecraft:entities/zombie"
    ],
    "pools": [
        {
            "bonus_rolls": 0.0,
            "entries": [
                {
                    "type": "minecraft:item",
                    "functions": [
                        {
                            "add": false,
                            "count": {
                                "type": "minecraft:uniform",
                                "max": 1.0,
                                "min": 0.0
                            },
                            "function": "minecraft:set_count"
                        }
                    ],
                    "name": "minecraft:tnt"
                }
            ],
            "rolls": 1.0
        }
    ]
}

Depend on inside mod:

repositories {
    // ...
    maven {
        name = "OffsetMods538"
        url = "https://maven.offsetmonkey538.top/releases"
        content {
            includeGroup "top.offsetmonkey538.loottablemodifier"
        }
    }
}


dependencies {
    // ...
    modImplementation "top.offsetmonkey538.loottablemodifier:loot-table-modifier:1.0.1+1.21.1"
}

Modrinth is open source.

app-ads@1633f40

© Rinth, Inc.

Company

TermsPrivacyRulesCareers

Resources

SupportBlogDocsStatus

Interact

Discord X (Twitter) Mastodon Crowdin
Get Modrinth App Settings
NOT AN OFFICIAL MINECRAFT SERVICE. NOT APPROVED BY OR ASSOCIATED WITH MOJANG OR MICROSOFT.