PDA

View Full Version : using symbols in array


SRE
06-03-2010, 06:21 PM
please check it .
Is it corrrect, to use the array in symbols.

I am using lot of movieclips as a symbols

var myArray:Array = new Array(mySymbol1, mySymbol2, mySymbol3);

can i able to access the symbols using array variable"Array[]" like this

Array[1],Array[2],Array[3]

If not posssible,
how can i access the symbols
please give me the any other way

franky87
06-03-2010, 11:07 PM
var symb1:Sprite = new Sprite();
var symb2:Sprite = new Sprite();
symb1.name = "first symbol";
symb2.name = "second symbol";
var ary:Array = new Array(symb1, symb2);
trace(ary);
trace(ary[0]);
trace(ary[0].name);