is supported in part by

July 26, 2004

uhlmann launches AnimationPackage

it's a great day for scripted animators and rich internet app developers alike: alex uhlmann has officially released his superb "AnimationPackage" library. with AnimationPackage (AP), you can create programmatic drawings and animation sequences with amazingly little effort.

written entirely in actionscript 2.0, AP provides classes to draw basic primitive shapes (rectange, circle, polygon) and some complex ones (gear, star, rounded rectangle, dashed line, spiral, etc). lines, arcs, and spirals can be animated into place procedurally (so it looks like a pen is drawing them on screen).

as great as the AP drawing toolset is, the fun really starts when you create programmatic, object-oriented animations. you can bounce something across the screen, shake something, blur something, or add a motion tween all with a couple lines of code. you can even move something along a bezier curve or animate a color transformation.

here's all the code you need to move a MovieClip in an arc:

var myMOC:MoveOnQuadCurve = new MoveOnQuadCurve(mc);

or if you're into compactness, its:
new MoveOnQuadCurve(mc).run(100,100,300,300,500,100,4000,Circ.easeInOut);

here's the code you need to shake something back and forth:

new Shake(mc).run(.1,2000);

oh yeah, that's sweet! and if you want to spin the object around after it arrives at the end of the curve or stops shaking, no problem: you can chain animations together using the flexible event handling system (based on grant skinner's "GDispatcher" extension to the v2 EventDispatcher system).

the api has been well thought out, and contains sensible classes like Parallel, which lets you run several animations together at the same time. flexibility and extensibility are evident throughout...for example, the tweening engine itself can be changed, allowing frame-based or time-based animations.

AP even sports thorough documentation and lots of example files so you can see how things work before you try to produce a given effect.

if you've already been messing around with the mx.effects.Tween class or have ever used one of robert penner's easing equations, you *must* look at AP. free some time, sit down for an afternoon, and enjoy the fun. start with this super concise tutorial:

>> read AnimationPackage tutorial

then take a look at the docs and download AP here:
>> visit AnimationPackage home

great respect and thanks to alex for this gift to the flash community...

Posted by moock at July 26, 2004 08:39 PM