aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
diff options
context:
space:
mode:
authorRobert Adams2013-09-10 17:32:01 -0700
committerJustin Clark-Casey (justincc)2013-09-20 21:04:03 +0100
commit568ff6fddc60d7cc86f3c568f349c00aafdf15fd (patch)
tree600ec04e21f42a1252f4151dee847ccd55d9f0d1 /OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
parentBulletSim: update DLLs and SOs for spring parameters and constraint (diff)
downloadopensim-SC_OLD-568ff6fddc60d7cc86f3c568f349c00aafdf15fd.zip
opensim-SC_OLD-568ff6fddc60d7cc86f3c568f349c00aafdf15fd.tar.gz
opensim-SC_OLD-568ff6fddc60d7cc86f3c568f349c00aafdf15fd.tar.bz2
opensim-SC_OLD-568ff6fddc60d7cc86f3c568f349c00aafdf15fd.tar.xz
BulletSim: add ClearCollisionProxyCache function to API.
Add proxy cache clearing when some properties are changed. This fixes a problem where objects would stop colliding of they were moved with setPosition mulitple times.
Diffstat (limited to '')
-rwxr-xr-xOpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs12
1 files changed, 10 insertions, 2 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
index 2efb1a5..47df611 100755
--- a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
@@ -300,8 +300,16 @@ public abstract class BSPhysObject : PhysicsActor
300 // Called in taint-time!! 300 // Called in taint-time!!
301 public void ActivateIfPhysical(bool forceIt) 301 public void ActivateIfPhysical(bool forceIt)
302 { 302 {
303 if (IsPhysical && PhysBody.HasPhysicalBody) 303 if (PhysBody.HasPhysicalBody)
304 PhysScene.PE.Activate(PhysBody, forceIt); 304 {
305 // Clear the collision cache since we've changed some properties.
306 PhysScene.PE.ClearCollisionProxyCache(PhysScene.World, PhysBody);
307 if (IsPhysical)
308 {
309 // Physical objects might need activating
310 PhysScene.PE.Activate(PhysBody, forceIt);
311 }
312 }
305 } 313 }
306 314
307 // 'actors' act on the physical object to change or constrain its motion. These can range from 315 // 'actors' act on the physical object to change or constrain its motion. These can range from