Flash scripting question
Flash scripting question
Out of context: Reply #3
- Started
- Last post
- 4 Responses
- fyoucher10
Turn em into movieclips, stop frame on 1st frame.
Then use variables and have your button code check them:
var currentButton:Movieclip;
btn1.onRelease() = function:Void {
//This is the 1st time a button is pressed
if (currentButton == undefined ) {
currentButton = this;
this.gotoAndStop(2); //over state
return();} else {
currentButton.gotoAndStop(1); // previous button back to default
this.gotoAndStop(2);
}
}Then fill in the rest of the button code
- or change that entire thing into a reusable function / method...fyoucher1