So I have a base class w/ a struct in it, I inherit it off to 2 more classes, which in turn create pointer objects each. One I create a whole new arrays of information, the other I assign it the memory reference of the other in the other class w/ the data. So when I go to assign an integer variable the value of it, it comes up with a run-time error during execution:
System.NullReferenceException.
It compiles just fine, using debug mode I can see the values are there. How come when it hits the part to read the int value from the pointed to int array it crashes?
int temp = Map[y].tile_ID[x]; //<---pointer error crap going on
I can see in debug mode that the values of tile_ID[x] is there, but it still crashes.
struct sMap{ int *tile_ID; bool *clip; };
Map is a struct array and tile_ID is a int array. Help please! =(