diff options
author | Justin Clark-Casey (justincc) | 2012-10-11 23:56:03 +0100 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2012-10-11 23:56:03 +0100 |
commit | f5f5f2e3fbc34c2bb0688177ea9a91d7fe674fc4 (patch) | |
tree | 73b56a7b8294cc55c5f33c30b52bcefbf7d24e60 /OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs | |
parent | Extend "show stats" command to "show stats [list|all|<category name>]" (diff) | |
parent | BulletSim: update the DLLs and SOs (diff) | |
download | opensim-SC_OLD-f5f5f2e3fbc34c2bb0688177ea9a91d7fe674fc4.zip opensim-SC_OLD-f5f5f2e3fbc34c2bb0688177ea9a91d7fe674fc4.tar.gz opensim-SC_OLD-f5f5f2e3fbc34c2bb0688177ea9a91d7fe674fc4.tar.bz2 opensim-SC_OLD-f5f5f2e3fbc34c2bb0688177ea9a91d7fe674fc4.tar.xz |
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs')
-rwxr-xr-x | OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs b/OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs index 63a4127..a20be3a 100755 --- a/OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSConstraint.cs | |||
@@ -49,9 +49,16 @@ public abstract class BSConstraint : IDisposable | |||
49 | if (m_enabled) | 49 | if (m_enabled) |
50 | { | 50 | { |
51 | m_enabled = false; | 51 | m_enabled = false; |
52 | bool success = BulletSimAPI.DestroyConstraint2(m_world.ptr, m_constraint.ptr); | 52 | if (m_constraint.ptr != IntPtr.Zero) |
53 | m_world.physicsScene.DetailLog("{0},BSConstraint.Dispose,taint,body1={1},body2={2},success={3}", BSScene.DetailLogZero, m_body1.ID, m_body2.ID, success); | 53 | { |
54 | m_constraint.ptr = System.IntPtr.Zero; | 54 | bool success = BulletSimAPI.DestroyConstraint2(m_world.ptr, m_constraint.ptr); |
55 | m_world.physicsScene.DetailLog("{0},BSConstraint.Dispose,taint,id1={1},body1={2},id2={3},body2={4},success={5}", | ||
56 | BSScene.DetailLogZero, | ||
57 | m_body1.ID, m_body1.ptr.ToString("X"), | ||
58 | m_body2.ID, m_body2.ptr.ToString("X"), | ||
59 | success); | ||
60 | m_constraint.ptr = System.IntPtr.Zero; | ||
61 | } | ||
55 | } | 62 | } |
56 | } | 63 | } |
57 | 64 | ||