Hi all,
I’m very green to the world of flash and hope you can help me.
i have created a flash object based around the complex button tutorial link below:
http://www.kirupa.com/developer/mx2004/button_effect.htm
but with differances. in the main single frame i have 18 movieclips which are images which when clicked move forward and expand to the center of the stage. and when u click it again it goes back in to the original place. also if u click on another image while the first image if forward the first image goes back and the second one expand and moves into the center of the stage. thats fine… BUT if i click on the first image to bring it forward and then click on another image to bring that one forward the first one goes back no worries and the second one comes forward as it should… if the second image when expanded and has moved forward to the center of the stage is over the first image when you click on the second image to send it back the first image pops up, in it retracted size, in front of the second image breifly then goes back behind the second image and then the second image goes back as normal. i’m currently using swapDepths to put the images either coming forward or going back in front of all the others.
I hope this all makes sense?
here is my code in frame 1 of the movie:
stop();
this.onEnterFrame = function () {
if (rewind == true) {
prevFrame();
}
}
this.onRelease = function () {
if (this._currentFrame == 1) {
this.swapDepths(4);
rewind = false;
play();
}
else {
this.swapDepths(4);
rewind = true;
}
}
onMouseDown = function() {
if (this._currentframe>1) {
this.swapDepths(2);
rewind = true;
}
}
and on frame 20 i have just:
stop;
what i think is causing this problem is the swapDepths in the onMouseDown function.
can anyone please tell me how to get round this problem.
cheers in advance for any advice or help you can give me.