Jump to content
Search Community

Is possible to know if an objec "is tweening"?

American horizon test
Moderator Tag

Recommended Posts

Yes, each tween has an isTweening property you can check.

 

Let me quickly boot up my other computer which I code on and get back on here...

 

...back. OK, so for example you have a movie clip called box, you've applied a tween to it and you want to know if that tween is still in progress:

 

if (TweenMax.isTweening(box)) {
//tween is still going, do whatever is here
}

 

Is basically saying, if the tween is still going, do...

 

Of course you could check if the tween isn't going by using:

 

if (!TweenMax.isTweening(box)) {
//tween is not in progress, do something
}

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...