From f205de7847da7ae1c10212d82e7042d0100b4ce0 Mon Sep 17 00:00:00 2001 From: dan miller Date: Fri, 19 Oct 2007 05:24:38 +0000 Subject: from the start... checking in ode-0.9 --- .../contrib/BreakableJoints/diff/ode.cpp.diff | 28 ++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 libraries/ode-0.9/contrib/BreakableJoints/diff/ode.cpp.diff (limited to 'libraries/ode-0.9/contrib/BreakableJoints/diff/ode.cpp.diff') diff --git a/libraries/ode-0.9/contrib/BreakableJoints/diff/ode.cpp.diff b/libraries/ode-0.9/contrib/BreakableJoints/diff/ode.cpp.diff new file mode 100644 index 0000000..761b7be --- /dev/null +++ b/libraries/ode-0.9/contrib/BreakableJoints/diff/ode.cpp.diff @@ -0,0 +1,28 @@ +212,230d211 +< /******************** breakable joint contribution ***********************/ +< dxJoint* nextJ; +< if (!world->firstjoint) +< nextJ = 0; +< else +< nextJ = (dxJoint*)world->firstjoint->next; +< for (j=world->firstjoint; j; j=nextJ) { +< nextJ = (dxJoint*)j->next; +< // check if joint is breakable and broken +< if (j->breakInfo && j->breakInfo->flags & dJOINT_BROKEN) { +< // detach (break) the joint +< dJointAttach (j, 0, 0); +< // call the callback function if it is set +< if (j->breakInfo->callback) j->breakInfo->callback (j); +< // finally destroy the joint if the dJOINT_DELETE_ON_BREAK is set +< if (j->breakInfo->flags & dJOINT_DELETE_ON_BREAK) dJointDestroy (j); +< } +< } +< /*************************************************************************/ +931,933d911 +< /******************** breakable joint contribution ***********************/ +< j->breakInfo = 0; +< /*************************************************************************/ +1011,1013d988 +< /******************** breakable joint contribution ***********************/ +< if (j->breakInfo) delete j->breakInfo; +< /*************************************************************************/ -- cgit v1.1