Julian Bleecker wrote:
That's great Ian — thanks for the help! Each of those little idioms
makes sense when described — I never would've figured these out just
whacking at various permutations, particularly the very baroque
incantation leveraging the invisible symbol names.
You may find it more convenient to consider MovieClip items as
primitives -- or at least not worth your time to extend -- and create
classes which wrap them. If you just want MovieClips to do particular
things, or exhibit polymorphic behavior, you can probably get away with
this:
class Foo
{
private var myClip:MovieClip;
public function Foo()
{
// create the MovieClip, possibly by
// creating a new instance from the library
}
public function doThing()
{
myClip.doSomething();
myClip.doSomethingElse();
var tween:Tween = new Tween(some properties, myClip);
trace("And so on");
}
}
I find this approach easier to work with and, since you could have more
than one MovieClip in your custom object, more flexible. (Sure, Flash
also lets you nest MovieClips ad infinitum, but moving away from
parent.child.child.child is another benefit of going Java style.)
_______________________________________________
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com