Flasher Archive

[Previous] [Next] - [Index] [Thread Index] - [Previous in Thread] [Next in Thread]


Subject: Re: FLASH: Actionscript F5:swapDepths
From: Helen Triolo
Date: Fri, 24 Nov 2000 15:12:00 GMT

Paul,

I think it was created for using with duplicated movieclips (but that's
just my guess and could be a wrong assumption). But it does seem to
work with movieclips inside another (parent) movieclip as well. I
created two clips, green and blue, inside holder (with blue in front of
green initially), on the main timeline, then added three buttons:

1st button:
on (press) {
holder.green.swapDepths(5);
}

2nd button:
on (press) {
holder.blue.swapDepths(7);
}

3rd button:
on (press) {
holder.green.swapDepths(10);
}

and clicking them in that order (1, then 2, then 3) made the green pop
to the front, then blue, then green again. It isn't really swapping the
values, just replacing one.

I also added a 4th button with this action:

on (press) {
holder.green.swapDepths(_root.holder["blue"]);
}

and a 5th with this:

on (press) {
holder.green.swapDepths(holder.blue);
}

and they both worked to swap the depth of blue and green back and forth.

Regards,
Helen
-----------------------------------------------------
i-Technica � http://i-technica.com � 301.424.6037
developer resources: http://i-technica.com/whitestuff

Paul Willoughby wrote:
>
> Hi all,
>
> Has anyone tried using the swapDepths in Flash 5? Is it only possible to
> swap the Depths of movie clips that are duplicates of the same instance
> (this is what it seems to say in the reference documents)? Or is there a
> way to swap the depths of two movie clips that are within another clip,
> but aren't duplicates?
> I think I'm confused over the use of the term 'parent movie clip'. I've
> seen it being used as referring to a master MC which you make duplicates
> from, or as an MC that contains nested MC's. Which is the correct
> definition in Flashspeek?
>
> Cheers!
>
> paul
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
flasher is generously supported by...
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
flashforward2000 and the Flash(tm) Film Festival
November 27-29, 2000, LONDON, National Film Theatre

Produced by United Digital Artists and lynda.com
-Sponsored by Macromedia, Adobe Systems and Apple Computer
-http://www.flashforward2000.com or UK tel. +44 (0870) 751 1526
Register before November 10 and save �200
http:// www.flashforward2000.com
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To unsubscribe or change your list settings go to
http://www.chinwag.com/flasher or email helpatchinwag [dot] com


Replies
  FLASH: Actionscript F5:swapDepths, Paul Willoughby

[Previous] [Next] - [Index] [Thread Index] - [Next in Thread] [Previous in Thread]