x


IndexOutOfRange error on iPhone, but not on PC/Player

I have the following loop which accesses a multidimensional array. It works fine on PC and in the Player, but when I try to run the app for iOs it gives me an indexoutofrange exception. I'm at a loss debugging it as it ostensibly works fine everywhere else. Anyone have an idea as to what might be happening?

for (int z = worldDepthInBlocks - 1; z >= 0; z--)
{
    chunk.Blocks[blockXInChunk, blockYInChunk, z].Type = blockType;
}

//In Chunk...
private Block[,,] m_Blocks;
public Block[,,] Blocks
{
    get { return m_Blocks; }
    set { m_Blocks = value; }
}
more ▼

asked Jul 17 '12 at 02:42 PM

CazicThule gravatar image

CazicThule
47 2 9 14

(comments are locked)
10|3000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2000
x1363
x355
x95
x11

asked: Jul 17 '12 at 02:42 PM

Seen: 239 times

Last Updated: Jul 17 '12 at 02:42 PM