Jump to content


Fresh version of GS AS3 can't compile

Recommended Posts

I just donated to get the shockingly green and downloaded a fresh version of the AS3 version of Greensock. When I run my code I'm getting an error in Animation.as


Line 210 1061: Call to a possibly undefined method add through a reference with static type com.greensock.core:SimpleTimeline.
It says that there is no function "add" in SimpleTimeline, but I made sure and the SimpleTimeline does have the add function so I'm not sure why I'm getting this.
Link to comment
Share on other sites

hmm, in v11 there was no add() method. 


To be sure you are using the latest version please add this to your file:


If you get something other than 12.1.4, you don't have the latest version.




I just downloaded the latest and tested with:


import com.greensock.*;

var tl:TimelineLite = new TimelineLite();

tl.add(TweenLite.to(mc, 1, {x:100}));

function done() {
trace("all done"); 
trace(TweenLite.version); //12.1.4

add() worked in adding a label, tween, and a callback. No problems.


If you still have trouble please provide a very simple fla with just enough code to cause the error.


-- Be sure you download GSAP from http://www.greensock.com/account to get all the premium plugins.




Let us know if you still have trouble, I'm sure we can get it sorted.


Thanks for joining Club GreenSock!



Link to comment
Share on other sites

Yes you are right. Animation.as was actually referencing the wrong SimpleTimeline because I had some folders messed up. it is now fixed and working properly!



  • Like 1
Link to comment
Share on other sites

Great. No worries. It happens to all of us.

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.