Being fairly new to actionscripting I’m getting frustrated with what seems to be an easy thing. What I’m making is a simple navigation bar that opens and closes to sublinks. To do this, I’ve made several movie clips and just have them played when the buttons are clicked on. The problem is this: when I’m in a movieclip of my menu being opened, how can I find out when the movieclip of my menu closing is done, so that I can play another movieclip? (I know - it’s confusing).
Here is the code that I have placed on a movieclip inside of a movieclip:
//playing movie membershipclose.swf in instance allbuttons
on (release){
_root.allbuttons.loadMovie(“membershipclose.swf”);
//finding if the movie membershipclose.swf is done playing
_root.allbuttons.onEnterFrame = function(){
loaded = _root.allbuttons.getBytesLoaded();
total = _root.allbuttons.getBytesTotal();
//if it is done playing, now it will play applicationsopen.swf
if (loaded == total) {
_root.allbuttons.loadMovie(“applicationsopen.swf”);
}
}
}
What I want to happen here is when the button is released the movieclip “membershipclose.swf” will play in allbuttons. Then when this is done playing, I want “applicationsopen.swf” to play in allbuttons. I can’t just put a loadMovie at the end of “membershipclose.swf” because I have other movieclips that need to be played as well inside of allbuttons. What I have seems pretty logical to me, but it’s not working.
Please Help!!