-
-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Description
"custom_model_data" should be sorted from smallest to largest when merging resource packs, otherwise minecraft will not handle the "custom_model_data" correctly, resulting in unexpected behavior.
Because I encountered strange behavior in the 1.20.4 client, the item NBT "custom_model_data" was 2200001. But it used the model "magic:wands/enchantedbook" instead of "slimefun:slimefun/gui/slimefun_guide".
(I used machine translation, so I'm sorry if there's any confusion.)
https://minecraft.wiki/w/Tutorials/Models#Item_predicates
Unsorted data
{
"parent": "item/generated",
"textures": { "layer0": "item/enchanted_book" },
"overrides": [
{
"predicate": { "custom_model_data": 2200001 },
"model": "slimefun:slimefun/gui/slimefun_guide"
},
{
"predicate": { "custom_model_data": 2200003 },
"model": "slimefun:slimefun/gui/back"
},
{
"predicate": { "custom_model_data": 2200313 },
"model": "slimefun:slimefun/magical_gadgets/knowledge_tome"
},
{
"predicate": { "custom_model_data": 2200604 },
"model": "infinityexpansion:materials/ender_flame"
},
{
"predicate": { "custom_model_data": 2200605 },
"model": "item/enchanted_book"
},
{
"predicate": { "custom_model_data": 18001 },
"model": "magic:wands/enchantedbook"
}
]
}
Sorted data
{
"parent": "minecraft:item/generated",
"textures": { "layer0": "minecraft:item/enchanted_book" },
"overrides": [
{
"predicate": { "custom_model_data": 18001 },
"model": "magic:wands/enchantedbook"
},
{
"predicate": { "custom_model_data": 2200001 },
"model": "slimefun:slimefun/gui/slimefun_guide"
},
{
"predicate": { "custom_model_data": 2200003 },
"model": "slimefun:slimefun/gui/back"
},
{
"predicate": { "custom_model_data": 2200313 },
"model": "slimefun:slimefun/magical_gadgets/knowledge_tome"
},
{
"predicate": { "custom_model_data": 2200604 },
"model": "infinityexpansion:materials/ender_flame"
},
{
"predicate": { "custom_model_data": 2200605 },
"model": "item/enchanted_book"
}
]
}
Edited:
This issue has been fixed in version 24w45a, previous versions are still affected: https://bugs.mojang.com/browse/MC-158872
Akiranya, Flandreqwq, zty012, GoodestEnglish, XXY233 and 1 more
Metadata
Metadata
Assignees
Labels
No labels