hevi
29-09-2009 17:22:00
hey everyone
I'm working on a 'AirStrike 3D' kind of game
but I have some problems because of collision groups ; I dont want the missiles to collide with eachother and also with the helicopter but with the enemy troops.
lets say that the missiles are in group 1, the helicopter is in 2 and the enemy troops are in 3. in that case i can easily disable collisions between group 1 and 2, but the problem is all the missiles are in group 1 and I couldnt manage to disable collisions within the same group.
I used
but it didn't work
briefly
how can I disable the collisions of the objects within the same group? Actorflags is not the answer because of performance constraints as there might be tens of missiles in the game.
my collision map in the game is;
Group 1 - Group 1 => collisions disabled
Group 1 - Group 2 => collisions disabled
Group 1 - Group 3 => collisions enabled
...
Group 2 - Group 2 => collisions disabled
Group 2 - Group 3 => collisions enabled
...
Group 3 - Group 3 => collisions disabled
...
I'm working on a 'AirStrike 3D' kind of game
but I have some problems because of collision groups ; I dont want the missiles to collide with eachother and also with the helicopter but with the enemy troops.
lets say that the missiles are in group 1, the helicopter is in 2 and the enemy troops are in 3. in that case i can easily disable collisions between group 1 and 2, but the problem is all the missiles are in group 1 and I couldnt manage to disable collisions within the same group.
I used
m_pNxScene->getScene()->setGroupCollisionFlag(1, 1, false);
but it didn't work
briefly
how can I disable the collisions of the objects within the same group? Actorflags is not the answer because of performance constraints as there might be tens of missiles in the game.
my collision map in the game is;
Group 1 - Group 1 => collisions disabled
Group 1 - Group 2 => collisions disabled
Group 1 - Group 3 => collisions enabled
...
Group 2 - Group 2 => collisions disabled
Group 2 - Group 3 => collisions enabled
...
Group 3 - Group 3 => collisions disabled
...