-
Always Confused
motion guide tweening to random frame
is it possible to use motion guide tweening and have AS to stop at a random (or an array) frame within the mc?
-
Always Confused
ok so i figured it out myself...here is what to do if you have the same problem:
add this on the main time line:
var frameArray:Array=new Array(47,140,185)
var target:Number=Math.floor(Math.random()*frameArray. length)
frameToStopAt = frameArray[target];
ship_moving.play();
then on the MC (in my case a ship tweening along a path) add this on the frame you wish the animation to stop at:
if (_root.frameToStopAt == 47) {
stop();
}
and so on..on the other frames (47, 140, and 185)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|