Current code:
Code: Select all
btRigidBody* tileRigidBody[300][300]
Code: Select all
int* intarray = new int[10]
Code: Select all
btRigidBody* tileRigidBody[300][300]
Code: Select all
int* intarray = new int[10]
Code: Select all
btRigidBody **rbArray = new btRigidBody*[300]; //returns a pointer to a btRigidBody*
for (int x=0;x<300;x++) rbArray[x] = new btRigidBody(/* constructor arguments here */); //returns a btRigidBody*
Code: Select all
btRigidBody ***rbArray = new btRigidBody**[300]; //returns a pointer to a btRigidBody** ... double pointer so intense
for (int x = 0; x < 300; x++) {
rbArray[x] = new btRigidBody*[300]; //returns a pointer to a btRigidBody*
for (int y = 0; y < 300; y++) {
rbArray[x][y] = new btRigidBody(/* constructor arguments here */); //returns a btRigidBody*
}
}