Compatibility
Minecraft: Java Edition
Links
Details
What is this?
- Does not replace existing textures or models of the vanilla game.
- Use custom item models to decorate the container GUI instead of Glass Panes and Heads.
- Stack layers of models, then use custom model data to control.
- Template models for easily creating layer models from textures.
- An item model definition as an example or direct use.
GUItem
The goal is to imitate the container GUI by covering inventory slots with pieces of the GUI elements.
Models can be created from template models by simply providing textures to the specified texture variable.
The templates and models are categorized from GUI elements, layered from bottom to top:
- Background
- The bottom layer that can be displayed.
- Ignorable or unimportant information that does not affect the reading.
- Field
- To declare sections or primary color fill.
- Pattern
- Visually interact with.
- Implicit or direct informing of something.
- Slot
- Can insert, take, or preview items.
- Button
- Something will happen when interacting with.
- Must have a placeholder state if the action cannot be available.
- Icon
- Expression of condensed information.
- Symbols or graphics representing.
- Foreground
- The top layer that can be displayed.
- Any information that must be shown, even if the items can be covered.
Models can then be composed into the item model definition, and can also be controlled by custom model data by adding some tricks.
Here is an example /give
command to get a "check mark button" by using the provided item model definition: /give @s minecraft:recovery_compass[minecraft:item_model='guitem:gui_stack',minecraft:custom_model_data={"strings":["","","","","button","check_mark",""]}]
GUI Pieces
Most pieces are designed to fit a whole slot size:
Some pieces have a greater cover area that extends to other slots, representing a complete element or being a foreground/background to the others:
Playing with oversized items with caution! They may have their own rules for covering items:
Known Issues
- Item models are rendered slightly dim.
- Oversized models sometimes have a smaller UV area, resulting in the wrong scaling of the texture.
Compatibility Info
- namespace:
guitem
- atlases directory:
gui_item