Jump to content

1.8.9 Animating 3D Models


DestinySpork

Recommended Posts

(This post was renamed)

 

I have a working 3d model using a .obj file, but I would like to know if I can render it from a tile entity.

I want to know because I want to a. animate it and b. change it depending on the block's state.

 

Also if anyone knows how to make my custom furnace render correctly in the inventory that would be appreciated :)

http://prntscr.com/an17a9

Link to comment
Share on other sites

I suggest you use Forge's animation system for this. I can't help you with it much myself, but there's an example mod here (assets).

 

The commit that added the system briefly explains the purpose of each animation class.

Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.

Link to comment
Share on other sites

Ok, so I've gone through all the code and copied it out.

However, my block just renders as a cube with missing texture. It is doing something because it is outputting to the console:

 

 

[16:57:52] [Client thread/INFO] [sTDOUT]:[destinyspork.appliedautomation.tileentity.ITileEntityChest:handleEvents:30]: Event: boop 0.001953125 BlockPos{x=-320, y=63, z=68} 15422.008

 

 

 

Also, i'm not sure why there is a chest involved with this, because it's looking for engine models.

 

Anyway, a model is better than no model so can anyone see what is wrong here?

EntityChest - http://pastebin.com/gWzNFJib

TileEntityChest - http://pastebin.com/PAYmWeJL

ClientProxy - http://pastebin.com/ScY4XpAN

If you need other classes tell me.

 

Also also - it looks to me like these 'frames' are stored inside a jason file - is there no way to set them in code? I don't want the model to change, I just want it to move, and smoothly (using sin(x)  ).

 

Link to comment
Share on other sites

Ok, I've decided to just say what it is I'm trying to make, and so hopefully somebody can help me from there.

I want to make a multiblock structure for an oil jack, and I want the 'swingy bit' to swing when it is active. I'm thinking of using 2 models, one for the frame and one for the arm. Hopefully this makes it clear what I am trying to achieve here.

 

PS. I don't want to use JSON because a. I want smooth motion and b. It's horrible and blocky, and can only do rectangular quads.

 

Edit: I was kinda wrong about that, smooth motion is possible with interpolation.

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.