The problem is that I need a 2d matrix for a map which is defined in a config file. The map is not a set height or width so I need to have the ability to either make the map any size between 1x1 to 1000x1000. Is there some way to get around this or do I do what all the other games do and use a few sets of numbers for map sizes like 256x256 128x512 etc?
errors:Code:int **grid;
.
.
.
load>>x>>y>>input; //get dimentions of the map
grid = new int[x][y];
.
.
.
Code:error C2540: non-constant expression as array bound
'=' : cannot convert from 'int (*)[1]' to 'int ** '
Types pointed to are unrelated; conversion requires reinterpret_cast, C-style cast or function-style cast