Jump to content
Search Community

can't pinpoint tweenmax error

kakarlus test
Moderator Tag

Recommended Posts

hi guys,

 

i have a lot of animation in around 5-7 views, my problem is that i can't pinpoint where the tweenmax error ocurs. do you have any tips such that it displays in which class (my class) does the error ocur. any help will be appreciated.

 

 

TypeError: Error #1034: Type Coercion failed: cannot convert global@10a1af01 to flash.display.DisplayObject.

at MethodInfo-3637()

at Function/http://adobe.com/AS3/2006/builtin::apply()

at com.greensock.core::TweenCore/complete()

at com.greensock::TweenMax/complete()

at com.greensock::TweenMax/renderTime()

at com.greensock.core::SimpleTimeline/renderTime()

at com.greensock::TweenLite$/updateAll()

 

 

thanks,

carlos

Link to comment
Share on other sites

It sounds like you've probably got an anonymous function somewhere in your code that is throwing the error. Generally anonymous functions should be avoided in ActionScript (although that's not a hard-and-fast rule). I'd recommend naming your functions so that the names will show up in the debugging output. For example:

 

//BAD
TweenLite.to(mc, 1, {x:100, onComplete:function() {...}});

//GOOD
TweenLite.to(mc, 1, {x:100, onComplete:myFunction});
function myFunction() {
   ...
}

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