Hey,
as I recently had to tell someone how and why to use TweenLite v11 (or any other Tweening Engine in AS3) I wanted to share that two minutes conversation with you. I think there will be following some other articles about TweenLite here - i guess there will be more Q&A talks concerning specific animations / techniques.
Setting up TweenLite is pretty simple at all. Just download the latest version for AS3 at the right top on this site: GreenSock Tweening Platform and unzip it. There were some minor changes in GreenSock's package order, so the following steps are written for v11.
In the unzipped folder you find some subfolders, containing docs, demos, badges and the like. If you're working withing the Flash IDE copy the com folder to the folder your .fla is saved. If you're using FDT or any other Coding IDE just link the .swc as a Library Source.
To use TweenLite and it's easing (and any other external Class not saved on the same directory-level) you have to import it with
-
import com.greensock.TweenLite;
-
import com.greensock.easing.*;
Now having a DisplayObject on stage you can tween it with the following syntax:
-
TweenLite.to($myClip, $timeInSeconds, {$propObj});
Care for the brackets. With this setup you can easily fadeout any DisplayObject on stage with:
-
TweenLite.to(myClip, 1.5, {alpha:0, ease:Linear.easeOut});
That's it.. more articles covering different easing-types, iterating multiple children, dealing with delays and overwrites are coming soon. Stay tuned for some hellish cool animations any timeline would have to struggle with! :)



April 27th, 2010
Marvin Blase
Posted in
Tags:
Hi, thanks for putting that online! Looking forward to your Tweening skills ^^
[...] da noch einige tutorials folgen und ich werde dann einfach immer den thread hier aktualisieren. Step 1 | Basic TweenLite (v11) Setup __________________ * Flash-Junkie ≠ Musiker & Grafiker # Marvin B. # The finer Art of [...]
Tell people to look the website & documentations...
http://www.greensock.com/tweenlite/