Last year I created a small timeline based intro of products for a
client that used Math.random to produce a random start of the
animation sequence. This year they would like two specific product
animations to always start in the #1 and #2 position and the remaining
7 products to play in a random order. I have given this some thought
and am not sure how to go about it. Any ideas out there? If I contain
the two specific products to the # 1 and # 2 positions, and procede
randomly to the rest, how might I get all 7 remaining products to play
before replaying #1 and #2?
Last years code below:
stop();
var minList:Array = ["mmPretzel", "3Musketeers_truffle",
"MilkyWay_Caramel", "mmCO", "mmCherry", "Twix_java", "VOTE", "mmPB",
"NASCAR"];
var minStart:Number = Math.floor(Math.random()*9);
trace(minStart);
trace(minList[minStart]);
function goOn(){
gotoAndPlay(minList[minStart]);
};
setTimeout(goOn,+8);
Don Talcott
316 Greenwood Ave
Decatur, GA 30030
404 538-1642
[email protected]
_______________________________________________
Flashcoders mailing list
[email protected]
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders