
www.web-discovery.net

Int*** threeD = new int**[40];
for(int j=0; j<40; ++j)
{
threeD[j] = new int*[4];
for(int k=0; k<2; k++)
threeD[j][k] = new int[2];
}

struct etc
value1 as int
value2 as int
/struct
struct_arr[] as etc
struct arr = new etc[40]
function resize_preserve(new_size, old_arr) //returns pointer
{
tmp_newArr = new etc[new_size];
memcpy(newArr,old_arr, nbytes);
return newArr;
}

quote:
array[40][2][1]=1234; // error, but shouldn't accept values from [1][1][1] up to [40][20][1] ?
This topic has been locked by a moderator. New replies are not allowed.
With your permission, GameDev.net uses analytics cookies to understand how people use the platform. You can accept analytics or continue with necessary cookies only. Learn more