To define an item, the item definition must be defined in the behavior pack in a JSON file.All attributes, including item names, must be defined using item components.
The properties are part of the Item Definition. This helps the system determine how to parse and initialize this item.
Name | Type | Default Value | Description |
---|---|---|---|
format_version | Specifies the version of the game this entity was made in. If the version is lower than the current version, any changes made to the entity in the vanilla version will be applied to it. | ||
minecraft:item | Item definition, which includes the "description" and "components" sections. |
Example
{ "format_version": "1.20.20", "minecraft:item": { "description": { "identifier": "minecraft:blaze_rod" }, "components": { "minecraft:fuel": { "duration": 120.0 }, "minecraft:max_stack_size": 64, "minecraft:icon": { "texture": "blaze_rod" }, "minecraft:hand_equipped": true, "minecraft:display_name": { "value": "Blaze Rod" } } } }
List of all components that used in this item.
Name | Type | Default Value | Description |
---|---|---|---|
minecraft:allow_off_hand | JSON Object | The allow off hand component determines whether the item can be placed in the off hand slot of the inventory. | |
minecraft:block_placer | JSON Object | Block Placer item component. Items with this component will place a block when used.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:can_destroy_in_creative | JSON Object | The can destroy in creative component determines if the item will break blocks in creative when swinging. | |
minecraft:cooldown | JSON Object | Cool down time for a component. After you use an item, all items specified with the same `cool down category` setting becomes unusable for the duration specified by the 'cool down time' setting in this component.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:damage | JSON Object | The damage component determines how much extra damage the item does on attack. | |
minecraft:digger | JSON Object | Digger item component. You can specify how quickly this item can dig specific blocks. | |
minecraft:display_name | JSON Object | Display Name item component. Determines the text shown whenever an item's name is displayed (ex. hover text).Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0) | |
minecraft:durability | JSON Object | Durability item component. Determines how much damage this item takes before breaking and allows the item to be combined in crafting.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0) | |
minecraft:enchantable | JSON Object | The enchantable component determines what enchantments can be applied to the item. Not all enchantments will have an effect on all item components. | |
minecraft:entity_placer | JSON Object | Entity placer item component. You can specifiy allowed blocks that the item is restricted to.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0) | |
minecraft:food | JSON Object | When an item has a food component, it becomes edible to the player. Must have the 'minecraft:use_duration' component in order to function properly.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.30) | |
minecraft:fuel | JSON Object | Fuel item component. Allows this item to be used as fuel in a furnace to 'cook' other items.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0) | |
minecraft:glint | JSON Object | The glint component determines whether the item has the enchanted glint render effect on it. | |
minecraft:hand_equipped | JSON Object | This component determines if an item is rendered like a tool while in hand. | |
minecraft:hover_text_color | JSON Object | The hover text color component determines the color of the item name when hovering over it. | |
minecraft:icon | JSON Object | Icon item component. Determines the icon to represent the item in the UI and elsewhere.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0) | |
minecraft:interact_button | JSON Object | This component is a boolean or string that determines if the interact button is shown in touch controls and what text is displayed on the button. When set as true, default "Use Item" text will be used. | |
minecraft:item_storage | JSON Object | The Storage Item Component is used for storing Items within an Item's User DataExperimental toggles required: Vanilla Experiments Internal (NON_LOC) | |
minecraft:liquid_clipped | JSON Object | The liquid clipped component determines whether the item interacts with liquid blocks on use. | |
minecraft:max_stack_size | JSON Object | The max stack size component determines how many of the item can be stacked together. | |
minecraft:projectile | JSON Object | Projectile item component. projectile items shoot out, like an arrow.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:record | JSON Object | Record Item Component. Used by record items to play music. Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:repairable | JSON Object | Repairable item component. Determines the items that can be used to repair this item along with how much durability they repair.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:shooter | JSON Object | Shooter Item Component. Must have the 'minecraft:use_duration' component in order to function properly.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:should_despawn | JSON Object | Should despawn component determines if the item should eventually despawn while floating in the world | |
minecraft:stacked_by_data | JSON Object | The stacked by data component determines if the same item with different aux values can stack. Also defines whether the item actors can merge while floating in the world. | |
minecraft:tags | JSON Object | The tags component determines which tags an item has on it. | |
minecraft:throwable | JSON Object | Throwable item component. Throwable items, such as a snowball.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10) | |
minecraft:use_animation | JSON Object | This component determines which animation plays when using the item. | |
minecraft:use_modifiers | JSON Object | This component modifies use effects, including how long the item takes to use and the player's speed when used in combination with components like Shooter, Throwable or Food. | |
minecraft:wearable | JSON Object | Wearable item component.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.20) |
List of characters of an item. The description MUST contain an identifier; the other fields are optional.
Name | Type | Default Value | Description |
---|---|---|---|
identifier | String | The identifier for this item. The name must include a namespace and must not use the Minecraft namespace unless overriding a Vanilla item. | |
menu_category | JSON Object | The creative group name and category for this item. |
The creative group name and category for this item.
Name | Type | Default Value | Description |
---|---|---|---|
category | 69, 70, 71, 72, 74 | The Creative Category that this item belongs to. Defaults to "items". | |
group | String | The Creative Group that this item belongs to. Group name is limited to 256 characters. | |
is_hidden_in_commands | Boolean | Determines whether or not this item can be used with commands. Commands can use items by default. |
The allow off hand component determines whether the item can be placed in the off hand slot of the inventory.
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | Whether the item can be placed in the off hand slot. |
Block Placer item component. Items with this component will place a block when used.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
block | JSON Object | Defines the block that will be placed. | |
use_on | Array | List of block descriptors that contain blocks that this item can be used on. If left empty, all blocks will be allowed. |
The can destroy in creative component determines if the item will break blocks in creative when swinging.
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | Whether the item can destroy blocks while in creative. |
Cool down time for a component. After you use an item, all items specified with the same `cool down category` setting becomes unusable for the duration specified by the 'cool down time' setting in this component.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
category | JSON Object | The type of cool down for this item. All items with a cool down component with the same category are put on cool down when one is used. | |
duration | Float | The duration of time (in seconds) items with a matching category will spend cooling down before becoming usable again. |
The damage component determines how much extra damage the item does on attack.
Name | Type | Default Value | Description |
---|---|---|---|
value | How much extra damage the item does, must be a positive number. |
Digger item component. You can specify how quickly this item can dig specific blocks.
Name | Type | Default Value | Description |
---|---|---|---|
destroy_speeds | Array | A list of blocks to dig with correlating speeds of digging. | |
use_efficiency | Boolean | Whether this item should be impacted if the efficiency enchant is applied to it. |
Display Name item component. Determines the text shown whenever an item's name is displayed (ex. hover text).Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0)
Name | Type | Default Value | Description |
---|---|---|---|
value | String | The display name for an item. |
Durability item component. Determines how much damage this item takes before breaking and allows the item to be combined in crafting.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0)
Name | Type | Default Value | Description |
---|---|---|---|
damage_chance | JSON Object | Damage chance is the percentage chance of this item losing durability. Default is set to 100. Defined as an int range with min and max value. | |
max_durability | Integer | Max durability is the amount of damage that this item can take before breaking. This is a required parameter and has a minimum of 0. |
The enchantable component determines what enchantments can be applied to the item. Not all enchantments will have an effect on all item components.
Name | Type | Default Value | Description |
---|---|---|---|
slot | String | What enchantments can be applied (ex. Using `bow` would allow this item to be enchanted as if it were a bow). | |
value | The value of the enchantment (minimum of 0). |
Entity placer item component. You can specifiy allowed blocks that the item is restricted to.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0)
Name | Type | Default Value | Description |
---|---|---|---|
dispense_on | Array | List of block descriptors that contain blocks that this item can be dispensed on. If left empty, all blocks will be allowed. | |
entity | JSON Object | The entity to be placed in the world. | |
use_on | Array | List of block descriptors that contain blocks that this item can be used on. If left empty, all blocks will be allowed. |
When an item has a food component, it becomes edible to the player. Must have the 'minecraft:use_duration' component in order to function properly.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.30)
Name | Type | Default Value | Description |
---|---|---|---|
can_always_eat | Boolean | If true you can always eat this item (even when not hungry). Default is set to false. | |
nutrition | Integer | The value that is added to the actor's nutrition when the item is used. Default is set to 0. | |
saturation_modifier | Float | Saturation Modifier is used in this formula: (nutrition * saturation_modifier * 2) when applying the saturation buff. Default is set to 0.6. | |
using_converts_to | JSON Object | When used, converts to the item specified by the string in this field. Default does not convert item. |
Fuel item component. Allows this item to be used as fuel in a furnace to 'cook' other items.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0)
Name | Type | Default Value | Description |
---|---|---|---|
duration | Float | How long in seconds will this fuel cook items for. |
The glint component determines whether the item has the enchanted glint render effect on it.
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | Whether the item has the glint effect. |
This component determines if an item is rendered like a tool while in hand.
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | If the item is rendered like a tool while in hand. |
The hover text color component determines the color of the item name when hovering over it.
Name | Type | Default Value | Description |
---|---|---|---|
value | JSON Object | The color of the item's hover text. |
Icon item component. Determines the icon to represent the item in the UI and elsewhere.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.0)
Name | Type | Default Value | Description |
---|---|---|---|
textures | JSON Object | This map contains the different textures that can be used for the item's icon. Default will contain the actual icon texture. Armor trim textures and palettes can be specified here too. The icon textures are the keys from the resource_pack/textures/item_texture.json 'texture_data' object associated with the texture file. |
This component is a boolean or string that determines if the interact button is shown in touch controls and what text is displayed on the button. When set as true, default "Use Item" text will be used.
Item definition, which includes the "description" and "components" sections.
Name | Type | Default Value | Description |
---|---|---|---|
components | JSON Object | List of all components that used in this item. | |
description | JSON Object | List of characters of an item. The description MUST contain an identifier; the other fields are optional. |
The Storage Item Component is used for storing Items within an Item's User DataExperimental toggles required: Vanilla Experiments Internal (NON_LOC)
Name | Type | Default Value | Description |
---|---|---|---|
capacity | Integer | The max capacity of the item, default is 64 |
The liquid clipped component determines whether the item interacts with liquid blocks on use.
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | Whether the item interacts with liquid blocks on use. |
The max stack size component determines how many of the item can be stacked together.
Name | Type | Default Value | Description |
---|---|---|---|
value | How many of the item that can be stacked. |
Projectile item component. projectile items shoot out, like an arrow.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
minimum_critical_power | Float | How long you must charge a projectile for it to critically hit. | |
projectile_entity | JSON Object | The entity to be fired as a projectile. |
Record Item Component. Used by record items to play music. Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
comparator_signal | Integer | Signal strength for comparator blocks to use, from 1 - 13. | |
duration | Float | Duration of sound event in seconds, float value. | |
sound_event | 68, 69, 70, 289, 71, 72, 355, 73, 74, 75, 76, 77, 85, 287, 86, 82, 288, 83, 84, 78, 79, 80, 560, 310, 356, 81, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 362, 500, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 291, 122, 123, 124, 125, 126, 127, 128, 129, 279, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 297, 298, 299, 300, 301, 302, 303, 304, 305, 284, 282, 285, 283, 286, 157, 158, 160, 159, 161, 280, 281, 162, 163, 168, 164, 165, 166, 167, 385, 169, 170, 171, 172, 173, 174, 175, 176, 177, 178, 179, 180, 382, 537, 439, 507, 182, 183, 186, 187, 188, 184, 185, 189, 190, 191, 192, 498, 499, 193, 194, 195, 196, 197, 198, 199, 200, 201, 202, 203, 205, 204, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 220, 221, 222, 223, 224, 225, 226, 227, 228, 229, 230, 231, 232, 233, 234, 235, 236, 237, 238, 239, 240, 241, 242, 243, 244, 258, 278, 246, 253, 247, 248, 249, 250, 251, 252, 255, 256, 257, 259, 260, 261, 262, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 292, 293, 294, 296, 534, 535, 501, 503, 306, 308, 309, 311, 320, 321, 322, 312, 307, 313, 314, 315, 316, 317, 318, 319, 323, 245, 324, 325, 326, 327, 330, 331, 333, 332, 334, 335, 336, 337, 328, 329, 338, 339, 340, 344, 343, 345, 346, 347, 348, 341, 342, 349, 350, 351, 352, 353, 354, 358, 359, 361, 360, 357, 363, 370, 364, 365, 367, 368, 369, 366, 380, 381, 376, 377, 378, 379, 375, 371, 372, 373, 395, 391, 392, 393, 394, 390, 386, 387, 388, 389, 383, 374, 396, 397, 384, 254, 295, 502, 398, 399, 400, 401, 405, 406, 402, 404, 403, 407, 408, 409, 413, 414, 415, 410, 411, 412, 416, 417, 418, 419, 420, 421, 422, 423, 424, 425, 426, 427, 428, 429, 430, 431, 432, 433, 434, 435, 436, 437, 438, 443, 444, 440, 496, 497, 506, 441, 442, 445, 451, 452, 453, 454, 455, 456, 457, 458, 494, 495, 504, 505, 508, 447, 448, 449, 450, 510, 513, 514, 515, 511, 512, 516, 517, 518, 519, 520, 521, 522, 523, 524, 525, 526, 527, 528, 529, 532, 533, 530, 531, 536, 538, 539, 540, 541, 542, 543, 544, 545, 546, 549, 550, 547, 548, 551, 558, 559, 561, 562, 552, 554, 556, 555, 553, 557, 563, 564, 565, 566, 567, 568 | Sound event type: 13, cat, blocks, chirp, far, mall, mellohi, stal, strad, ward, 11, wait, pigstep, otherside, 5, relic. |
Repairable item component. Determines the items that can be used to repair this item along with how much durability they repair.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
repair_items | Array | List of repair item entries. Each entry needs to define a list of strings for `items` that can be used for the repair and an optional `repair_amount` for how much durability is repaired. |
Shooter Item Component. Must have the 'minecraft:use_duration' component in order to function properly.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
ammunition | Array | Ammunition. | |
charge_on_draw | Boolean | Charge on draw? Default is set to false. | |
max_draw_duration | JSON Object | Draw Duration. Default is set to 0. | |
scale_power_by_draw_duration | Boolean | Scale power by draw duration? Default is set to false. |
Should despawn component determines if the item should eventually despawn while floating in the world
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | Whether the item should eventually despawn while floating in the world |
The stacked by data component determines if the same item with different aux values can stack. Also defines whether the item actors can merge while floating in the world.
Name | Type | Default Value | Description |
---|---|---|---|
value | Boolean | Whether the same item with different aux values can stack. Also defines whether the item actors can merge while floating in the world. |
The tags component determines which tags an item has on it.
Name | Type | Default Value | Description |
---|---|---|---|
tags | Array | An array that can contain multiple item tags. |
Throwable item component. Throwable items, such as a snowball.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.10)
Name | Type | Default Value | Description |
---|---|---|---|
do_swing_animation | Boolean | Whether the item should use the swing animation when thrown. Default is set to false. | |
launch_power_scale | Float | The scale at which the power of the throw increases. Default is set to 1.0. | |
max_draw_duration | Float | The maximum duration to draw a throwable item. Default is set to 0.0. | |
max_launch_power | Float | The maximum power to launch the throwable item. Default is set to 1.0. | |
min_draw_duration | Float | The minimum duration to draw a throwable item. Default is set to 0.0. | |
scale_power_by_draw_duration | Boolean | Whether or not the power of the throw increases with duration charged. Default is set to false. |
This component determines which animation plays when using the item.
Name | Type | Default Value | Description |
---|---|---|---|
value | Which animation to play when using the item. |
This component modifies use effects, including how long the item takes to use and the player's speed when used in combination with components like Shooter, Throwable or Food.
Name | Type | Default Value | Description |
---|---|---|---|
movement_modifier | Float | Modifier value to scale the players movement speed when item is in use. | |
use_duration | Float | How long the item takes to use in seconds. |
Wearable item component.Experimental toggles required: Holiday Creator Features (in format versions before 1.20.20)
Name | Type | Default Value | Description |
---|---|---|---|
protection | Integer | How much protection the wearable item has. Default is set to 0. | |
slot | 69, 70, 71, 72, 73 | Determines where the item can be worn. If any non-hand slot is chosen, the max stack size is set to 1. |