Jump to content

Recommended Posts

Posted

RenderEntityItem uses the model retrieved from ItemModelMesher#getModel(ItemStack), but, unlike all of the other points of rendering items / blocks, does not check if the model is an ISmartItemModel, IPerspectiveAwareModel, or anything else of that nature (there is no longer even an ENTITY camera transform...).

 

Currently, the only way I can think of to render my item's custom smart model while in Entity form is to actually create a custom EntityItem and register a different render class for it. I can do that, but the entity itself doesn't actually need to do anything special, and the renderer would just be making calls to my smart item model, so it seems kind of like overkill.

 

Does anyone happen to know if there are plans amongst the Forge team to correct this, or is there already a solution that I am just overlooking?

Posted

Does anyone happen to know if there are plans amongst the Forge team to correct this,

 

You could suggest it on the suggestions board.

Posted

ItemModelMesher.getItemModel(ItemStack) actually is the place that calls the ISmartItemModel hook. As for perspective - default perspective (without additional perspective transformations) is what's used for entities, so you should make your default model be the one used for in-world entity.

Posted

You're right, and I had seen that there in ItemModelMesher before, but totally forgot about it. My problem is just that the default model is not the one I want to render in the world and IPerspectiveAwareModel#handlePerspective is not called for EntityItems, which is slightly unfortunate.

 

Still, changing which model I use for the default is pretty simple, though I will lose out on the changes I'd like to make based on perspective.

 

Speaking of which, why isn't there an EntityItem camera transform anymore? Or is that 'NONE' ?

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.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Announcements



×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.