Thanks for dropping by! Please make yourself at home by leaving comments and subscribing to the RSS feed to stay updated.
|
Categories: Blogroll
Archives:
|
HOW TO: Randomize/Shuffle an array in Flash (AS2)January 30, 2010
No Comments
I was creating a logo scroller in flash when a client of mine asked me if the logo’s could show up in a random order. This lead me to look to see if Actionscript 2.0 has a built in function to randomize an array. Well, I didn’t find a built in funciton, but i found a great blog entry describing how to build you own. The following code snippets come from: http://mrsteel.wordpress.com/2007/06/15/randomize-array-shuffle-an-array-in-flash/ Prototype function and return function code is : |