aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region')
-rw-r--r--OpenSim/Region/Environment/Scenes/EntityBase.cs2
-rw-r--r--OpenSim/Region/Environment/Scenes/InnerScene.cs27
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs10
-rw-r--r--OpenSim/Region/Environment/Scenes/SceneObjectPart.cs1
4 files changed, 18 insertions, 22 deletions
diff --git a/OpenSim/Region/Environment/Scenes/EntityBase.cs b/OpenSim/Region/Environment/Scenes/EntityBase.cs
index 2a8c1e9..670ca13 100644
--- a/OpenSim/Region/Environment/Scenes/EntityBase.cs
+++ b/OpenSim/Region/Environment/Scenes/EntityBase.cs
@@ -46,7 +46,7 @@ namespace OpenSim.Region.Environment.Scenes
46 get { return m_scene; } 46 get { return m_scene; }
47 } 47 }
48 48
49 public LLUUID m_uuid; 49 protected LLUUID m_uuid;
50 50
51 public virtual LLUUID UUID 51 public virtual LLUUID UUID
52 { 52 {
diff --git a/OpenSim/Region/Environment/Scenes/InnerScene.cs b/OpenSim/Region/Environment/Scenes/InnerScene.cs
index 053fc85..c75ca81 100644
--- a/OpenSim/Region/Environment/Scenes/InnerScene.cs
+++ b/OpenSim/Region/Environment/Scenes/InnerScene.cs
@@ -489,40 +489,27 @@ namespace OpenSim.Region.Environment.Scenes
489 if (child) 489 if (child)
490 { 490 {
491 m_numChildAgents++; 491 m_numChildAgents++;
492 m_log.Info("[SCENE]"+ m_regInfo.RegionName + ": Creating new child agent."); 492 m_log.Info("[SCENE]" + m_regInfo.RegionName + ": Creating new child agent.");
493 } 493 }
494 else 494 else
495 { 495 {
496 m_numRootAgents++; 496 m_numRootAgents++;
497 m_log.Info("[SCENE] "+ m_regInfo.RegionName + ": Creating new root agent."); 497 m_log.Info("[SCENE] " + m_regInfo.RegionName + ": Creating new root agent.");
498 m_log.Info("[SCENE] "+ m_regInfo.RegionName + ": Adding Physical agent."); 498 m_log.Info("[SCENE] " + m_regInfo.RegionName + ": Adding Physical agent.");
499 499
500 presence.AddToPhysicalScene(); 500 presence.AddToPhysicalScene();
501 } 501 }
502 502
503 lock (Entities) 503 lock (Entities)
504 { 504 {
505 if (!Entities.ContainsKey(presence.m_uuid)) 505 Entities[presence.UUID] = presence;
506 {
507 Entities.Add(presence.m_uuid, presence);
508 }
509 else
510 {
511 Entities[presence.m_uuid] = presence;
512 }
513 } 506 }
507
514 lock (ScenePresences) 508 lock (ScenePresences)
515 { 509 {
516 if (ScenePresences.ContainsKey(presence.m_uuid)) 510 ScenePresences[presence.UUID] = presence;
517 {
518 ScenePresences[presence.m_uuid] = presence;
519 }
520 else
521 {
522 ScenePresences.Add(presence.m_uuid, presence);
523 }
524 } 511 }
525 } 512 }
526 513
527 public void SwapRootChildAgent(bool direction_RC_CR_T_F) 514 public void SwapRootChildAgent(bool direction_RC_CR_T_F)
528 { 515 {
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
index 47c4567..e295f87 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs
@@ -123,7 +123,15 @@ namespace OpenSim.Region.Environment.Scenes
123 123
124 public override LLVector3 AbsolutePosition 124 public override LLVector3 AbsolutePosition
125 { 125 {
126 get { return m_rootPart.GroupPosition; } 126 get
127 {
128 if( m_rootPart == null )
129 {
130 throw new NullReferenceException(string.Format("Object {0} has no root part.", m_uuid));
131 }
132
133 return m_rootPart.GroupPosition;
134 }
127 set 135 set
128 { 136 {
129 LLVector3 val = value; 137 LLVector3 val = value;
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
index 5b3ea0f..060003e 100644
--- a/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
+++ b/OpenSim/Region/Environment/Scenes/SceneObjectPart.cs
@@ -270,6 +270,7 @@ namespace OpenSim.Region.Environment.Scenes
270 m_groupPosition.Y = PhysActor.Position.Y; 270 m_groupPosition.Y = PhysActor.Position.Y;
271 m_groupPosition.Z = PhysActor.Position.Z; 271 m_groupPosition.Z = PhysActor.Position.Z;
272 } 272 }
273
273 return m_groupPosition; 274 return m_groupPosition;
274 } 275 }
275 set 276 set