aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/SceneGraph.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/SceneGraph.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/SceneGraph.cs24
1 files changed, 5 insertions, 19 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneGraph.cs b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
index 66fb493..dd0ca43 100644
--- a/OpenSim/Region/Framework/Scenes/SceneGraph.cs
+++ b/OpenSim/Region/Framework/Scenes/SceneGraph.cs
@@ -215,27 +215,13 @@ namespace OpenSim.Region.Framework.Scenes
215 if (sp.IsChildAgent) 215 if (sp.IsChildAgent)
216 continue; 216 continue;
217 217
218 if (sp.ParentID != 0) 218 SceneObjectPart sitPart = sp.ParentPart;
219 { 219 if (sitPart != null)
220 // sitting avatar 220 coarseLocations.Add(sitPart.AbsolutePosition + sp.OffsetPosition);
221 SceneObjectPart sop = m_parentScene.GetSceneObjectPart(sp.ParentID);
222 if (sop != null)
223 {
224 coarseLocations.Add(sop.AbsolutePosition + sp.OffsetPosition);
225 avatarUUIDs.Add(sp.UUID);
226 }
227 else
228 {
229 // we can't find the parent.. ! arg!
230 coarseLocations.Add(sp.AbsolutePosition);
231 avatarUUIDs.Add(sp.UUID);
232 }
233 }
234 else 221 else
235 {
236 coarseLocations.Add(sp.AbsolutePosition); 222 coarseLocations.Add(sp.AbsolutePosition);
237 avatarUUIDs.Add(sp.UUID); 223
238 } 224 avatarUUIDs.Add(sp.UUID);
239 } 225 }
240 } 226 }
241 227