I'm using AS2, but I could also do it in AS3.
I'm making a simple animation with about 10 "coins" on screen. I have a movie clip that animates another movie clip flipping over. I want to pull a random movie clip from the library into the nested clip so that on each "flip" a random coin face comes up.
I've put all the clip names into an array (coin1,coin2,coin3,etc.)
I think it would be described as _root.coin_container.coin_animation.random_coin_here
There will be 10 coin_container's on the main stage, with coin_animation nested inside. At the beginning of the animation a random movie clip from the array should be called into coin_animation, then coin_animation will run through a few frames, repeat, call another random movie clip and repeat.
Additionally if I could set a random time for the animation to pause so the 10 animations are flipping randomly that would be nice.
I hope that is clear enough.
Thanks!
Best Answer
An as2 example. Paste this into an frame 1 of an empty flash file, create a movieclip called "coin" and via properties set its linkage identifier to "coin". You can adapt this for what you need. No need for several frames...
You will need to create the coin movieclip correctly. You should have a
stop();
on frame 1 and on the last frame a blank empty keyframe that hasgotoAndPlay(2);