Xna error - array of texture2d's
I have an array of Texture2D's set up like this;
map = new Texture2D[30, 18];
H开发者_StackOverflow中文版owever, when I try and refer to map[30, 1] I get an index out of range of array error. Any reason why this would be happening?
Thanks.
C# arrays are indexed from 0, so valid indices for an array of length 30 are 0 to 29.
精彩评论