-
Notifications
You must be signed in to change notification settings - Fork 0
Pack format
A pack contains:
-
pack.mcmeta
Pack information, such as the pack name and author -
assetsfolder
Same as resource packs: e.g. textures and models for your custom blocks and items -
datafolder
Same as data packs: e.g. crafting recipes, loot tables and tags for your custom blocks and items -
contentfolder
Custom blocks and item properties, e.g. type of block (cube, stairs, slab etc.) and explosion resistance
This file contains information about the pack.
This is similar to (but not the same as!) the pack.mcmeta file in resource and data packs.
JSON format (* = required):
pack*object
|
||||||||||||||||||||||||||||||||||||
pack.mcmeta:
{ "pack": { "supported_formats": 1, "uuid": "b8f2e967-a4c2-40h6-8b7a-e3b470d23ffb", "display_name": "Willows", "version": "1.2", "description": "Adds willow trees", "authors": [ "Martijn Muijsers" ], "credits": [ { "name": "Enzo Mortelli", "role": "Model artist" }, { "name": "Thomas Sourtzis", "role": "Plugin tester" } ] } }
Note: There is one invalid character in the above UUID, so that you can't accidentally copy it and then forget to change it. You must generate a new UUID for your pack, for example by copying the random UUID that you see when you go to: www.uuidgenerator.net
This folder is identical to the assets folder in resource packs.
Amongst others, it contains block states, models and textures.
The top-level subfolders have a namespace as name (for example assets/minecraft for vanilla resources, or assets/willows for resources for a pack named Willows).
Wiki links for some subfolders:
assets/willows/blockstates/willow_log.json
(based on assets/minecraft/blockstates/oak_log.json):
{ "variants": { "axis=x": { "model": "willows:block/willow_log_horizontal", "x": 90, "y": 90 }, "axis=y": { "model": "willows:block/willow_log" }, "axis=z": { "model": "willows:block/willow_log_horizontal", "x": 90 } } }
assets/willows/models/block/willow_log_horizontal.json
(based on assets/minecraft/models/block/oak_log_horizontal.json):
{ "parent": "minecraft:block/cube_column_horizontal", "textures": { "end": "willows:block/willow_log_top", "side": "willows:block/willow_log" } }
assets/willows/models/item/willow_sapling.json
(based on assets/minecraft/models/item/oak_sapling.json):
{ "parent": "minecraft:item/generated", "textures": { "layer0": "willows:block/willow_sapling" } }
assets/willows/lang/en_us.json
(based on assets/minecraft/lang/en_us.json):
{ "block.willows.willow_basket": "Willow Basket", "block.willows.willow_log": "Willow Log", "block.willows.willow_planks": "Willow Planks", "block.willows.willow_sapling": "Willow Sapling", "block.willows.willow_wood": "Willow Wood", "block.willows.stripped_willow_log": "Stripped Willow Log", "block.willows.stripped_willow_wood": "Stripped Willow Wood", "item.willows.willow_twig_bundle": "Willow Twig Bundle" }
This folder is identical to the data folder in data packs.
Amongst others, it contains crafting recipes, loot tables and tags.
The top-level subfolders have a namespace as name (for example data/willows for resources for a pack named Willows).
Wiki links for some subfolders:
data/willows/recipes/willow_planks.json
(based on data/minecraft/recipes/oak_planks.json):
{ "type": "minecraft:crafting_shapeless", "category": "building", "group": "planks", "ingredients": [ { "tag": "willows:willow_logs" } ], "result": { "count": 4, "item": "willows:willow_planks" } }
data/willows/tags/blocks/willow_logs.json
(based on data/minecraft/tags/blocks/oak_logs.json):
{ "values": [ "willows:willow_log", "willows:willow_wood", "willows:stripped_willow_log", "willows:stripped_willow_wood" ] }
data/willows/loot_tables/blocks/willow_bookshelf.json
(based on data/minecraft/loot_tables/blocks/bookshelf.json):
{ "type": "minecraft:block", "pools": [ { "bonus_rolls": 0.0, "entries": [ { "type": "minecraft:alternatives", "children": [ { "type": "minecraft:item", "conditions": [ { "condition": "minecraft:match_tool", "predicate": { "enchantments": [ { "enchantment": "minecraft:silk_touch", "levels": { "min": 1 } } ] } } ], "name": "willows:willow_bookshelf" }, { "type": "minecraft:item", "functions": [ { "add": false, "count": 3.0, "function": "minecraft:set_count" }, { "function": "minecraft:explosion_decay" } ], "name": "minecraft:book" } ] } ], "rolls": 1.0 } ] }
This folder contains the new blocks and items.
For each namespace, it can contain two folders: blocks and items.
This folder contains a file for each new block type.
JSON format (* = required):
parent*string |
The parent block of this blockThe parent determines which block states this block has (including their collision boxes), and inherits some of the effects of that parent. For example, if you use "minecraft:oak_log" as parent, the block will have 3 block states (one per axis), and these will be placed correctly based on the block face that a player clicks.
The effects of the parent that will be inherited can be found on the Parents page. |
||||||||||||||||
propertiesobject
|
|||||||||||||||||
| parent-specific values(*) |
Depending on the value of parent, there may be some other values that are possible or required. For example, for stairs blocks, an additional full_block_state value is required. You can find which additional values exist on the Parents page.
|
||||||||||||||||
content/willows/blocks/willow_log.json:
{ "parent": "minecraft:oak_log" }
content/metal_working/blocks/gold_stairs.json:
{ "parent": "minecraft:bamboo_stairs" }
content/dirt_shapes/blocks/dirt_slab.json:
{ "parent": "minecraft:mud_brick_slab" }
This folder contains a file for each new item type.
JSON format (* = required):
parent*string |
The parent item of this itemThe parent determines which properties this item has, and inherits some of the effects of that item. For example, if you use the "minecraft:stone_bricks" as parent, the item will be a block item.
The effects of the parent that will be inherited can be found on the Parents page. |
||||||
propertiesobject
|
|||||||
| parent-specific values(*) |
Depending on the value of parent, there may be some other values that are possible or required. For example, for block items, an additional block value is possible (but not required). You can find which additional values exist on the Parents page.
|
||||||
content/willows/items/willow_log.json:
{ "parent": "minecraft:oak_log" }