ok so i have a cloud named cloud2_mc and in its timeline i have a cloud layer, and an actions layer. I took the cloud and made it into a a Movie clip clip with an instance name of embeddedcloud_mc in this Movie clips timeline i have a 50 frame animation of the cloud breaking appart and disapating with a tween and i have a stop(); function on frame 1 of this layer.
What I want to happen is, when the cloud2_mc movie clip is clicked to play the animation of the cloud breaking appart. the cloud2_mc has a trajectory moving slowly accross the sceen continuously when the cloud2_mc reaches the side of the sceen it loops again. When the animation is clicked i would like it to continue across its path but, when the cloud2_mc reaches to left hand side of the screen i want the embeddedcloud_mc to reset its timeline and go back to its original state where the cloud has not broken appart.
My question is, how do I access an embedded movie clips timeline to tell it to play an animation on its timeline as well as, how do i make the same object restet its timeline to frame 1?
To access an objects timeline you just need to target the object. If all the names you are talking about are instance names (not library names) then you can taregt your embedded cloud timeline using...
cloud2_MC.embeddedcloud_mc, as in...
If you want to access cloud2_MC from inside embeddedcloud_mc you can just do: MovieClip(this.parent).gotoAndPlay('whatever');
Add more .parents to it to traverse higher up as much as you need. If your setup was Timeline->cloud2_MC->embeddedcloud_mc and you wanted to affect the Timeline you will need 2 parents.. so e.g. MovieClip(this.parent.parent).play();