This content has been marked as final. Show 3 replies
I don't think this can be solved unless I see your flash file. There would be too many questions based solely on this description, so lookinf at the flash file would make it easier for me to solve.
Ok on restart i lost the file i was working on. So heres the problem again.
In scene one theres a layer called "g2a" which holds a movie clip called "g2". "G2" holds a mc called "flame" and a button. The animation for "flame is right inside "g2" not flame itself.
Back at Scene 1, theres a layer called box which holds a MC called box. Inside of box is the animation.
What i want to happen is on the release of the button in g2a i want it to play the MC box. I don't know how to get the button to play a MC thats not in the same layer. I've attached the file. If anyone could help that would be awesome.
Here is your working example. I think you are going to have problems down the road unless you backtrack a little and understand a little more about proper time line construction. For example, on the layer called Design&Multimedia, you have the movie clip on the first frame, but within the movie clip you have 71 blank frames before you get to your animation. This is the only movie clip I changed for you regarding this. I removed the 71 blank frames in that movie clip and then moved the actual symbol on the main time line from frame 1 to frame 72 (where it originally showed up). This is how it should be done. Also, it's a better idea to place your action scripts on its own layer (either top layer in the time line or bottom) - I use top - instead of on a layer that contains a symbol.
To fix your other problem, I gave the symbol (g2) an instance name "mcG2" (frame layer g2a at frame number 104). Also, on layer "BOX", I gave it an instance name "mcBox" - you need to give symbols instance names so you can control them with action script - otherwise Flash doesn't know where you are trying to point the script. You will see on the frame labeled "actions" - frame 104, I have code of
mcBox.gotoAndPlay ("play box")
If you will open the symbol of "box", you will see how I have reconstructed it. Again, action frame on its own layer. In order to navigate to a particular frame using action script, I used a frame label "play box", then placed a stop(); on the last layer.
The code you pasted on your first post is incorrect in itself. When you use "this" in your code, you are referring to the time line where that action script lies and nothing else, so that code wouldn't work for anything as it is written.
The example I changed is here http://www.shan-dysigns.com/flash/box2c.fla