Multi-dimensional array problems?
BlitzMax Forums/BlitzMax Programming/Multi-dimensional array problems?
| ||
Does anyone else have any problems using multi-dimensional arrays? I know skidracer mentioned that the debugger was having problems with multi-dimensional arrays, but I'm having problems in non-debug mode. In this piece of code when I comment out the last line in the if/endif block, the program runs fine, but when I uncomment the last line it crashes the program eventhough I'm referencing BoardArray in other places in the code. For iCount = (BoardHeightMatch-1) To 1 Step -1 If BoardArray[iCount,BoardArrayColumn] = 0 Then 'if there are no more pieces above the last one thats needs to move down; exit If BoardArray[(iCount-1),BoardArrayColumn] = 0 Then Exit BoardArray[iCount,BoardArrayColumn] = BoardArray[(iCount-1),BoardArrayColumn] ' BoardArray[(iCount-1),BoardArrayColumn] = 0 EndIf Next |