Okay, correct me if I'm wrong. In this way the depth keeps
increasing and
will finally reach the limit (if there's any) causing erratic
behaviour in
the movie clip. I just need to swap two depths of two
different movie clips.
I need to create a kind of card shuffle like motion.
"DazFaz" <webforumsuser@macromedia.com> schreef in
bericht
news:egikak$s0a$1@forums.macromedia.com...
> MovieClip.prototype.changeDepth = function() {
> var highestDepth = 0;
> for (var i in this._parent) {
> highestDepth = (eval(i).getDepth()>highestDepth) ?
eval(i).getDepth() :
> highestDepth;
> }
> this.swapDepths(highestDepth);
> };
> myMovieClip = "menu"// this being the name of your menue
system
> for (var i in myMovieClip) {
> if (typeof (eval(i)) == "movieclip") {
> eval(i).onRollOver = function() {
> this.changeDepth();
> };
> }
> }
> // what this will do is loop through ever movieClip
within your menu and
> apply
> the "onRollOver" function to each movieClip within.
>