I'm trying to build a grid system in code (invisible grid) and thought an array would be the best option.
I wanted the array grid to change values (0 = false, 1 = true) if an object was covering those corresponding potions on the game field.
I tried a few variations of:
Start of Layout
->Set Array size to X=layoutWidth/gridsize Y=layoutHeight/gridsize
Fox "x" from 0 to layoutWidth/gridsize
Fox "y" from 0 to layoutHeight/gridsize
--If object is over gridsize*loopindex("x"),gridsize*loopindex("y")
->Set Array Index (loopindex("x"),loopindex("x")) to 1
--Else
->Set Array Index (loopindex("x"),loopindex("x")) to 0
But the array just wont recognize if something has been placed over the corresponding coordinates.
Can I not use the array this way?