HomeJavaModsLoot Injector
Loot Injector
Loot Injector — screenshot 1Loot Injector — screenshot 2

Loot Injector

Inject custom loot into any chest in the game — vanilla or modded — using simple JSON config files. No coding required.


✦ Features


✦ How It Works

Place a .json file in .minecraft/config/structureloot/pools/ and the mod injects your items into that loot table at runtime — no data pack, no /reload, no restart needed.

{
  "target_loot_table": "minecraft:chests/simple_dungeon",
  "enabled": true,
  "inject_items": [
    { "item": "minecraft:diamond",  "weight": 10.0, "min_count": 1.0, "max_count": 3.0 },
    { "item": "examplemod:rare_sword", "weight": 2.0, "min_count": 1.0, "max_count": 1.0,
      "nbt": "{display:{Name:'{\"text\":\"Ancient Blade\"}'}}" }
  ]
}

The weight field is a percentage chance per chest opening (not a pool weight). weight: 10.0 means a 10% chance each time that chest is opened.


✦ Custom Loot Chests

Define a named chest config in config/structureloot/chests/ and give it to any player via command:

/structureloot chest get mythic_chest

The player receives a named chest with pre-rolled items inside. The GUI lets you manage configs, add items, set rolls, and edit everything without editing files directly.


✦ Commands

All commands require OP level 2.

Command Description
/structureloot reload Reload all JSON configs
/structureloot list List all active pool rules
/structureloot validate Check all item IDs for errors
/structureloot export Export configs as a ZIP
/structureloot import Import a ZIP profile
/structureloot chest get Give a custom loot chest
/structureloot chest list List all chest configs
/structureloot debug items List registered items from a mod
/structureloot debug item Test a specific item ID

✦ GUI Editor

Open with the K keybind (rebindable in Controls → Structure Loot Injector).

The editor provides a full three-panel interface:


✦ Finding Item IDs

  1. Press F3+H in-game to enable advanced tooltips
  2. Hover over any item — the registry ID appears at the bottom of the tooltip
  3. For mods with NBT-based item variants, the full NBT tag is also shown

Or use the built-in command:

/structureloot debug items 

✦ Compatibility

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

Verified by MCModsHub

These come from our own check of the pack file, not from the source page.

Explore more