Hello everybody,
I wonder if is there any way in AS3 to push data dynamically into a Vector using for() some thing like this:
var verticesT0:Vector.<Number> = new Vector.<Number>();
for(var i:int = 0; i < 5; i++)
{
verticesT0.push(
(“fila”+i+x*), (“fila”+i+y*)
);
}
And the use it with DrawTrangle
var t0:Sprite;
t0 = new Sprite();
addChild(t0);
t0.graphics.beginFill(0xFFFFFF);
t0.graphics.drawTriangles(verticesT0);