Skip to content
This repository was archived by the owner on May 2, 2025. It is now read-only.

Material Shop

LukeGrahamLandry edited this page Feb 27, 2023 · 1 revision

The shop allows you to spend the materials you've generated to buy normal items.

Data Pack Format

Each offer that shows in the shop is a json file from the shop folder in datapacks. The names of the files don't matter as long as they're unique per namespace.

Object Structure:

  • cost: a MaterialCollection to be subtracted from the team when a player buys this offer.
  • items: a list of item stack objects to give the player when they buy this offer. (Optional)
    • item: the resource location of the item (ie. "minecraft:apple").
    • count: how many of the item to give.
    • tag: (optional). nbt data to give the stack, so you can have enchantments, etc. It's a string in the same format as commands use for nbt. Remember to escape any quotes for strings within the nbt with a backslash. (Optional)
  • minBaseLevel: determines when a team unlocks the ability to buy this offer. Optional, defaults to 0.
  • materials: a MaterialCollection to give the player's team when they buy this offer. (Optional)

Clone this wiki locally