Jump to content
Search Community

Timing With MotionPathPlugin

Andy1708 test
Moderator Tag

Recommended Posts

I try the MotionPathPlugin to move the octopus along this path but it seems not to be perfectly synchronize every time in the loop animation.

what am i doing wrong ?

I put a white stroke to see the path.

You can fork the codepen if you want and comment each animation on the mainTl (eyeTween, octopusTween, movePathTween) to see what's happened behind the scene.

Thanks for your answer

Yves

See the Pen dyPqPKj by YVES_V (@YVES_V) on CodePen

Link to comment
Share on other sites

Hey Andy,

 

This is because you have repeat: -1 on each of the sub-timelines. That means that they will each repeat as soon as they complete, regardless of the other animations, for infinity. In other words, the master timeline (mainTL) will never repeat because its children never finish animating. 

 

What you should do instead is arrange it so that all of the children timeline end at or near the same time. That may require some calculation depending on how you set it up. Then you can put a repeat: -1 the master timeline and have the whole thing repeat. 

 

Does that make sense?

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...