OK so a question...
If I have a
single dimension array that has been created and I want to quiz the value held in a certain cell , but clearly I don't want to request data from a cell that doesn't exist (ie beyond the scope of the array that will "crash" AGK) it's easy, I just check with
So, let's say I want to check cell number 5 (ie CheckCell = 5) I just do...
If CheckCell > Array.length
Tell user no-can-do and don't quiz the array or you'll get a "crash"
Else
ValueInCell = Array[CheckCell]
Endif
If I have a
jagged multi-dimensional array, and I want to do the same what do I do....
So, let's say I want to check cell location [5,3]....
How would I safely go about ascertaining if there is such a cell in my array (in as simple and clear a way as possible so I can read the code) so that I don't request data from a cell that is beyond the scope of the array and therefore crashes?
Using Tier 1 AppGameKit V2
Started coding with AMOS (Thanks Francois Lionet)