Destroying joint? possible bug?

razi

15-06-2011 20:08:34

How do I properly release and destroy created joint? This is my code

NxOgre::Joint* climbJoint=mScene->createFixedJoint(mBody,NxOgre::FixedJointDescription());
mScene->destroyJoint(climbJoint);

Even after calling destroy joint it still persists. Thank you.

razi

16-06-2011 14:58:00

So now I edited NxOgre to not call GC thingie and stuff but simply called raw physx mScene->releaseJoint and it works. Did I just find bug or am I doing something wrong. There no documentation about using joints in nxogre.

SniperBinaire

07-08-2012 23:09:03

For me Ogre crash after destroying a joint. (using NxOgre::Scene::destroyJoint)

SniperBinaire

18-08-2013 11:18:24

Micro update, because it may helps.
Don't remember why it don't crash anymore, but if a joint persists after deletion, you should try to make it breakable with a tiny maximum force :

Joint->setBreakable(0.00001f,0.000001f);

Definitely not a clean solution, but it may do the trick.