aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Physics/BulletSPlugin/BSScene.cs12
1 files changed, 10 insertions, 2 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs b/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
index a31c578..0a0e27e 100644
--- a/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs
@@ -78,10 +78,16 @@ public class BSScene : PhysicsScene, IPhysicsParameters
78 public string BulletSimVersion = "?"; 78 public string BulletSimVersion = "?";
79 79
80 private Dictionary<uint, BSCharacter> m_avatars = new Dictionary<uint, BSCharacter>(); 80 private Dictionary<uint, BSCharacter> m_avatars = new Dictionary<uint, BSCharacter>();
81 public Dictionary<uint, BSCharacter> Characters { get { return m_avatars; } }
82
81 private Dictionary<uint, BSPrim> m_prims = new Dictionary<uint, BSPrim>(); 83 private Dictionary<uint, BSPrim> m_prims = new Dictionary<uint, BSPrim>();
84 public Dictionary<uint, BSPrim> Prims { get { return m_prims; } }
85
82 private HashSet<BSCharacter> m_avatarsWithCollisions = new HashSet<BSCharacter>(); 86 private HashSet<BSCharacter> m_avatarsWithCollisions = new HashSet<BSCharacter>();
83 private HashSet<BSPrim> m_primsWithCollisions = new HashSet<BSPrim>(); 87 private HashSet<BSPrim> m_primsWithCollisions = new HashSet<BSPrim>();
88
84 private List<BSPrim> m_vehicles = new List<BSPrim>(); 89 private List<BSPrim> m_vehicles = new List<BSPrim>();
90
85 private float[] m_heightMap; 91 private float[] m_heightMap;
86 private float m_waterLevel; 92 private float m_waterLevel;
87 private uint m_worldID; 93 private uint m_worldID;
@@ -429,13 +435,13 @@ public class BSScene : PhysicsScene, IPhysicsParameters
429 { 435 {
430 numSubSteps = BulletSimAPI.PhysicsStep(m_worldID, timeStep, m_maxSubSteps, m_fixedTimeStep, 436 numSubSteps = BulletSimAPI.PhysicsStep(m_worldID, timeStep, m_maxSubSteps, m_fixedTimeStep,
431 out updatedEntityCount, out updatedEntitiesPtr, out collidersCount, out collidersPtr); 437 out updatedEntityCount, out updatedEntitiesPtr, out collidersCount, out collidersPtr);
432 // DetailLog("{0},Simulate,call, substeps={1}, updates={2}, colliders={3}", DetailLogZero, numSubSteps, updatedEntityCount, collidersCount); 438 DetailLog("{0},Simulate,call, substeps={1}, updates={2}, colliders={3}", DetailLogZero, numSubSteps, updatedEntityCount, collidersCount);
433 } 439 }
434 catch (Exception e) 440 catch (Exception e)
435 { 441 {
436 m_log.WarnFormat("{0},PhysicsStep Exception: substeps={1}, updates={2}, colliders={3}, e={4}", LogHeader, numSubSteps, updatedEntityCount, collidersCount, e); 442 m_log.WarnFormat("{0},PhysicsStep Exception: substeps={1}, updates={2}, colliders={3}, e={4}", LogHeader, numSubSteps, updatedEntityCount, collidersCount, e);
437 // DetailLog("{0},PhysicsStepException,call, substeps={1}, updates={2}, colliders={3}", DetailLogZero, numSubSteps, updatedEntityCount, collidersCount); 443 // DetailLog("{0},PhysicsStepException,call, substeps={1}, updates={2}, colliders={3}", DetailLogZero, numSubSteps, updatedEntityCount, collidersCount);
438 // updatedEntityCount = 0; 444 updatedEntityCount = 0;
439 collidersCount = 0; 445 collidersCount = 0;
440 } 446 }
441 447
@@ -534,6 +540,8 @@ public class BSScene : PhysicsScene, IPhysicsParameters
534 else if (m_avatars.ContainsKey(collidingWith)) 540 else if (m_avatars.ContainsKey(collidingWith))
535 type = ActorTypes.Agent; 541 type = ActorTypes.Agent;
536 542
543 DetailLog("{0},BSScene.SendCollision,collide,id={1},with={2}", DetailLogZero, localID, collidingWith);
544
537 BSPrim prim; 545 BSPrim prim;
538 if (m_prims.TryGetValue(localID, out prim)) { 546 if (m_prims.TryGetValue(localID, out prim)) {
539 prim.Collide(collidingWith, type, collidePoint, collideNormal, penitration); 547 prim.Collide(collidingWith, type, collidePoint, collideNormal, penitration);