Jump to content

1.15.1 entity model problems


treblotmail

Recommended Posts

I've been struggling to create a custom entity. I used BlockBench to create the model and have fixed up some parts of it (it's not complete so there is probably some terrible code in there). I have a few questions: 

 

1. When I export the model as a .java file using BlockBench, for some reason it uses bodypart.cubeList.add() even though cubeList is private. Is there a way to get around that or is using .cubeList.add() completely wrong?

 

2. In other places of reference I've looked at, such as GirafiStudios' Waddles mod (https://github.com/GirafiStudios/Waddles/blob/master/src/main/java/com/girafi/waddles/client/model/PenguinModel.java) and McJty's examplemod (https://github.com/McJty/YouTubeModding14/blob/master/src/main/java/com/mcjty/mytutorial/entities/WeirdMobModel.java) for 1.14/1.15, they've all been using bodypart.addBox(). However, in my environment, the ModelRenderer.class doesn't even have the addBox method. When I try to use addBox Intellij says "cannot resolve addBox() in ModelRenderer" And I looked ModelRenderer up on the documentation and its totally there. What do I even do to get around this?

 

Code: https://pastebin.com/4ePXPwtz

 

If this is relevant, the forge version I am using is 1.15.1 - 30.0.50 with the default mcp mapping

 

Thanks for any help and sorry if this is very lengthy!

Link to comment
Share on other sites

Hi

I'd advise you swap to the latest forge version (not recommended), because the mcp mappings are much better.

 

It sounds like you're doing things the right way.

 

You might find this example project useful (see MBE80 and MBE21), it has some working examples of models (rendered using a TER not an entity but the ModelRenderer is the same)

https://github.com/TheGreyGhost/MinecraftByExample

 

Don't use the cubeList.add(). addBox() should work fine instead.

 

-TGG

Link to comment
Share on other sites

15 hours ago, treblotmail said:

However, in my environment, the ModelRenderer.class doesn't even have the addBox method

Try to update to the last mappings versions. 

15 hours ago, treblotmail said:

Is there a way to get around that or is using .cubeList.add() completely wrong?

Yes, here is no more a cubelist, but you simply can use the add function.

New in Modding? == Still learning!

Link to comment
Share on other sites

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.