Hi everyone,
i made this dynamic menu in flash a long time ago, and need to migrate it to AS2. The only problem is that when i change it to as2 on public settings and put flash player 6> , it stops working. ( actionscript aborted ).
Ill post the action script and see if anyone can help out.
*[SIZE=“3”]function resetMenu() {
for (i=1; i<=_root.total; i++) {
if (_root[“subText”+i]>=1) {
name = “stext”+i;
for (n=1; n<=_root[“subText”+i]; n++) {
this[name+n]._visible = false;
}// end of for
}
// end if
this[“menuMC”+i]._y = this[“menuMC”+(i-1)]._y+this[“menuMC”+(i-1)]._height;
}// end of for
}// End of the function
function submenuShow() {
resetMenu();
if (_root[“subText”+choice]>=1) {
name = “stext”+choice;
for (n=1; n<=_root[“subText”+choice]; n++) {
this[name+n]._visible = true;
}// end of for
this[“menuMC”+(choice+1)]._y = this[name+(n-1)]._y+this[name+(n-1)]._height;
for (i=choice+2; i<=_root.total; i++) {
this[“menuMC”+i]._y = this[“menuMC”+(i-1)]._y+this[“menuMC”+(i-1)]._height;
}// end of for
}
// end if
}// End of the function
for (i=1; i<=_root.total; i++) {
menuMC.duplicateMovieClip(“menuMC”+i,i);
this[“menuMC”+i]._y = this[“menuMC”+(i-1)]._y+this[“menuMC”+(i-1)]._height;
this[“menuMC”+i].choice = i;
levelTrack = i;
}// end of for
for (i=1; i<=_root.total; i++) {
if (_root[“subText”+i]>=1) {
name = “stext”+i;
for (n=1; n<=_root[“subText”+i]; n++) {
levelTrack = levelTrack+1;
subMenuMC.duplicateMovieClip(name+n,levelTrack);
this[name+n]._visible = false;
this[name+n].choice = i*10+n;
}// end of for
this[name+1]._y = this[“menuMC”+i]._y+this[“menuMC”+i]._height;
for (n=2; n<=_root[“subText”+i]; n++) {
this[name+n]._y = this[name+(n-1)]._y+this[name+(n-1)]._height;
}// end of for
}
// end if
}// end of for[/SIZE]*
Best regards,
Thomas