Skip to main content
Known Participant
April 27, 2007
Question

Easy If Statement Question

  • April 27, 2007
  • 1 reply
  • 120 views
I am just trying to get this if statement to work. Basically what I want is when the button labeled t2 is pressed I want one of my other movie clips to go to the first frame and stop. Here is the code I have written. Any help would be greatly appreciated.

t2.onPress = function() {
torso.gotoAndStop(3,0);
if (t2.onPress == true) {
bottom.gotoAndStop(1,0);
}
}

her is the code that is controlling the movie clip that I want to affect when I press t1

b1.onPress = function() {
bottom.gotoAndStop(2,0);
}
b2.onPress = function() {
bottom.gotoAndStop(3,0);
}
b3.onPress = function() {
bottom.gotoAndStop(4,0);
}
This topic has been closed for replies.

1 reply

Known Participant
April 27, 2007
Ok I have found a work around here, but I need help again with another if statement question. Perhaps someone could help me with this. I want t say

If mc1 is on frame 3 then mc2 is to remain on frame 1 until mc1 is no longer on frame 3.

Any help would be greatly appreciated!