RepoDocsMinecraft

Plushie Friends Data Pack Guide

This guide explains how to create a data pack that adds Plushie Friends plushies to loot tables.

Plushie loot rules roll on top of target loot tables. They do not replace vanilla or modded loot, so other data packs and mods keep working. The JSON format is the same across Fabric and NeoForge and across Minecraft 1.20.1, 1.21.1, 26.2, and 26.3. Changes apply after /reload.

Legacy format removed

The plushie_friends:set_plushie loot function and data/<namespace>/plushies/*.json files are no longer supported. All loot packs now use data/<namespace>/plushie_friends/loot/*.json.

Folder layout

A data pack is a folder (or zip file) containing pack.mcmeta and a data directory:

my_custom_plushies/
├── pack.mcmeta
└── data/
    └── example/
        └── plushie_friends/
            └── loot/
                └── common.json

Put each loot rule JSON file in data/<namespace>/plushie_friends/loot/<name>.json.

Use lowercase letters, numbers, underscores, periods, or hyphens for namespaces and file names.

Create pack.mcmeta

Use the pack.mcmeta format for your Minecraft version:

Minecraft version Format fields
1.20.1 "pack_format": 15
1.21.1 "pack_format": 48
26.2 "min_format": [107, 1], "max_format": [107, 1]
26.3 "min_format": [121, 0], "max_format": [121, 0]

Example for Minecraft 1.21.1:

{
  "pack": {
    "pack_format": 48,
    "description": "Custom Plushie Friends loot"
  }
}

Example for Minecraft 26.3:

{
  "pack": {
    "min_format": [121, 0],
    "max_format": [121, 0],
    "description": "Custom Plushie Friends loot"
  }
}

Quick start

Create data/example/plushie_friends/loot/common.json:

{
  "plushies": ["Notch", "jeb_", "Dinnerbone"],
  "chance": 0.15,
  "rolls": 1,
  "loot_tables": [
    "minecraft:chests/simple_dungeon",
    "minecraft:chests/village/*"
  ]
}

Each time a dungeon chest or any village chest generates loot, this rule rolls once with a 15% chance to add one plushie picked at random from plushies.

Loot rule fields

Each JSON file in data/<namespace>/plushie_friends/loot/ is an independent rule:

Field Required Default Description
plushies yes - Non-empty list of plushies that can drop. See Plushie entries.
loot_tables yes - Non-empty list of target loot table IDs or wildcard patterns.
exclude_loot_tables no [] List of loot table IDs or wildcard patterns to skip even if matched by loot_tables.
chance no 1.0 Probability from 0 to 1 for each roll to drop a plushie (0.15 = 15%).
rolls no 1 Non-negative integer number of independent rolls per loot generation.
lore no [] Default tooltip lines for entries that do not define their own lore.

Plushie entries

Each element in plushies uses one of two forms:

  1. Player name string (weight 1, uses the file’s lore):

    "Notch"
    
  2. Inline object:

    {
      "owner_name": "jeb_",
      "lore": ["Special edition"],
      "weight": 2
    }
    

    owner_name is required. lore and weight (integer >= 1, default 1) are optional.

When an entry sets lore, it replaces the file-level lore for that plushie. Set "lore": [] on an entry to clear the file-level lore.

Full example

{
  "plushies": [
    "Dinnerbone",
    {
      "owner_name": "SodaSyrup",
      "weight": 3
    },
    {
      "owner_name": "Notch",
      "lore": ["Rare find"],
      "weight": 1
    },
    {
      "owner_name": "jeb_",
      "lore": [],
      "weight": 1
    }
  ],
  "lore": ["Collected in the wild"],
  "chance": 0.1,
  "rolls": 1,
  "loot_tables": ["minecraft:chests/*"],
  "exclude_loot_tables": ["minecraft:chests/spawn_bonus_chest"]
}

In this example, Dinnerbone and SodaSyrup show "Collected in the wild", Notch shows "Rare find", and jeb_ has no lore.

Wildcards, non-chest tables, and overrides

  • Wildcards (*): * matches zero or more characters, including /. For example, "minecraft:chests/*" matches every vanilla chest table.

  • Default namespace: Omitting the namespace in loot_tables or exclude_loot_tables defaults to minecraft:. For example, "chests/simple_dungeon" equals "minecraft:chests/simple_dungeon".

  • Any loot table works: You can target entity drops ("minecraft:entities/zombie"), fishing ("minecraft:gameplay/fishing"), or archaeology ("minecraft:archaeology/*").

  • Overriding and disabling rules: A file at the same path in a higher-priority data pack replaces the lower-priority file. To disable another pack’s rule without editing it, override that path with:

    {
      "chance": 0
    }
    

Install, reload, and test

  1. Put your data pack folder (or zip) in <world folder>/datapacks/.
  2. Start the world, or run /reload if the world is open.
  3. Run /datapack list enabled to confirm that Minecraft enabled the pack.
  4. Test a matching table with /loot give @s loot minecraft:chests/simple_dungeon.

Troubleshooting

  • Invalid loot rule files log messages starting with Plushie loot in the server log.
  • A bad file is skipped without blocking valid files in the same pack or other packs.
  • Common issues are the wrong pack.mcmeta format for your Minecraft version, invalid JSON syntax, or missing owner_name or loot_tables.