At 12/28/07 08:22 PM, aonefischer wrote:
I m writing the code on the main timeline on frame 1 but I want to switch between the frames on the movie clip I made. IS this the right code for that?
YOURMCNAMEHERE.a = true;
YOURMCNAMEHERE.b = true;
YOURMCNAMEHERE.onEnterFrame=function(){
if(Key.isDown(Key.LEFT)){
if(a == true){
a = false;
gotoAndStop(_currentframe - 1);
}
} else {
a = true;
}
if(Key.isDown(Key.RIGHT)){
if(b == true){
b = false;
gotoAndStop(_currentframe + 1);
}
} else {
b = true;
}
}
put this code on your frame, and replace YOURMCNAMEHERE with the linkage ID of your MC