[Bug - models] Custom large chest model slows down game reloads
PixalThePixeled opened this issue ยท 4 comments
Model "chest_large" cannot find the chest part to use their animations on the first try. which slows down the loading of packs.
It is noteworthy that the part that uses animation and the part with animation are on the same side ("base_left" uses "lid_left" animation)
The model manages to find them and apply their animations, but this does not happen the first time, which is why the mod issues a warning in the logs:
- [09:43:49] [Render thread/WARN]: [EMF]: no part found for: [lid_left.rx] in [minecraft:optifine/cem/chest_large/chest_large103.jem]. Available parts were: {lid_right:EMF_lid_right, EMF_knob_right, EMF_lid_right, base_right, lid_right, EMF_base_right, knob_right:EMF_knob_right, root, knob_right, base_right:EMF_base_right}
- [09:43:49] [Render thread/WARN]: [EMF]: Variable [lid_left.rx] not found in animation [drawer.tz] of model [minecraft:optifine/cem/chest_large/chest_large103.jem]. EMF will treat the variable as zero.
Using right parts animations on left parts gives a similar error but does not change the animation at all, but this can be ignored since the left and right parts use the same animations.
- Minecraft Version: 1.21
- EMF version: 2.1.3
so this is kind of a tricky situation, in vanilla the large chest is not 1 model, there are left and right half models to the large chest.
I have no idea why optifine decided to merge these into 1 model .jem but becuase they do it means i have to merge them somehow.
A result of this merge is when i make a "left large chest" model it will not have all the right hand side parts in it at all, so when the animations try and apply for the right hand side they simply have nothing to target so throw this error.
I am looking into improving the logs for this case, but there is nothing i can do when it comes to custom parts within the opposite chest side being referenced which will always trigger these error messages
tl;dr when emf makes the "right large chest" model itll complain that the "left large chest" model parts dont exist. and vice versa. there isnt much to be done about this, and removing these log messages would open up even more potential issues
this should not at all present a slowdown, at most it means this model searches a bit more for part names during the animation setup phase but this should not have any significant slowdown during boot