Share Posted February 3 I have a timeline probably like this tl .addLabel('1') to(...) .addLabel('2') to(...) .addLabel('3') when I call tl.tweenTo(tl.nextLabel()); The next tween must wait untill the last one was ended before it can start playing So how can i accelerate the last one ? Or I achieve it another way rather than timeline ? Link to comment Share on other sites More sharing options...
Share Posted February 3 Hi @UnrilWever welcome to the forum! Do you have a minimal demo for this, so what we can see what is going on. Can't you put an onComplete call back on the tween an run your function only when it is done animating? https://greensock.com/docs/v3/GSAP/Tween/eventCallback() Link to comment Share on other sites More sharing options...
Solution Solution Share Posted February 3 Hi, What you could do is when you call the tweenTo method you could change the timescale of the timeline and, as @mvaneijgen mentioned, use an onComplete method to reset the timescale back to 1 in order to set the speed of the timeline to normal. I'd recommend you to keep everything in a timeline since it's simpler and easier to update the timescale of a specific instance each time you want to go to a specific label. Happy Tweening! Link to comment Share on other sites More sharing options...
Author Share Posted February 4 I may unable to give a demo,but all of your suggestion does help and good to answer my question Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now