-
Bug
-
Resolution: Unresolved
-
None
-
1.21.1, 24w37a
-
None
-
Confirmed
-
Textures and models
The bug
If an item uses two textures combined together for its appearence, those two layers will be rendered in full, not accounting for cases where some geometry would never be visible from outside. This results in extra faces being rendered for no reason, causing potential render lag.
Potions, leather armor, spawn eggs, firework stars, trimmed armor and used maps are affected; in the case of trimmed armor and maps this causes extra internal Z-fighting.
How to reproduce
- Obtain one of these items
- Drop it on the ground or (excluding maps) put it in an item frame
- Clip inside of the item model
Expected results
Where one layer meets another, there would be no extra planes inside.
Actual results
There are.
How to fix
For the specific case of potions available in Survival, it may be worth abandoning the "base and inner with tint" system, and instead giving each potion its own texture file without a tint, meaning only one texture file needs to be rendered for each potion. This may happen in future: https://twitter.com/kingbdogz/status/1631006850282934289
However, if custom potions still exist, the two-layer system will probably be kept, and the issue will be localized to there. It will not be a Survival problem, but another solution may be required here.