I’ve wanted an easy way to tween multiple properties of an object for a while now, but always been a little too lazy (or busy) to build one. Enter Flash 8, with its abundance of matrixes and filters, just begging to be tweened. My requirements were fairly straightforward:
- Support for matrixes (arrays) and objects
- Simple to integrate with existing tweening classes and custom tween routines
- An extremely straightforward and easy to use API
The result was the com.gskinner.transitions.MultiTween class, which you can download at the end of this post. It allows you to programmatically tween multiple object properties or array elements by changing a single value. Here’s a quick API spec: