I'm doing a basic 2D array in C# and I've got a bit of confusion.
I'm a lot more used to working with 1-based arrays, so 0-based arrays kind of mess up my head if you know what I mean.
blocks = new Block[15, 999];
for (int x = 0; x <= 15; x++)
{
for (int y = 0; y <= 999; y++)
{
blocks[x, y] = new Dirt(terrainTexture, new Vector2(x * 16, y * 16));
}
}
So it's telling me I'm out of bounds of the array?
If the array is from
0-15, 0-999
Shouldn't a loop from 0-15, 0-999 work?