Tuesday, May 22, 2012

[Action Script] 2D array problem May,2012

I have the code:


Code: var blockmanager:Array = new Array() Code: blockmanager[0] = new Array()
Code: blockmanager[0].push(block.x)
blockmanager[1].push(block.y)...to add some block positions (x,y) to this 2D array. First of all, am I doing it the right way? Second of all, im getting this error :Error #1010: A term is undefined and has no properties.

What is wrong?

EDIT: I want the array to look like this with x values in colum 1 and y values in colum 2:

snpr.cm/QpbNAz.png
2D array problem

Related Post



0 comments: