Hi everybody,
I have a quite annoying bug which is really simple.
In my game I have a radius detection that allows bodies to sleep when they are away from the screen. Just before allowing sleeping I added a line to be sure that it will not move anymore :
body_->SetLinearVelocity(b2Vec2_zero);
But in the SetLinearVelocity call the line 495 (in b2Body.h) which crashes:
if (m_type == b2_staticBody) <<<< THREAD 1: Program received signal: "EXC_BAD_ACCESS"
In my log I have this:
Current language: auto; currently objective-c++
Warning: the current language does not match this frame.
The point is that it crashes 1/1000 times... If anyone has been able to beat a bug like that one, I am really interested to know how !
Thanks 😉
I have a quite annoying bug which is really simple.
In my game I have a radius detection that allows bodies to sleep when they are away from the screen. Just before allowing sleeping I added a line to be sure that it will not move anymore :
body_->SetLinearVelocity(b2Vec2_zero);
But in the SetLinearVelocity call the line 495 (in b2Body.h) which crashes:
if (m_type == b2_staticBody) <<<< THREAD 1: Program received signal: "EXC_BAD_ACCESS"
In my log I have this:
Current language: auto; currently objective-c++
Warning: the current language does not match this frame.
The point is that it crashes 1/1000 times... If anyone has been able to beat a bug like that one, I am really interested to know how !
Thanks 😉