The rundown:
Ok here’s the deal. I hope that somebody knows how to script the new Flash UI components, because I don’t seem to be able to. I have a combobox with the instance name “box1” and a pushbutton with an instance name “play1”.
The problem:
Each selection in “box1” has a scene I want to go to when “play1” is clicked. If the script below is added to “play1” and I run the movie, all the trace() commands work just fine, but the “_root.gotoAndPlay(“scene whatever”, 1);” doesn’t work at all. (The trace() commands were added to see if my if(){} statements are working, and they appear to be).
In essence, I was hoping somebody could help me out. If you need a file attachment, I MAY be able to (not at home right now).
//Script for “play1”:
// Code
on (release) {
if (_root.box1.getSelectedIndex() == 0) {
_root.gotoAndPlay(“scene 0”, 1);
trace(“scene 0, 1”);
}
if (_root.box1.getSelectedIndex() == 1) {
_root.gotoAndPlay(“scene 1”, 1);
trace(“scene 1, 1”);
}
if (_root.box1.getSelectedIndex() == 2) {
_root.gotoAndPlay(“scene 2”, 1);
trace(“scene 2, 1”);
}
if (_root.box1.getSelectedIndex() == 3) {
_root.gotoAndPlay(“scene 3”, 1);
trace(“scene 3, 1”);
}
if (_root.box1.getSelectedIndex() == 4) {
_root.gotoAndPlay(“scene 4”, 1);
trace(“scene 4, 1”);
}
if (_root.box1.getSelectedIndex() == 5) {
_root.gotoAndPlay(“scene 5”, 1);
trace(“scene 5, 1”);
}
}
// End
P.S. this does have formatting