Nuchaz Posted August 6, 2016 Posted August 6, 2016 I am updating my mod, BiblioCraft, from 1.8.9 to 1.9.4 / 1.10.2 (tried both, same issue) and I have some custom models that implement IPerspectiveAwareModel. The interface adds the handlePerspective method to my custom model and in 1.8.9 would run every tick on item models. Now in 1.9.4 / 1.10.2 it doesn't get called at all and my models transforms are unaffected by anything that happens in this method. What changed here? Is there something new I need to do to make the handlePerspective method fire in 1.9.4 / 1.10.2? Quote
Nuchaz Posted August 7, 2016 Author Posted August 7, 2016 I should also mention I am loading an OBJ model so I am pretty sure it is using the OBJBakedModel class when rendering. After further investigation, the OBJBakedModel class implements IPerspectiveAwareModel and it calls the handlePerspective method like this: @Override public Pair<? extends IBakedModel, Matrix4f> handlePerspective(TransformType cameraTransformType) { return IPerspectiveAwareModel.MapWrapper.handlePerspective(this, state, cameraTransformType); } So it looks like it is calling the static, state sensitive method of handlePerspective for IPerspectiveAwareModel instead of the method with just the TransformType, which is the one I need to get called in my custom OBJ model that extends IPerspectiveAwareModel. In debug mode in Eclipse I can see that the state sensitive version of handlePerspective is indeed running on IPerspectiveAwareModel, but the handlePerspective on my custom model never gets called. This is starting to maybe look like a bug in forge, but I'd like a second opinion. Should I create an issue on the forge github for this? I am still wondering too if maybe there is just something new I have to do that wasn't in 1.8.9 that I am unaware of. Quote
Durand1w Posted October 18, 2016 Posted October 18, 2016 Any suggestions or confirmation from the Forge team? It looks like Nuchaz logged a bug report that was assigned, but the owner hasn't been active for a few months. https://github.com/MinecraftForge/MinecraftForge/issues/3173 Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.