Minecraft:Bedrock Edition level format/Item format: Difference between revisions
More actions
imported>Rostiger Bot m Bot: Modifying zh:基岩版世界格式/物品格式 to zh:基岩版存档格式/物品格式 |
Fix template calls: add MC/ prefix |
||
| (One intermediate revision by the same user not shown) | |||
| Line 1: | Line 1: | ||
{{ | {{MC/Exclusive|bedrock}} | ||
This page lists NBT structures of items {{ | This page lists NBT structures of items {{MC/In|bedrock}}. | ||
Item NBT is used both in the player's inventory and Ender inventory, and in chest block entities, dropped item entities, etc. | Item NBT is used both in the player's inventory and Ender inventory, and in chest block entities, dropped item entities, etc. | ||
| Line 7: | Line 7: | ||
== Item Stack == | == Item Stack == | ||
All items share this base: | All items share this base: | ||
* {{ | * {{MC/Nbt|compound}}: The item's root tag. | ||
** {{ | ** {{MC/Nbt|compound|Block}}: (May not exist) What block is placed when placing a block item. | ||
*** {{ | *** {{MC/Bedrock nbt|Block}} | ||
** {{ | ** {{MC/Nbt|list|CanDestroy}}: (May not exist) Controls what block types this item can destroy. | ||
*** {{ | *** {{MC/Nbt|string}}: A block ID. | ||
** {{ | ** {{MC/Nbt|list|CanPlaceOn}}: (May not exist) Controls what block types this block may be placed on. | ||
*** {{ | *** {{MC/Nbt|string}}: A block ID. | ||
** {{ | ** {{MC/Nbt|byte|Count}}: Number of items stacked in this inventory slot. | ||
** {{ | ** {{MC/Nbt|short|Damage}}: The metadata value. Note that this tag does not store items' damage value. | ||
** {{ | ** {{MC/Nbt|string|Name}}: The item ID. | ||
** {{ | ** {{MC/Nbt|compound|tag}}: (May not exist) Additional information about the item. | ||
** {{ | ** {{MC/Nbt|byte|WasPickedUp}}: Unknown. | ||
== General Tags == | == General Tags == | ||
Items with durability store their damage value in NBT. Additionally, items can have custom display names and lore. There is also the '''RepairCost''' tag which tracks anvil usage for items, making them more costly with every use of the anvil. | Items with durability store their damage value in NBT. Additionally, items can have custom display names and lore. There is also the '''RepairCost''' tag which tracks anvil usage for items, making them more costly with every use of the anvil. | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|int|Damage}}: (May not exist) The damage value for this item. Defaults to 0. | ||
** {{ | ** {{MC/Nbt|compound|display}}: (May not exist) Display properties. | ||
*** {{ | *** {{MC/Nbt|list|Lore}}: (May not exist) List of strings to display as lore for the item. | ||
**** {{ | **** {{MC/Nbt|string}}: (May not exist) A line of text for the lore of an item. | ||
*** {{ | *** {{MC/Nbt|string|Name}}: (May not exist) The JSON text component to use to display the item name. | ||
** {{ | ** {{MC/Nbt|byte|minecraft:item_lock}}: 1 for "lock in slot". 2 for "lock in inventory". | ||
** {{ | ** {{MC/Nbt|byte|minecraft:keep_on_death}}: 1 if keeping on death.{{MC/Needs testing}} | ||
** {{ | ** {{MC/Nbt|int|RepairCost}}: (May not exist) Number of experience levels to add to the base level cost when repairing, combining, or renaming this item with an [[Minecraft:Anvil]]. | ||
** {{ | ** {{MC/Nbt|byte|Unbreakable}}: 1 or 0 (true/false) - (may not exist) if this item's durability is allowed to take damage. | ||
== Enchantment Tags == | == Enchantment Tags == | ||
{{ | {{MC/In|bedrock}}, there's only one way to store enchantment NBTs: both enchanted items and [[Minecraft:Enchanted Book]] share the {{MC/Nbt|list|ench}} tag. | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|list|ench}}: Contains enchantments on this item. | ||
*** {{ | *** {{MC/Nbt|compound}}: A single enchantment. | ||
**** {{ | **** {{MC/Nbt|short|id}}: The ID of the enchantment. | ||
**** {{ | **** {{MC/Nbt|short|lvl}}: The level of the enchantment, where 1 is level 1. Values are clamped between 0 and 255 when reading. | ||
== Armor Trim == | == Armor Trim == | ||
Additional fields when an [[Minecraft:armor]] is [[Minecraft:Smithing Template|trimmed]]: | Additional fields when an [[Minecraft:armor]] is [[Minecraft:Smithing Template|trimmed]]: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|compound|Trim}}: Properties of the armor trim. | ||
*** {{ | *** {{MC/Nbt|string|Material}}: The material which decides the color of armor trim. | ||
*** {{ | *** {{MC/Nbt|string|Pattern}}: The pattern of armor trim. | ||
== Book and Quills == | == Book and Quills == | ||
Additional fields for | Additional fields for book and quills: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|list|pages}}: (May not exist) The list of pages in the book. | ||
*** {{ | *** {{MC/Nbt|compound}}: A single page in the book. | ||
**** {{ | **** {{MC/Nbt|string|photoname}}: Filename of a [[Minecraft:photo]] in this page if included. | ||
**** {{ | **** {{MC/Nbt|string|text}}: The text in this page. | ||
== Bucket of Aquatic Mob == | == Bucket of Aquatic Mob == | ||
Additional fields for [[Minecraft:bucket]]: | Additional fields for [[Minecraft:bucket]]: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Bedrock nbt|Entity|entity}} | ||
** Additional tags unique to fish or axolotl entity. | ** Additional tags unique to fish or axolotl entity. | ||
** {{ | ** {{MC/Nbt|byte|AppendCustomName}}: 1 or 0 (true/false) - true if the entity color, state, and id are used to generate the bucket item's name. | ||
** {{ | ** {{MC/Nbt|string|BodyID}}: (May not exist) The translation key of entity's state. Used to generate the bucket item's name. | ||
** {{ | ** {{MC/Nbt|string|ColorID}}: (May not exist) The translation key of a color. Used to generate the bucket item's name. | ||
** {{ | ** {{MC/Nbt|string|Color2ID}}: (May not exist) The translation key of another color. Used to generate the bucket item's name. | ||
** {{ | ** {{MC/Nbt|string|CustomName}}: (May not exist) The custom name of entity in it. Used to generate the bucket item's name. | ||
** {{ | ** {{MC/Nbt|string|GroupName}}: (May not exist) Unknown. Used to generate the bucket item's name. | ||
== Crossbow == | == Crossbow == | ||
Additional fields for [[Minecraft:crossbow]]: | Additional fields for [[Minecraft:crossbow]]: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|compound|chargedItem}}: The items this crossbow has charged. | ||
*** {{ | *** {{MC/Bedrock nbt|Item Stack|item}} | ||
== Filled Map == | == Filled Map == | ||
Additional fields for | Additional fields for filled map: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|byte|map_display_players}}: 1 or 0 (true/false) - (may not exist) true if the map displays player markers. | ||
** {{ | ** {{MC/Nbt|byte|map_is_init}}: (May not exist) Unknown. | ||
** {{ | ** {{MC/Nbt|byte|map_is_scaling}}: (May not exist) Unknown. | ||
** {{ | ** {{MC/Nbt|int|map_name_index}}: The index of the map's name. | ||
** {{ | ** {{MC/Nbt|int|map_scale}}: (May not exist) Unknown. | ||
** {{ | ** {{MC/Nbt|long|map_uuid}}: The UUID of the map used in this item. | ||
== Firework Rocket == | == Firework Rocket == | ||
Additional fields for | Additional fields for firework rocket: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|compound|Fireworks}} | ||
*** {{ | *** {{MC/Nbt|list|Explosions}}: List of compounds representing each explosion this firework causes. | ||
**** {{ | **** {{MC/Nbt|compound}}: A explosion effect. | ||
***** {{ | ***** {{MC/Bedrock nbt|Firework Explosion}} | ||
*** {{ | *** {{MC/Nbt|byte|Flight}}: Indicates the flight duration of the firework (equals the amount of gunpowder used in crafting the rocket). Can be anything from -128 to 127. | ||
== Firework Star == | == Firework Star == | ||
Additional fields for | Additional fields for firework star: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|int|customColor}}: The color of this firework star. | ||
** {{ | ** {{MC/Nbt|compound|FireworksItem}}: The explosion effect contributed by this firework star. | ||
*** {{ | *** {{MC/Bedrock nbt|Firework Explosion}} | ||
== Glow Stick == | == Glow Stick == | ||
Additional fields for | Additional fields for glow stick: | ||
* {{ | * {{MC/Nbt|compound}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|long|active_time}}: (May not exist) Unknown. | ||
== Horse Armor == | == Horse Armor == | ||
Additional fields for | Additional fields for horse armor: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|int|customColor}}: (May not exist) The color of the leather armor. | ||
== Lodestone Compass == | == Lodestone Compass == | ||
Additional fields for | Additional fields for lodestone compass: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|int|trackingHandle}}: The ID of lodestone to track. | ||
== Potion == | == Potion == | ||
Additional fields for [[Minecraft:potion]]: | Additional fields for [[Minecraft:potion]]: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|byte|wasJustBrewed}}: 1 or 0 (true/false) - (may not exist) true if item is brewed in brewing stand. | ||
== Shield == | == Shield == | ||
Additional fields for [[Minecraft:shield]]: | Additional fields for [[Minecraft:shield]]: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|int|Base}}: The base color of the banner on the shield. See [[Minecraft:Banner#Block_data]]. | ||
** {{ | ** {{MC/Nbt|list|Patterns}}: (May not exist) List of all patterns applied to the banner on the shield. | ||
*** {{ | *** {{MC/Nbt|compound}}: An individual pattern. | ||
**** {{ | **** {{MC/Nbt|int|Color}}: The base color of the pattern. See [[Minecraft:Banner#Block_data]]. | ||
**** {{ | **** {{MC/Nbt|string|Pattern}}: The pattern ID code. See [[Minecraft:Banner#Block_data]]. | ||
== Written Book == | == Written Book == | ||
Additional fields for | Additional fields for written book: | ||
* {{ | * {{MC/Nbt|compound|tag}}: Parent tag. | ||
** {{ | ** {{MC/Nbt|string|author}}: The author of this book. | ||
** {{ | ** {{MC/Nbt|int|generation}}: The copy tier of the book. 0 = Original, 1 = Copy of original, 2 = Copy of copy. | ||
** {{ | ** {{MC/Nbt|list|pages}}: The list of pages in the book. | ||
*** {{ | *** {{MC/Nbt|compound}}: A single page in the book. | ||
**** {{ | **** {{MC/Nbt|string|photoname}}: Filename of a [[Minecraft:photo]] in this page if included. | ||
**** {{ | **** {{MC/Nbt|string|text}}: The text in this page. | ||
** {{ | ** {{MC/Nbt|string|title}}: The title of this book. | ||
** {{ | ** {{MC/Nbt|long|xuid}}: Unknown. | ||
</div> | </div> | ||
pt:Formato de nível da Edição Bedrock/Formatos de item | |||
zh:基岩版存档格式/物品格式 | |||
Latest revision as of 19:51, 9 April 2026
Script error: No such module "Exclusive". This page lists NBT structures of items in Template:Editions.
Item NBT is used both in the player's inventory and Ender inventory, and in chest block entities, dropped item entities, etc.
Item Stack
All items share this base:
- Template:Nbt/sprite: The item's root tag.
- Template:Nbt/sprite Block: (May not exist) What block is placed when placing a block item.
- Template:Nbt/sprite CanDestroy: (May not exist) Controls what block types this item can destroy.
- Template:Nbt/sprite: A block ID.
- Template:Nbt/sprite CanPlaceOn: (May not exist) Controls what block types this block may be placed on.
- Template:Nbt/sprite: A block ID.
- Template:Nbt/sprite Count: Number of items stacked in this inventory slot.
- Template:Nbt/sprite Damage: The metadata value. Note that this tag does not store items' damage value.
- Template:Nbt/sprite Name: The item ID.
- Template:Nbt/sprite tag: (May not exist) Additional information about the item.
- Template:Nbt/sprite WasPickedUp: Unknown.
General Tags
Items with durability store their damage value in NBT. Additionally, items can have custom display names and lore. There is also the RepairCost tag which tracks anvil usage for items, making them more costly with every use of the anvil.
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite Damage: (May not exist) The damage value for this item. Defaults to 0.
- Template:Nbt/sprite display: (May not exist) Display properties.
- Template:Nbt/sprite Lore: (May not exist) List of strings to display as lore for the item.
- Template:Nbt/sprite: (May not exist) A line of text for the lore of an item.
- Template:Nbt/sprite Name: (May not exist) The JSON text component to use to display the item name.
- Template:Nbt/sprite Lore: (May not exist) List of strings to display as lore for the item.
- Template:Nbt/sprite minecraft:item_lock: 1 for "lock in slot". 2 for "lock in inventory".
- Template:Nbt/sprite minecraft:keep_on_death: 1 if keeping on death.
<needs testing></needs testing> - Template:Nbt/sprite RepairCost: (May not exist) Number of experience levels to add to the base level cost when repairing, combining, or renaming this item with an Minecraft:Anvil.
- Template:Nbt/sprite Unbreakable: 1 or 0 (true/false) - (may not exist) if this item's durability is allowed to take damage.
Enchantment Tags
in Template:Editions, there's only one way to store enchantment NBTs: both enchanted items and Minecraft:Enchanted Book share the Template:Nbt/sprite ench tag.
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite ench: Contains enchantments on this item.
- Template:Nbt/sprite: A single enchantment.
- Template:Nbt/sprite id: The ID of the enchantment.
- Template:Nbt/sprite lvl: The level of the enchantment, where 1 is level 1. Values are clamped between 0 and 255 when reading.
- Template:Nbt/sprite: A single enchantment.
- Template:Nbt/sprite ench: Contains enchantments on this item.
Armor Trim
Additional fields when an Minecraft:armor is trimmed:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite Trim: Properties of the armor trim.
- Template:Nbt/sprite Material: The material which decides the color of armor trim.
- Template:Nbt/sprite Pattern: The pattern of armor trim.
- Template:Nbt/sprite Trim: Properties of the armor trim.
Book and Quills
Additional fields for book and quills:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite pages: (May not exist) The list of pages in the book.
- Template:Nbt/sprite: A single page in the book.
- Template:Nbt/sprite photoname: Filename of a Minecraft:photo in this page if included.
- Template:Nbt/sprite text: The text in this page.
- Template:Nbt/sprite: A single page in the book.
- Template:Nbt/sprite pages: (May not exist) The list of pages in the book.
Bucket of Aquatic Mob
Additional fields for Minecraft:bucket:
- Template:Nbt/sprite tag: Parent tag.
- Template:Bedrock nbt/inherit
- Additional tags unique to fish or axolotl entity.
- Template:Nbt/sprite AppendCustomName: 1 or 0 (true/false) - true if the entity color, state, and id are used to generate the bucket item's name.
- Template:Nbt/sprite BodyID: (May not exist) The translation key of entity's state. Used to generate the bucket item's name.
- Template:Nbt/sprite ColorID: (May not exist) The translation key of a color. Used to generate the bucket item's name.
- Template:Nbt/sprite Color2ID: (May not exist) The translation key of another color. Used to generate the bucket item's name.
- Template:Nbt/sprite CustomName: (May not exist) The custom name of entity in it. Used to generate the bucket item's name.
- Template:Nbt/sprite GroupName: (May not exist) Unknown. Used to generate the bucket item's name.
Crossbow
Additional fields for Minecraft:crossbow:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite chargedItem: The items this crossbow has charged.
Filled Map
Additional fields for filled map:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite map_display_players: 1 or 0 (true/false) - (may not exist) true if the map displays player markers.
- Template:Nbt/sprite map_is_init: (May not exist) Unknown.
- Template:Nbt/sprite map_is_scaling: (May not exist) Unknown.
- Template:Nbt/sprite map_name_index: The index of the map's name.
- Template:Nbt/sprite map_scale: (May not exist) Unknown.
- Template:Nbt/sprite map_uuid: The UUID of the map used in this item.
Firework Rocket
Additional fields for firework rocket:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite Fireworks
- Template:Nbt/sprite Explosions: List of compounds representing each explosion this firework causes.
- Template:Nbt/sprite: A explosion effect.
- Template:Nbt/sprite Flight: Indicates the flight duration of the firework (equals the amount of gunpowder used in crafting the rocket). Can be anything from -128 to 127.
- Template:Nbt/sprite Explosions: List of compounds representing each explosion this firework causes.
- Template:Nbt/sprite Fireworks
Firework Star
Additional fields for firework star:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite customColor: The color of this firework star.
- Template:Nbt/sprite FireworksItem: The explosion effect contributed by this firework star.
Glow Stick
Additional fields for glow stick:
- Template:Nbt/sprite: Parent tag.
- Template:Nbt/sprite active_time: (May not exist) Unknown.
Horse Armor
Additional fields for horse armor:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite customColor: (May not exist) The color of the leather armor.
Lodestone Compass
Additional fields for lodestone compass:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite trackingHandle: The ID of lodestone to track.
Potion
Additional fields for Minecraft:potion:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite wasJustBrewed: 1 or 0 (true/false) - (may not exist) true if item is brewed in brewing stand.
Shield
Additional fields for Minecraft:shield:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite Base: The base color of the banner on the shield. See Minecraft:Banner#Block_data.
- Template:Nbt/sprite Patterns: (May not exist) List of all patterns applied to the banner on the shield.
- Template:Nbt/sprite: An individual pattern.
- Template:Nbt/sprite Color: The base color of the pattern. See Minecraft:Banner#Block_data.
- Template:Nbt/sprite Pattern: The pattern ID code. See Minecraft:Banner#Block_data.
- Template:Nbt/sprite: An individual pattern.
Written Book
Additional fields for written book:
- Template:Nbt/sprite tag: Parent tag.
- Template:Nbt/sprite author: The author of this book.
- Template:Nbt/sprite generation: The copy tier of the book. 0 = Original, 1 = Copy of original, 2 = Copy of copy.
- Template:Nbt/sprite pages: The list of pages in the book.
- Template:Nbt/sprite: A single page in the book.
- Template:Nbt/sprite photoname: Filename of a Minecraft:photo in this page if included.
- Template:Nbt/sprite text: The text in this page.
- Template:Nbt/sprite: A single page in the book.
- Template:Nbt/sprite title: The title of this book.
- Template:Nbt/sprite xuid: Unknown.
pt:Formato de nível da Edição Bedrock/Formatos de item zh:基岩版存档格式/物品格式