Jump to content

Recommended Posts

Posted

When I make an API for a mod, I don't start of with the intention of making it an API. Make a system to animate your mobs, generalize it with interfaces, abstract classes and registries. Test your API, export it and release it.

 

As a side note, you, the creator of the API, should also use the API to make sure the API works as intended.

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Posted

Ok.. I started listing out some variables (this is btw my FIRST time designing an API so this is new to me) about what entities I want to animate and the yaw and pitch and timing varaibles controlling the animation time and yaw and pitch times. Im kinda stuck on how to list the methods

Main Developer and Owner of Zero Quest

Visit the Wiki for more information

If I helped anyone, please give me a applaud and a thank you!

Posted

Ok, let's start from the beginning. You want to make an API for animating entities. Why? Because you think it would help others out with animating their entities, or you want to make it easier for yourself in the future. In either case, try making a system for animating entities on your own entity, and if that works as intended, start to apply it to other entities as well. Then you start the clean-up progress:

- Duplicate code can be put in a static method or a method in a general super-class.

- If you need data from an Entity, make an interface defining the methods for getting that data, and use that instead of harcoded values.

- (Optional) Make registries for registering an entity using your animation API, so you have control of all the entities that use the API, and control them in any way.

 

That's basicly what I do, and it works for me.

Don't PM me with questions. They will be ignored! Make a thread on the appropriate board for support.

 

1.12 -> 1.13 primer by williewillus.

 

1.7.10 and older versions of Minecraft are no longer supported due to it's age! Update to the latest version for support.

 

http://www.howoldisminecraft1710.today/

Posted

Basically, my reason to make an API for animating entities because to it easy on myself on making animations for my entities (mine only) and have them in one place where I can access and control them all

Main Developer and Owner of Zero Quest

Visit the Wiki for more information

If I helped anyone, please give me a applaud and a thank you!

Posted

I think the first thing to consider is what type of entities and animations you're doing. For something stiff, simple and robotic or cyclical you can get by just doing same thing that vanilla entity models to -- use a bit of trigonometry to move things based on the swing progress parameter passed into the set rotation angles method.

 

For anything that is more complex, I like to do it like real animators -- they don't use math but instead create a number of "keyframe" poses in an animation program and then let the computer figure out the "tweens" (the positions in between as it moves).

 

I'm helping a big mod team with creating such a system. I've used Tabula to create a bunch of poses, and then put them in as assets then read them into an array. I have another array that indicates the order the poses should happen and the number of ticks it should take to move between the poses. Then each tick I have methods that calculate the amount of adjustment of rotation, position and offset for each block in the model.

 

I'm hoping to write a tutorial on this at some point, but basically I hope you get the idea. Such a system can allow much more complex and natural animations than doing math can do.

Check out my tutorials here: http://jabelarminecraft.blogspot.com/

Posted

Thats what I want to do, I want to make keyframes for advanced animations like a stationary one (similar to what JurrasiCraft has) to make it look like the creature is breathing. I have no idea how to acutally develop keyframes though

Main Developer and Owner of Zero Quest

Visit the Wiki for more information

If I helped anyone, please give me a applaud and a thank you!

Posted

I used something called MCA Animator but causes a lot of errors and it is difficult for me to start and stop animations once I made them

Main Developer and Owner of Zero Quest

Visit the Wiki for more information

If I helped anyone, please give me a applaud and a thank you!

Posted

Do you have problems with interpolations? Or is it totally another thing?

I. Stellarium for Minecraft: Configurable Universe for Minecraft! (WIP)

II. Stellar Sky, Better Star Rendering&Sky Utility mod, had separated from Stellarium.

Posted

Everything about it basically..  I never tried animations advanced like this before but I have done walking animations

Main Developer and Owner of Zero Quest

Visit the Wiki for more information

If I helped anyone, please give me a applaud and a thank you!

Posted

So what format do you want to follow.

I. Stellarium for Minecraft: Configurable Universe for Minecraft! (WIP)

II. Stellar Sky, Better Star Rendering&Sky Utility mod, had separated from Stellarium.

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.