-
Notifications
You must be signed in to change notification settings - Fork 1
Home
Trimmed armor items in Minecraft display one of four generic trim textures for every item, no matter what trim you put on an item the texture is always the same. This mod fixes that by adding more item trim textures that change depending on the trim applied
To add a pattern, create a JSON file in the assets/{namespace}/armortrimitemfix/patterns
folder and add an element
called pattern
that specifies the pattern ID.
{
"pattern": "minecraft:silence"
}
All that's left to do is to add a texture. The mod will look for a texture for each item type (
helmet
, chestplate
, leggings
, and boots
) with the ID
{pattern_namespace}:trims/items/{item_type}/{item_type}_{pattern_path}_trim.png
Note: The existence of the pattern with the specified ID is not validated, meaning typos in IDs will be ignored
Similar to patterns, create a JSON file in the assets/{namespace}/armortrimitemfix/materials
folder and add an element
called material
that specifies the material ID.
{
"material": "minecraft:diamond"
}
The mod will now look for a color palette texture with the material ID
{material_namespace}:trims/color_palettes/{material_path}.png
Note: Just like patterns, the existence of the material with the ID is not validated
Additionally, you can add a list for specifying material overrides allowing for changing color palettes depending on the item. Each entry is made up of two parts; the left side is the ID matched to the Override ID of a trimmable item, the right side is the override material ID, which is essentially a fake material used to find a color palette with the same ID.
Note: Be sure to make the override material ID something unique to prevent causing problems with real material IDs
{
"material": "minecraft:diamond",
"overrides": {
"minecraft:diamond_armor": "minecraft:diamond_darker"
}
}
Create a JSON file in the assets/{namespace}/armortrimitemfix/trimmables
folder and add the following two elements
{
"item": "minecraft:diamond_chestplate",
"type": "chestplate"
}
item
is the ID of the item to be added, unlike pattern and material IDs this is validated
type
must be one of helmet
, chestplate
, leggings
, boots
.
This will be used to determine which pattern texture to use
An optional ID that gets matched to the Material Overrides of each material, if there's a match, the material will use its alternate color palette for this item
{
"item": "minecraft:diamond_chestplate",
"type": "chestplate",
"override_id": "minecraft:diamond_armor"
}
By default, the mod will look for a texture with the same ID as the item in the items
directory e.g.
minecraft:leather_helmet -> minecraft:item/leather_helmet
to use as the base texture for the model.
This can be changed to any other texture in the block atlas like so
{
"item": "minecraft:leather_helmet",
"type": "helmet",
"textures": {
"layer0": "minecraft:block/dirt"
}
}
Additionally, up to three extra textures can be added in the same way, all of which will be rendered under the trim texture
{
"item": "minecraft:leather_helmet",
"type": "helmet",
"textures": {
"layer0": "minecraft:item/leather_helmet",
"layer1": "minecraft:item/leather_helmet_overlay0",
"layer2": "minecraft:item/leather_helmet_overlay1",
"layer3": "minecraft:item/leather_helmet_overlay2"
}
}
Just like item models, an optional list of tint sources can be specified to be applied to all the generated models. This is useful for things like dye-able armor
{
"item": "minecraft:leather_helmet",
"type": "helmet",
"tints": [
{
"type": "minecraft:dye",
"default": -6265536 // The vanilla leather armor color
}
]
}