Minecraft:Model: Difference between revisions
More actions
Sync: updated from Minecraft |
Sync: updated from Minecraft |
||
| (6 intermediate revisions by the same user not shown) | |||
| Line 72: | Line 72: | ||
***** {{nbt|float|angle}}: Specifies the angle of rotation. Can be 45 through -45 degrees. | ***** {{nbt|float|angle}}: Specifies the angle of rotation. Can be 45 through -45 degrees. | ||
***** {{nbt|bool|rescale}}: Specifies whether or not to scale the faces across the whole block. Can be true or false. Defaults to false. | ***** {{nbt|bool|rescale}}: Specifies whether or not to scale the faces across the whole block. Can be true or false. Defaults to false. | ||
**** {{nbt|bool|shade}}: Defines if the faces of the element should be shaded according to their orientation (<code>true</code> - default) or not (<code>false</code>). This does not affect ambient occlusion or shading based on light level. | **** {{nbt|bool|shade}}{{until|je 26.3}}: Defines if the faces of the element should be shaded according to their orientation (<code>true</code> - default) or not (<code>false</code>). This does not affect ambient occlusion or shading based on light level. | ||
**** {{nbt|bool|shade_direction_override}}{{upcoming|je 26.3}}: Optional. Defines the direction of the light source to cast a shading effect on the faces. The accepted values are {{cd|d=and|down|up|north|south|west|east}}. If not specified, no shading will be applied. This does not affect ambient occlusion or shading based on light level. | |||
**** {{nbt|int|light_emission}}: Defines the minimum light level that the element can receive. Can be 0-15, defaults to 0. | **** {{nbt|int|light_emission}}: Defines the minimum light level that the element can receive. Can be 0-15, defaults to 0. | ||
**** {{nbt|compound|faces}}: Holds all the faces of the cuboid. If a face is left out, it does not render. | **** {{nbt|compound|faces}}: Holds all the faces of the cuboid. If a face is left out, it does not render. | ||
| Line 81: | Line 82: | ||
****** {{nbt|int|rotation}}: Rotates the texture by the specified number of degrees. Can be 0, 90, 180, or 270. Defaults to 0. Rotation does not affect which part of the texture is used. Instead, it amounts to permutation of the selected texture vertexes (selected implicitly, or explicitly though <code>uv</code>). | ****** {{nbt|int|rotation}}: Rotates the texture by the specified number of degrees. Can be 0, 90, 180, or 270. Defaults to 0. Rotation does not affect which part of the texture is used. Instead, it amounts to permutation of the selected texture vertexes (selected implicitly, or explicitly though <code>uv</code>). | ||
****** {{nbt|int|tintindex}}: Tints the texture on that face using a tint value referenced from the [[Minecraft:Items model definition#model|Items model definition]]. If no tint color (or the color white) is provided, the texture isn't tinted. | ****** {{nbt|int|tintindex}}: Tints the texture on that face using a tint value referenced from the [[Minecraft:Items model definition#model|Items model definition]]. If no tint color (or the color white) is provided, the texture isn't tinted. | ||
** {{nbt|list|overrides}}: As of [[Minecraft:24w45a| 24w45a]]/[[Minecraft:1.21.4| 1.21.4]]+, overrides have been removed | ** {{nbt|list|overrides}}<span style="color:red;">*</span>: As of [[Minecraft:24w45a| 24w45a]]/[[Minecraft:1.21.4| 1.21.4]]+, overrides have been removed and replaced with [[Minecraft:Items_model_definition| Item model definitions]]. Before this change, this field was a list of cases that could change the model when its predicates passed. If the predicates of more than one case passed, only the last case took effect. | ||
*** {{nbt|compound|}} A case. | |||
**** {{nbt|compound|predicate}}: Holds one or more predicates that have to be met, see [[Minecraft:Tutorial:Models#Item predicates|item predicates]]. | |||
**** {{nbt|string|model}}: The [[Minecraft:Identifier|resource location]] of the model used if the predicates are met. | |||
</div> | </div> | ||
| Line 94: | Line 98: | ||
* mooshroom mushrooms | * mooshroom mushrooms | ||
* iron golem flowers | * iron golem flowers | ||
* copper golems | * copper golems | ||
* | * sulfur cubes | ||
* | * vault items | ||
* | * items held by villagers and wandering traders (honestly i should split these tables and the other tables on the Item page off to some new page)}} | ||
Non-hardcoded models are used in-game in the following contexts: | Non-hardcoded models are used in-game in the following contexts: | ||
{|class="wikitable" | {| class="wikitable" | ||
!Use case | ! Use case | ||
!Uses | ! Uses | ||
!Image | ! Image | ||
!Respects {{code|shade{{=}}false}}? | ! Respects {{code|shade{{=}}false}}? | ||
|- | |- | ||
!colspan="4"|Blocks | ! colspan="4"| Blocks | ||
|- | |- | ||
!Placed blocks | ! Placed blocks | ||
|All blocks excluding those listed [[#Blocks and fluids|here]] | | All blocks excluding those listed [[#Blocks and fluids|here]] | ||
| | | | ||
|{{tc|Yes}} | | {{tc|Yes}} | ||
|- | |- | ||
![[Minecraft:Falling block]]s | ! [[Minecraft:Falling block]]s | ||
|All blocks excluding those listed [[#Blocks and fluids|here]] | | All blocks excluding those listed [[#Blocks and fluids|here]] | ||
| | | | ||
|{{tc|Yes}} | | {{tc|Yes}} | ||
|- | |- | ||
![[Minecraft:Moving Piston|Piston-moved blocks]] | ! [[Minecraft:Moving Piston|Piston-moved blocks]] | ||
|All blocks excluding those listed [[#Blocks and fluids|here]] | | All blocks excluding those listed [[#Blocks and fluids|here]] | ||
| | | | ||
|{{tc|Yes}} | | {{tc|Yes}} | ||
|- | |- | ||
!Lit [[Minecraft:TNT]] | ! Lit [[Minecraft:TNT]] | ||
|TNT | | TNT{{verify|can't you change what is displayed now?}} | ||
| | | | ||
|{{tc|No}} | | {{tc|No}} | ||
|- | |- | ||
!colspan="4"|Items | ! [[Minecraft:Snow Golem]] headpiece<ref>{{bug|MC-308352}}</ref> | ||
| Carved Pumpkin | |||
| | |||
| {{verify}} | |||
|- | |||
! colspan="4"| Items | |||
|- | |||
! Items in the inventory | |||
| All items excluding air | |||
| | |||
| {{tc|No}} | |||
|- | |- | ||
!Items in the | ! Items in the player's hand (first person) | ||
|All items excluding air | | All items excluding air{{verify|Is it true for tridents?}} | ||
| | | | ||
|{{tc|No}} | | {{tc|No}} | ||
|- | |- | ||
!Items in the player's hand ( | ! Items in the player's hand (third person)<br>Items held by other players<br>Items held by mobs | ||
|All items excluding air{{verify|Is it true for tridents?}} | | All items excluding air{{verify|Is it true for tridents?}} | ||
| | | | ||
|{{tc|No}} | | {{tc|No}} | ||
|- | |- | ||
!Items | ! Items on the ground | ||
|All items excluding air | | All items excluding air | ||
| | | | ||
|{{tc|No}} | | {{tc|No}} | ||
|- | |- | ||
!Items | ! Items in item frames | ||
|All items excluding air | | All items excluding air | ||
| | | | ||
|{{tc|No}} | | {{tc|No}} | ||
|- | |- | ||
!Items | ! Items on shelves | ||
|All items excluding air | | All items excluding air | ||
| | | | ||
|{{ | | {{verify}} | ||
|- | |- | ||
![[Minecraft:Totem of undying]] animation | ! [[Minecraft:Totem of undying]] animation | ||
|Any item with the "death protection" component | | Any item with the "death protection" component | ||
| | | | ||
|{{tc|No}}{{verify}} | | {{tc|No}}{{verify}} | ||
|} | |} | ||
Each of the item display types are used in the following situations: | Each of the item display types are used in the following situations: | ||
{|class="wikitable" | {| class="wikitable" | ||
!Use case | ! Use case | ||
!Display type | ! Display type | ||
|- | |- | ||
|Inventory items | | Inventory items<br>Crafting station icon on recipe unlock toasts | ||
|{{code|gui}} | | {{code|gui}} | ||
|- | |- | ||
|Items equipped on the heads of certain mobs{{info needed|players and other humanoids, but what mobs exactly?}} | | Items equipped on the heads of certain mobs{{info needed|players and other humanoids, but what mobs exactly?}}<br>Spyglasses when in use | ||
|{{code|head}} | | {{code|head}} | ||
|- | |- | ||
|[[Minecraft:Item (entity)|Dropped items]]<br>Items held by [[Minecraft:dolphin]]s<ref>{{bug|MC-276803||Items held by dolphins use the "ground" display type|Invalid}}</ref><br>Items held by [[Minecraft:panda]]s<ref>{{bug|MC-276802||Items held by pandas unexpectedly use the "ground" display type|Invalid}}</ref><br>Items held by [[Minecraft:fox]]es<ref>{{bug|MC-276763||Item models held by foxes cannot be customized independently of dropped item models|Invalid}}</ref><br>Thrown projectiles<ref>{{bug|MC-276801||Projectiles which use item models use the "ground" display type and cannot be independently customized from it|Invalid}}</ref>{{info needed|snowballs, eggs, ender pearls, eye of enders and fire charges confirmed. are splash potions, lingering potions, experience bottles, firework rockets and ghast fireballs also subject to this, and are there any others?}}<br>Items held by villagers and wandering traders<br>Potions held by witches<br>Ominous item spawner | | [[Minecraft:Item (entity)|Dropped items]]<br>Items held by [[Minecraft:dolphin]]s<ref>{{bug|MC-276803||Items held by dolphins use the "ground" display type|Invalid}}</ref><br>Items held by [[Minecraft:panda]]s<ref>{{bug|MC-276802||Items held by pandas unexpectedly use the "ground" display type|Invalid}}</ref><br>Items held by [[Minecraft:fox]]es<ref>{{bug|MC-276763||Item models held by foxes cannot be customized independently of dropped item models|Invalid}}</ref><br>Thrown projectiles<ref>{{bug|MC-276801||Projectiles which use item models use the "ground" display type and cannot be independently customized from it|Invalid}}</ref>{{info needed|snowballs, eggs, ender pearls, eye of enders and fire charges confirmed. are splash potions, lingering potions, experience bottles, firework rockets and ghast fireballs also subject to this, and are there any others?}}<br>Items held by villagers and wandering traders<br>Potions held by witches<br>Ominous item spawner | ||
|{{code|ground}} | | {{code|ground}} | ||
|- | |- | ||
|Items in item frames<br>Totem of undying animation<br>Items being brushed out of suspicious sand and gravel | | Items in item frames<br>Totem of undying animation<br>Items placed on campfires<br>Items being brushed out of suspicious sand and gravel | ||
|{{code|fixed}} | | {{code|fixed}} | ||
|- | |- | ||
|Items | | Items on shelves | ||
|{{code| | | {{code|on_shelf}} | ||
|- | |- | ||
| | | Items held in a humanoid's left hand | ||
|{{code| | | {{code|thirdperson_lefthand}} | ||
|- | |- | ||
|Items held in | | Items held in a humanoid's right hand<br>Items held in a humanoid's left hand, if {{code|thirdperson_lefthand}} is left unspecified | ||
|{{code| | | {{code|thirdperson_righthand}} | ||
|- | |- | ||
| | | Items held in the left hand in first person | ||
|{{code| | | {{code|firstperson_lefthand}} | ||
|- | |- | ||
|Item display entities | | Items held in the right hand in first person<br>Items held in the left hand in first person, if {{code|firstperson_lefthand}} is left unspecified | ||
|Depends on what is specified | | {{code|firstperson_righthand}} | ||
|- | |||
| Item display entities | |||
| Depends on what is specified | |||
|} | |} | ||
== Limitations == | == Limitations == | ||
{{Hatnote| For block limitations see [[Minecraft:non-model-dependent block elements]]}} | |||
=== Objects that cannot be remodelled === | === Objects that cannot be remodelled === | ||
{{info needed section|Objects needing testing: | {{info needed section|Objects needing testing: | ||
| Line 229: | Line 244: | ||
|[[Minecraft:Ryan Holtz|TheMogMiner]] posts about upcoming changes to the model format.}} | |[[Minecraft:Ryan Holtz|TheMogMiner]] posts about upcoming changes to the model format.}} | ||
|{{HistoryLine|||dev=14w17a|Converted most of the remaining static blocks to the model format. | |{{HistoryLine|||dev=14w17a|Converted most of the remaining static blocks to the model format. | ||
|Added | |Added {{cd|"rotateVariantTextures"}} to preserve uv details through rotation.}} | ||
|{{HistoryLine|||dev=14w25a|The directional attribute from the uv definition has now been removed and replaced it with explicit texture references. | |{{HistoryLine|||dev=14w25a|The directional attribute from the uv definition has now been removed and replaced it with explicit texture references. {{cd|"textureFacing"}} has been replaced with {{cd|"texture"}} parameter, which is now prepended with the hash symbol (#). | ||
|"useAmbientOcclusion" has now been renamed to "ambientocclusion". | |"useAmbientOcclusion" has now been renamed to "ambientocclusion". | ||
|"rotateVariantTextures" has now been renamed to "UV lock". | |"rotateVariantTextures" has now been renamed to "UV lock". | ||
|"cull" has now been renamed to "cullface", specifies the opposite of which neighboring face causes culling to occur. | |"cull" has now been renamed to "cullface", specifies the opposite of which neighboring face causes culling to occur. | ||
|Rotation has now been made more verbose, it is now more clear that it can occur only on a single axis. Example, the rotation for one of the two faces of the | |Rotation has now been made more verbose, it is now more clear that it can occur only on a single axis. Example, the rotation for one of the two faces of the {{cd|"cross"}} model is now: {{cd|"rotation": { "origin": [ 8, 8, 8 ], "axis": "y", "angle": 45, "rescale": true },}}. | ||
|The folder | |The folder {{cd|models/blocks/meshes}} has now been removed and model files are now stored in {{cd|models/block}}. | ||
|The folder blockstates has now been added and stores the model selection files previously found in | |The folder blockstates has now been added and stores the model selection files previously found in {{cd|models/block}}. | ||
|The model format now supports custom [[Minecraft:item]] models.}} | |The model format now supports custom [[Minecraft:item]] models.}} | ||
|{{HistoryLine|||dev=14w27a|[[Minecraft:Block]] state names have now been replaced with data that better reflects the internal data. This does not yet reflect all data for some blocks and switches to using the actual stored data in a future version when numerical data values are completely dropped in favor of block states.}} | |{{HistoryLine|||dev=14w27a|[[Minecraft:Block]] state names have now been replaced with data that better reflects the internal data. This does not yet reflect all data for some blocks and switches to using the actual stored data in a future version when numerical data values are completely dropped in favor of block states.}} | ||
|{{HistoryLine|||dev=14w27b|The block state files now support an array of models allowing for random models.}} | |{{HistoryLine|||dev=14w27b|The block state files now support an array of models allowing for random models.}} | ||
|{{HistoryLine|||dev=14w30a|Added the item model | |{{HistoryLine|||dev=14w30a|Added the item model {{cd|"builtin/entity"}}.}} | ||
|{{HistoryLine||1.8.2|dev=pre5|slink=1.8.2-pre5|The tag "translation" is now limited to the range of -24 to 24. | |{{HistoryLine||1.8.2|dev=pre5|slink=1.8.2-pre5|The tag "translation" is now limited to the range of -24 to 24. | ||
|The tag "scale" is now limited to 4 or less.}} | |The tag "scale" is now limited to 4 or less.}} | ||
| Line 248: | Line 263: | ||
|Models can now be put together based on block state attributes, such as [[Minecraft:fence]]s. As a result, the vanilla set of [[Minecraft:block]] models was reduced by almost 300 models. | |Models can now be put together based on block state attributes, such as [[Minecraft:fence]]s. As a result, the vanilla set of [[Minecraft:block]] models was reduced by almost 300 models. | ||
|Block model JSON is now strict, comments and quoteless identifiers are now not allowed. | |Block model JSON is now strict, comments and quoteless identifiers are now not allowed. | ||
|"display" tag defaults have now been changed, and the | |"display" tag defaults have now been changed, and the {{cd|d=and|"thirdperson"|"firstperson"}} tags have now been replaced with {{cd|d=and|"thirdperson_righthand"|"thirdperson_lefthand"|"firstperson_righthand"|"firstperson_lefthand"}}. | ||
|"parent" and "elements" tags can now coexist, though the top level elements tag overwrites all former ones. | |"parent" and "elements" tags can now coexist, though the top level elements tag overwrites all former ones. | ||
|The option to disable alternate [[Minecraft:block]] models has now been removed. | |The option to disable alternate [[Minecraft:block]] models has now been removed. | ||
| Line 255: | Line 270: | ||
|Known bug in this version caused many/all items to be shifted down/positioned wrongly compared to prior versions. [https://bugs.mojang.com/browse/MC-82928 MC-82928]}} | |Known bug in this version caused many/all items to be shifted down/positioned wrongly compared to prior versions. [https://bugs.mojang.com/browse/MC-82928 MC-82928]}} | ||
|{{HistoryLine|||dev=15w31c|Item positions have been fixed to match how they were prior to 15w31a. Although the fishing rod is still different and still is to this day.}} | |{{HistoryLine|||dev=15w31c|Item positions have been fixed to match how they were prior to 15w31a. Although the fishing rod is still different and still is to this day.}} | ||
|{{HistoryLine||1.14|dev=18w43a|Added the item model property | |{{HistoryLine||1.14|dev=18w43a|Added the item model property {{cd|"custom_model_data"}}.}} | ||
|{{HistoryLine||1.15.2|dev=Pre-Release 1|The gui_light parameter for item models has been added.}} | |{{HistoryLine||1.15.2|dev=Pre-Release 1|The gui_light parameter for item models has been added.}} | ||
|{{HistoryLine||?|Blocks that render as entities, such as chests, will now display block model data alongside their block entity (much like how enchanting tables and lecterns did previously), rather than refusing to render any model data and only using it for particle definitions.}} | |{{HistoryLine||?|Blocks that render as entities, such as chests, will now display block model data alongside their block entity (much like how enchanting tables and lecterns did previously), rather than refusing to render any model data and only using it for particle definitions.}} | ||
|{{HistoryLine||1.21.2|dev=24w33a|The "light_emission" field for models has been added.}} | |{{HistoryLine||1.21.2|dev=24w33a|The "light_emission" field for models has been added.}} | ||
|{{HistoryLine|||dev=24w36a|All item models can now use the | |{{HistoryLine|||dev=24w36a|All item models can now use the {{cd|broken}} property in model overrides that was previously limited to just [[Minecraft:elytra]]. | ||
|The model of an item is selected based on the {{cd|minecraft:item_model}} component, following the format | |The model of an item is selected based on the {{cd|minecraft:item_model}} component, following the format {{cd|/assets/<namespace>/models/item/<id>}}.}} | ||
|{{HistoryLine||1.21.4|dev=24w45a|New format has been introduced for describing item models. See [[Minecraft:Items model definition]]. | |{{HistoryLine||1.21.4|dev=24w45a|New format has been introduced for describing item models. See [[Minecraft:Items model definition]]. | ||
|The {{cd|minecraft:item_model}} component now reference an Items model definition. | |The {{cd|minecraft:item_model}} component now reference an Items model definition. | ||
| Line 267: | Line 282: | ||
|Models in {{cd|models/item}} that only redirect to a block model have been removed.}} | |Models in {{cd|models/item}} that only redirect to a block model have been removed.}} | ||
|{{HistoryLine||1.21.6|dev=25w16a|Block model rotations are no longer limited to multiples of {{cd|22.5}}.}} | |{{HistoryLine||1.21.6|dev=25w16a|Block model rotations are no longer limited to multiples of {{cd|22.5}}.}} | ||
|{{HistoryLine||1.21.9|dev=25w33a|New item display transform | |{{HistoryLine||1.21.9|dev=25w33a|New item display transform {{cd|on_shelf}}. It is ignored by [[Minecraft:shelf]] with the {{cd|align_items_to_bottom}} block state.}} | ||
|{{HistoryLine||1.21.11|dev=25w46a|Block model elements can now be rotated around multiple axes.|Existing restriction for angle value limiting them to {{cd|[-45, 45]}} has been removed.}} | |{{HistoryLine||1.21.11|dev=25w46a|Block model elements can now be rotated around multiple axes.|Existing restriction for angle value limiting them to {{cd|[-45, 45]}} has been removed.}} | ||
|{{HistoryLine||26.1|dev=snap7|Any block model can now support cutout or translucent (partially transparent pixels) textures.|The format of the | |{{HistoryLine||26.1|dev=snap7|Any block model can now support cutout or translucent (partially transparent pixels) textures.|The format of the {{cd|textures}} map has been updated.}} | ||
|{{HistoryLine|upcoming java}} | |||
|{{HistoryLine||26.3|dev=snap3|Added the optional {{cd|shade_direction_override}} property to block model elements.|Removed the {{cd|shade}} property from block model elements.}} | |||
}} | }} | ||
Latest revision as of 11:08, 23 July 2026
|
For the {{{Description}}} of the same name, see [[{{{Destination}}}]]. |
Template:See also Template:Exclusive Template:Split
Models are three-dimensional shapes used in Minecraft that are used to display objects encountered in the game.
The models pertaining to the vast majority of Minecraft:blocks and Minecraft:items can be configured, as well as those of a small selection of Minecraft:entities. Models are stored as Minecraft:JSON files in a Minecraft:resource pack in the assets/<namespace>/models folder.
Block models
- Template:Nbt The root tag
- Template:Nbt: Loads a different model from the given path, in form of a resource location. If both
"parent"and"elements"are set, the"elements"tag overrides the"elements"tag from the previous model.- Can be set to
"builtin/generated"to use a model that is created out of the specified icon. Only the first layer is supported, and rotation can be achieved only by using block states files.
- Can be set to
- Template:Nbt: Whether to use Template:Wikipedia (
true- default), or not (false). - Template:Nbt: Holds the different places where item models are displayed.
- Template:Nbt: Named
thirdperson_righthand,thirdperson_lefthand,firstperson_righthand,firstperson_lefthand,gui,head,ground,fixed, oron_shelf. Place where an item model is displayed. Holds its rotation, translation and scale for the specified situation. fixed refers to item frames, while the rest are as their name states. Translations are applied to the model before rotations.- Template:Nbt: Specifies the rotation of the model according to the scheme
[x, y, z]. - Template:Nbt: Specifies the position of the model according to the scheme
[x, y, z]. The values are clamped between -80 and 80. - Template:Nbt: Specifies the scale of the model according to the scheme
[x, y, z]. If the value is greater than 4, it is displayed as 4.
- Template:Nbt: Specifies the rotation of the model according to the scheme
- Template:Nbt: Named
- Template:Nbt: Holds the textures of the model, in form of a resource location or can be another texture variable.
- Template:Nbt: Defines a texture variable and assigns a texture. The texture can either be a reference to another texture variable, or the resource location of a texture in the
texturesfolder. The variable can be referenced by prefixing it with a#in the model, e.g. the variable"texture"is referenced as"#texture". The texture variable named"particle"defines what texture the breaking particles are loaded from, but can also be referenced by the model as"#particle". The particle texture is also used as an overlay if you are in a Minecraft:nether portal, for Minecraft:water and Minecraft:lava's still textures,<ref>Template:Bug</ref> and for the particle textures of non-model blocks (such as for Minecraft:barriers). - Template:Nbt: Defines a texture variable and assigns it a texture. This is an alternative format that allows specifying some extra properties of the texture. This format works for all texture variables, including
"particle".- Template:Nbt: The resource location of a texture. Note that texture variables cannot be used here.
- Template:Nbt: Optional. Defines whether the texture should be considered translucent even when it is not. Normally, Minecraft determines whether a block is translucent by checking if any of its textures has any translucent pixels. Setting this to
trueoverrides that behavior for this texture. This is useful for textures that don't have any translucent pixels, but use themeanmipmap strategy. Defaults tofalse.
- Template:Nbt: Defines a texture variable and assigns a texture. The texture can either be a reference to another texture variable, or the resource location of a texture in the
- Template:Nbt: Contains all the elements of the model. They can have only cubic forms. If both
"parent"and"elements"are set, the"elements"tag overrides the"elements"tag from the previous model.- Template:Nbt An element.
- Template:Nbt: Start point of a cuboid according to the scheme
[x, y, z]. Values must be between -16 and 32. - Template:Nbt: Stop point of a cuboid according to the scheme
[x, y, z]. Values must be between -16 and 32. - Template:Nbt: Defines the rotation of an element.
- Template:Nbt: Sets the center of the rotation according to the scheme
[x, y, z]. - Template:Nbt: Specifies the angle of rotation around the
xaxis. This value will be ignored if anaxisandangleare specified. - Template:Nbt: Specifies the angle of rotation around the
yaxis. This value will be ignored if anaxisandangleare specified. - Template:Nbt: Specifies the angle of rotation around the
zaxis. This value will be ignored if anaxisandangleare specified. - Template:Nbt: Specifies the direction of rotation, can be
"x","y"or"z". - Template:Nbt: Specifies the angle of rotation.
- Template:Nbt: Specifies whether or not to scale the faces across the whole block by scaling the non-rotated faces by
1 / cos(angle). Can be true or false. Defaults to false.
- Template:Nbt: Sets the center of the rotation according to the scheme
- Template:Nbt: Defines if the faces of the element should be shaded according to their orientation (
true- default) or not (false). This does not affect ambient occlusion or shading based on light level. - Template:Nbt: Defines the minimum light level that the element can receive. Can be 0-15, defaults to 0.
- Template:Nbt: Holds all the faces of the cuboid. If a face is left out, it does not render.
- Template:Nbt: Named
down,up,north,south,westoreast. Contains the properties of the specified face.- Template:Nbt: Defines the area of the texture to use according to the scheme
[x1, y1, x2, y2]. The texture behavior is inconsistent if UV extends below 0 or above 16. If the numbers ofx1andx2are swapped (e.g. from0, 0, 16, 16to16, 0, 0, 16), the texture flips. UV is optional, and if not supplied it automatically generates based on the element's position. - Template:Nbt: Specifies the texture in form of the texture variable prepended with a
#. - Template:Nbt: Specifies whether a face does not need to be rendered when there is a block touching it in the specified position. The position can be:
down,up,north,south,west, oreast. It also determines the side of the block to use the light level from for lighting the face, and if unset, defaults to the side. - Template:Nbt: Rotates the texture clockwise by the specified number of degrees (counterclockwise for the 'down' face). Can be 0, 90, 180, or 270. Defaults to 0. Rotation does not affect which part of the texture is used. Instead, it amounts to permutation of the selected texture vertexes (selected implicitly, or explicitly though
uv). - Template:Nbt: Determines whether to tint the texture using a hardcoded tint index. The default value, -1, indicates not to use the tint. Any other number is provided to BlockColors to get the tint value corresponding to that index. However, most blocks do not have a tint value defined (in which case white is used). Furthermore, no vanilla block currently uses multiple tint values, and thus the tint index value is ignored (as long as it is set to something other than -1); it could be used for modded blocks that need multiple distinct tint values in the same block though.
- Template:Nbt: Defines the area of the texture to use according to the scheme
- Template:Nbt: Named
- Template:Nbt: Start point of a cuboid according to the scheme
- Template:Nbt An element.
- Template:Nbt: Loads a different model from the given path, in form of a resource location. If both
Item models
- Template:Nbt: The root tag
- Template:Nbt: Loads a different model from the given path, in form of a resource location. If both
"parent"and"elements"are set, the"elements"tag overrides the"elements"tag from the previous model.- Can be set to
"item/generated"to use a model that is created out of the specified icon. - Can be set to
"builtin/entity"to load a model from an entity file. As you cannot specify the entity, this does not work for all items (only for Minecraft:chests, Minecraft:ender chests, Minecraft:mob heads, Minecraft:shields, Minecraft:banners and Minecraft:tridents).
- Can be set to
- Template:Nbt: Holds the different places where item models are displayed.
- Template:Nbt: Named
thirdperson_righthand,thirdperson_lefthand,firstperson_righthand,firstperson_lefthand,gui,head,ground,fixed, oron_shelf. Place where an item model is displayed. Holds its rotation, translation and scale for the specified situation. fixed refers to item frames, while the rest are as their name states. Translations are applied to the model before rotations. If this is specified but not all of translation, rotation and scale are in it, the others aren't inherited from the parent.- Template:Nbt: Specifies the rotation of the model according to the scheme
[x, y, z]. - Template:Nbt: Specifies the position of the model according to the scheme
[x, y, z]. If the value is greater than 80, it is displayed as 80. If the value is less than -80, it is displayed as -80. - Template:Nbt: Specifies the scale of the model according to the scheme
[x, y, z]. If the value is greater than 4, it is displayed as 4.
- Template:Nbt: Specifies the rotation of the model according to the scheme
- Template:Nbt: Named
- Template:Nbt: Holds the textures of the model, in form of a resource location or can be another texture variable.
- Template:Nbt: Used only to specify the icon of the item used in the inventory. There can be more than just one layer (e.g. for Minecraft:leather armor and trimmed armor), but the amount of possible layers is hardcoded for each item.Template:Verify Works only in combination with
"item/generated". - Template:Nbt: What texture to load particles from. Used to determine the "crumb" particles generated by food items, as well as to determine the Minecraft:barrier particle (but it always uses
items/barrier.pngas blockbreaking particle), which otherwise uses "layer0". - Template:Nbt: Defines a texture variable and assigns a texture.
- Template:Nbt: Used only to specify the icon of the item used in the inventory. There can be more than just one layer (e.g. for Minecraft:leather armor and trimmed armor), but the amount of possible layers is hardcoded for each item.Template:Verify Works only in combination with
- Template:Nbt: Can be
"front"or"side". If set to"side", the model is rendered like a block. If set to"front", model is shaded like a flat item. Defaults to"side". - Template:Nbt: Contains all the elements of the model. They can have only cubic forms. If both
"parent"and"elements"are set, the"elements"list overrides the"elements"list from the parent model.- Template:Nbt An element.
- Template:Nbt: Start point of a cuboid according to the scheme
[x, y, z]. Values must be between -16 and 32. - Template:Nbt: Stop point of a cuboid according to the scheme
[x, y, z]. Values must be between -16 and 32. - Template:Nbt: Defines the rotation of an element.
- Template:Nbt: Sets the center of the rotation according to the scheme
[x, y, z]. - Template:Nbt: Specifies the direction of rotation, can be
"x","y"or"z". - Template:Nbt: Specifies the angle of rotation. Can be 45 through -45 degrees.
- Template:Nbt: Specifies whether or not to scale the faces across the whole block. Can be true or false. Defaults to false.
- Template:Nbt: Sets the center of the rotation according to the scheme
- Template:NbtTemplate:Until: Defines if the faces of the element should be shaded according to their orientation (
true- default) or not (false). This does not affect ambient occlusion or shading based on light level. - Template:NbtTemplate:Upcoming: Optional. Defines the direction of the light source to cast a shading effect on the faces. The accepted values are Template:Cd. If not specified, no shading will be applied. This does not affect ambient occlusion or shading based on light level.
- Template:Nbt: Defines the minimum light level that the element can receive. Can be 0-15, defaults to 0.
- Template:Nbt: Holds all the faces of the cuboid. If a face is left out, it does not render.
- Template:Nbt: Named
down,up,north,south,westoreast. Contains the properties of the specified face.- Template:Nbt Defines the area of the texture to use according to the scheme
[x1, y1, x2, y2]. If unset, it defaults to values equal to xyz position of the element. The texture behavior is inconsistent if UV extends below 0 or above 16. If the numbers ofx1andx2are swapped (e.g. from0, 0, 16, 16to16, 0, 0, 16), the texture flips. UV is optional, and if not supplied it automatically generates based on the element's position. - Template:Nbt Specifies the texture in form of the texture variable prepended with a
#. - Template:Nbt Specifies whether a face does not need to be rendered when there is a block touching it in the specified position. The position can be:
down,up,north,south,west, oreast. It also determines the side of the block to use the light level from for lighting the face, and if unset, defaults to the side. - Template:Nbt: Rotates the texture by the specified number of degrees. Can be 0, 90, 180, or 270. Defaults to 0. Rotation does not affect which part of the texture is used. Instead, it amounts to permutation of the selected texture vertexes (selected implicitly, or explicitly though
uv). - Template:Nbt: Tints the texture on that face using a tint value referenced from the Items model definition. If no tint color (or the color white) is provided, the texture isn't tinted.
- Template:Nbt Defines the area of the texture to use according to the scheme
- Template:Nbt: Named
- Template:Nbt: Start point of a cuboid according to the scheme
- Template:Nbt An element.
- Template:Nbt*: As of 24w45a/ 1.21.4+, overrides have been removed and replaced with Item model definitions. Before this change, this field was a list of cases that could change the model when its predicates passed. If the predicates of more than one case passed, only the last case took effect.
- Template:Nbt A case.
- Template:Nbt: Holds one or more predicates that have to be met, see item predicates.
- Template:Nbt: The resource location of the model used if the predicates are met.
- Template:Nbt A case.
- Template:Nbt: Loads a different model from the given path, in form of a resource location. If both
Fields used by Blockbench
Some models contain fields used by Blockbench due to Mojang utilizing the software, these fields are only used by Blockbench and aren't used by Minecraft.
- Template:Nbt: Name of an element (found in element objects).
- Template:Nbt: 2D Integer array defining the width and height of the texture(s) being used (found at the root object).
Uses of models
Template:Info needed section Non-hardcoded models are used in-game in the following contexts:
| Use case | Uses | Image | Respects Template:Code? |
|---|---|---|---|
| Blocks | |||
| Placed blocks | All blocks excluding those listed here | Template:Tc | |
| Minecraft:Falling blocks | All blocks excluding those listed here | Template:Tc | |
| Piston-moved blocks | All blocks excluding those listed here | Template:Tc | |
| Lit Minecraft:TNT | TNTTemplate:Verify | Template:Tc | |
| Minecraft:Snow Golem headpiece<ref>Template:Bug</ref> | Carved Pumpkin | Template:Verify | |
| Items | |||
| Items in the inventory | All items excluding air | Template:Tc | |
| Items in the player's hand (first person) | All items excluding airTemplate:Verify | Template:Tc | |
| Items in the player's hand (third person) Items held by other players Items held by mobs |
All items excluding airTemplate:Verify | Template:Tc | |
| Items on the ground | All items excluding air | Template:Tc | |
| Items in item frames | All items excluding air | Template:Tc | |
| Items on shelves | All items excluding air | Template:Verify | |
| Minecraft:Totem of undying animation | Any item with the "death protection" component | Template:TcTemplate:Verify | |
Each of the item display types are used in the following situations:
| Use case | Display type |
|---|---|
| Inventory items Crafting station icon on recipe unlock toasts |
Template:Code |
| Items equipped on the heads of certain mobsTemplate:Info needed Spyglasses when in use |
Template:Code |
| Dropped items Items held by Minecraft:dolphins<ref>Template:Bug</ref> Items held by Minecraft:pandas<ref>Template:Bug</ref> Items held by Minecraft:foxes<ref>Template:Bug</ref> Thrown projectiles<ref>Template:Bug</ref>Template:Info needed Items held by villagers and wandering traders Potions held by witches Ominous item spawner |
Template:Code |
| Items in item frames Totem of undying animation Items placed on campfires Items being brushed out of suspicious sand and gravel |
Template:Code |
| Items on shelves | Template:Code |
| Items held in a humanoid's left hand | Template:Code |
| Items held in a humanoid's right hand Items held in a humanoid's left hand, if Template:Code is left unspecified |
Template:Code |
| Items held in the left hand in first person | Template:Code |
| Items held in the right hand in first person Items held in the left hand in first person, if Template:Code is left unspecified |
Template:Code |
| Item display entities | Depends on what is specified |
Limitations
Objects that cannot be remodelled
Template:Info needed section While most blocks and items can have their model changed, there are a multitude of things that cannot.
For example, no entities (with the exception of Minecraft:item frames and Minecraft:glow item frames) can have their model changed Template:In with resource packs alone. Minecraft:Bells can have their attachment model changed but not the bell model itself.
Blocks and fluids
Template:Non-remodellable blocks
Even these blocks have particle textures defined in dedicated model files, however it still stands that actual visual models cannot be changed.
Sub-elements of blocks, such as passively emitted particles and the book on top of the Minecraft:enchanting table, cannot be modified, even though the base block can.
History
Issues
References
Template:Navbox resource packs Template:Navbox Java Edition technical
Minecraft:de:Modelldaten Minecraft:es:Modelo Minecraft:fr:Modèle Minecraft:ja:モデル Minecraft:pl:Modele bloków Minecraft:pt:Modelo Minecraft:zh:模型