Share Posted September 15, 2020 I have build an scroll animation with a timeline and scrub, and I want to control it, with adding pause to it and with running multiple things at the same time. How can I do this? Link to comment Share on other sites More sharing options...
Share Posted September 15, 2020 Hey Jona and welcome to the GreenSock forums. The ScrollTrigger docs talk about how to create animations that are scrubbed on scroll. Is that what you're looking for? Your post is a bit ambiguous. It'd be helpful if you made a minimal demo showing what you're trying to do and explain what's going wrong: 1 Link to comment Share on other sites More sharing options...
Author Share Posted September 16, 2020 Thanks for the fast reply! Sorry that my explaination wasn't good. I try to explain the scrollanimation. I have 3 elements, a,b and c. Element a is moving in x direction. When it reaches 50% of the way, element b should rotate, during element a is moving. Without a pause or something like this. After elemnt a reaches its ending position, element c will change its color. I have made it a scrub animation, so delay don't work. Here is a codepen with a simple example what I did: See the Pen rNerRYY by JonaAnders (@JonaAnders) on CodePen Link to comment Share on other sites More sharing options...
Share Posted September 16, 2020 Thanks for the minimal demo! That's very clear. Since the default duration of tweens is 0.5, you should set the start time of the second tween to 0.25. What might make things easier to think about is changing the default duration of the tweens in the timeline to 1 instead. It won't affect the scrub effect but it will make conceptualizing timings a little easier. Here's how I'd set it up: See the Pen oNxMraV?editors=0010 by GreenSock (@GreenSock) on CodePen 2 1 Link to comment Share on other sites More sharing options...
Author Share Posted September 16, 2020 Thank you very much, you helped me a lot, now it works perfectly! 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