Sign in to follow this  
fateriddle

Trying to animate a girl to rotation 90 degree, result in her rotate in circles (with PG)

Recommended Posts

I import a mesh of animation girl, and trying to rotate her then move her in sequence.

But the animation goes wild as girl rotate like 10 circles before she stays at the final key. Any reason for that and how do I fix?

https://www.babylonjs-playground.com/#WGZLGJ#367

 

btw, I always wanna ask, how do you animate a mesh's scaling? Do you have to make 3 animations for scaling.x, scaling.y, scaling.z?

Share this post


Link to post
Share on other sites
3 hours ago, brianzinn said:

Here is how to rotate that model.... I think if you see this PG you can hopefully get the answer to your second question:
https://www.babylonjs-playground.com/#WGZLGJ#369
hint: You need to change the animation type :)

Thanks.

1. Could you explain a bit why trying to change 'rotation.y' will result in such weird manner?

2. And when do I have to use rotationQuaternion to do the job? I see use case of 'rotation.y' here in this PG, and it works fine https://www.babylonjs-playground.com/#2L26P1#8 

Share this post


Link to post
Share on other sites
10 hours ago, fateriddle said:

And when do I have to use rotationQuaternion to do the job?

You can set rotationQuaternion to null and your PG will work, too.  I should have mentioned that...

https://www.babylonjs-playground.com/#WGZLGJ#371

RotationQuaternion when available takes priority.

Share this post


Link to post
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
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  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.

Loading...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.