Share Posted February 4, 2015 So I have...:var timeline = new TimelineLite ()Then timeline.from a few times, and timeline.fromTo once, and timeline.to once. Each one has {onUpdate: onUpdate ..}.In the onUpdate, I run TweenMax.killTweensOf(timeline) if certain conditions are met. I logged it and it's run hundreds of times, but the timeline keeps going.What's up with that? Anything obvious I missed? (I'd rather not post my code...) Link to comment Share on other sites More sharing options...
Share Posted February 4, 2015 Hi agamemnus pls check this out : http://greensock.com/docs/#/HTML5/GSAP/TimelineLite/kill/ 1 Link to comment Share on other sites More sharing options...
Share Posted February 4, 2015 It's tough to say without seeing your code or a simplified example, but I suspect you might be misunderstanding what killTweensOf() does. It allows you to kill the tweens of a particular target, but it looks like you're passing it an instance of a TimelineLite and expecting it to kill() the instance itself. What you're doing would kill tweens of that timeline (literally, like if you were tweening its timeScale with another tween or something). I bet you meant to do this: timeline.kill(); Right? (that's a long-winded way of saying exactly what Diaco.AW said) 3 Link to comment Share on other sites More sharing options...
Author Share Posted February 4, 2015 Oh.. thanks, guys! I appreciate the help, and the library. One more bug quashed. 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