hi evryone,
i have 5 buttons on a menu and when someone clicks them i'd like it to transfer its name to a variable and then have an action checking the variable and if it is equal to button1 it shows button1 movie clip etc etc etc.
so far, i have the variable all set up and working but when i try and add more buttons to the actionscript like this: it doesnt work properly and loads the first movieclip all the time.
if (var="button1" {
gotoAndPlay (76);
} else if (var="button2" {
gotoAndPlay (78);
} else if (var="button3" {
gotoAndPlay (80);
}
where am i going wrong?? and also, is there a better way of showing movie clips from the library (not seperate swf's) in the movie instead of putting them all on the timeline and using gotoAndPlay?
Thanks.
i have 5 buttons on a menu and when someone clicks them i'd like it to transfer its name to a variable and then have an action checking the variable and if it is equal to button1 it shows button1 movie clip etc etc etc.
so far, i have the variable all set up and working but when i try and add more buttons to the actionscript like this: it doesnt work properly and loads the first movieclip all the time.
if (var="button1" {
gotoAndPlay (76);
} else if (var="button2" {
gotoAndPlay (78);
} else if (var="button3" {
gotoAndPlay (80);
}
where am i going wrong?? and also, is there a better way of showing movie clips from the library (not seperate swf's) in the movie instead of putting them all on the timeline and using gotoAndPlay?
Thanks.