forEach is a nice wee function to speed some bizzo up on particular arrays.
myArray.forEach(myFunction); // for each item in this array, runs myFunction function. } public function myFunction(element:*, index:int, arr:Array):void { // element returns the current item (ie. myArray[0] etc. and the rest is clear) }
Tech Reference: AS3
Leave a Reply