> Are these copies essentially just pointers to the same array?
Yes. You need to clone the objects/arrays, not just set pointers.
var newArray:Array = [];
var i:Number = oldArray.length;
while (i--) {
newArray[i] = oldArray[i];
}
return newArray;
If you're storing objects in the array not just numbers or strings, then
you need to clone those as well or they will just stored as pointers to
the objects in the other array.
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com