EXC_BAD_ACCESS error when box2d joint is destroyed
- by colilo
When I destroy the weldJoint in the update method (see below) I get an EXC_BAD_ACCESS error pointing to the line
world->DestroyJoint(weldJoint);
in the update method below:
-(void) update: (ccTime) dt
{
int32 velocityIterations = 8;
int32 positionIterations = 1;
// Instruct the world to perform a single step of simulation. It is
//…