Jump to content
Search Community

Declare one animation, for multiple MC's [SOLVED]

zumajoe test
Moderator Tag

Recommended Posts

I had a friend give me the code below showing how to do this in AS3... but i'm struggling to figure it out in AS2 (i started learning only AS3). It makes sense to me, however I know that AS2 doesn't use "int"..so I have no clue how to get this to work.

 

I want to declare an animation without a movieClip- and then whenever I wish to apply that animation to a certain MC i will tell it to do so.

 

This is the AS3 version:

 

import gs.TweenMax;

tweenIt( box, 200, 150 );

function tweenIt( item:MovieClip, ex:int, why:int ) : void
{
TweenMax.to(item, .7, { x:ex, y:why });
}

Link to comment
Share on other sites

I don't think i've ever seen anyone respond to posts as quickly.. without flaming us beginners for not knowing code not even related to GS. I do not donate everywhere, but will be donating here, not there. 8-)

 

Ha ha. No problem. Thanks for the kind words and your willingness to support the project. Cheers!

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