Skip to content

Biome Loot

HIKI edited this page Oct 26, 2026 · 2 revisions

Offline loot by biome

Directory: tacznpc_loot/. This is expedition cargo, not Minecraft equipment loot tables and not an infinite trade catalogue.

default.json is the fallback and contains only pools:

{
  "pools": [
    {
      "name":"supplies",
      "chance":0.8,
      "rolls": {
        "min":1,
        "max":2
      },
      "entries":[
        {
          "item":"minecraft:bread",
          "weight":4,
          "count": {
            "min":1,
            "max":3
          }
        },
        {
          "item":"minecraft:iron_ingot",
          "weight":1,
          "chance":0.5,
          "count":1
        }
      ]
    }
  ]
}

Other files add exact biome selectors:

{
  "biomes":["minecraft:desert","minecraft:badlands"],"pools":[
    {
      "name":"salvage",
      "rolls":1,
      "entries":[
        {
          "item":"minecraft:iron_ingot",
          "count":2
        }
      ]
    }
  ]
}

Save the second example as desert.json. A specific biome file replaces the fallback; it does not add its pools to default.json. Empty pools deliberately disable loot for that biome. Do not put biomes on default.json.

Selection and limits

Field / rule Default or bound
Pool chance / entry chance 1; probability 0–1
rolls 1; integer or inclusive min/max, 0–16 per pool
entry weight 1; 1–1000000
entry count 1; integer or inclusive min/max, 1–64 and valid for the item's stack size
Pools per file At most 16
Total maximum rolls At most 64 per file
Entries per pool At most 256
Specific-file biome IDs At most 256
Files At most 128; up to 2 MiB each

Pool name labels the pool. File names use lowercase letters, digits, underscore and hyphen, ending in .json. Biome tags are not supported. One biome may not be assigned by two files; overlaps reject the offline/loot reload group.

All pools are visited, pool chance is tested, rolls are sampled, each roll chooses an entry by weight, then tests its chance and samples count. Repeated results are possible.

Only afterward are items filtered by the NPC's interests. There is no reroll because the NPC disliked an item. Multiple useful results can be kept. Rejected or full-cargo items do not become free world drops.

Components and TaCZ

{
  "item":"tacz:modern_kinetic_gun",
  "count":1,
  "nbt": {"GunId":"tacz:ak47","GunCurrentAmmoCount":0}
}

This is an entry object, not a complete file. NBT accepts SNBT or a JSON object and is written as custom_data. Use native components for component data such as minecraft:damage. Do not supply both nbt and components.minecraft:custom_data in the same entry.

Use count=1 for unstackable guns. GunId must exist in the gunpack. Interests match the base item/tag, not that GunId; the kept item preserves the original data.

Offline loot does not auto-equip gear. Ammo stored in cargo is not a finite-ammo supply system for the NPC's gun. Lost Cities district/layout selection is not implemented here.


Home · Configuration map · Troubleshooting

Clone this wiki locally