I’m sure this is pretty straightforward stuff, but I’m really just starting to get a handle on general actionscript - so any help would be tremendously appreciated.
Here’s what I’m trying to do:
I have a parent container movie that has several buttons on it. As it stands now the buttons trigger an instance of a MC on the main timeline to play using the “with” action (no biggie)
I would like to put a frame action in that MC instance that uses the “LoadMovieNum” action to load a particular external SWF movie into the container movie depending on which button the user clicked.
In theory I guess I need to somehow associate each button with it’s corresponding SWF child movie that is to be loaded (SetVariable?)
Then I need to pass that information to the MC instance in the main timeline that actually uses the LoadMovieNum command to load the SWF file.
Help anybody teach me how to do this, preferably without embarrassing me too much
the _root.loaded part is simply a switch, so you dont end up loading the same movie more than once. If you have more than one button (of course), your _root.loaded value will change to 2 for button 2, 3 for button 3, etc…
First on the button i define a variable of “MovieClip” and set it to “theSetup.swf”
then I tell the MC instance “_root.Doors” to play…like so:
on (release) {
MovieClip = “TheSetup.swf”;
with (_root.Doors) {
play();
}
}
Then in the MC instance “Doors” I have a frame action:
loadMovieNum(MovieClip value, _root.MasterSwap);
“MasterSwap” is the MC that is to be swapped out with the newly loaded SWF file. How do I load the MovieClip value that was set when the mouse was pressed?
Creating engaging and entertaining content for designers and developers since 1998.