diff options
Diffstat (limited to 'OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs')
-rw-r--r-- | OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs index 8a6f06c..fabf276 100644 --- a/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Environment/Scenes/SceneObjectGroup.cs | |||
@@ -592,7 +592,8 @@ namespace OpenSim.Region.Environment.Scenes | |||
592 | m_scene = scene; | 592 | m_scene = scene; |
593 | RegionHandle = m_scene.RegionInfo.RegionHandle; | 593 | RegionHandle = m_scene.RegionInfo.RegionHandle; |
594 | 594 | ||
595 | m_rootPart.ParentID = 0; | 595 | if (m_rootPart.Shape.PCode != 9 || m_rootPart.Shape.State == 0) |
596 | m_rootPart.ParentID = 0; | ||
596 | if (m_rootPart.LocalId==0) | 597 | if (m_rootPart.LocalId==0) |
597 | m_rootPart.LocalId = m_scene.AllocateLocalId(); | 598 | m_rootPart.LocalId = m_scene.AllocateLocalId(); |
598 | 599 | ||
@@ -921,9 +922,10 @@ namespace OpenSim.Region.Environment.Scenes | |||
921 | public void SetRootPart(SceneObjectPart part) | 922 | public void SetRootPart(SceneObjectPart part) |
922 | { | 923 | { |
923 | part.SetParent(this); | 924 | part.SetParent(this); |
924 | part.ParentID = 0; | ||
925 | part.LinkNum = 0; | ||
926 | m_rootPart = part; | 925 | m_rootPart = part; |
926 | if (!IsAttachment) | ||
927 | part.ParentID = 0; | ||
928 | part.LinkNum = 0; | ||
927 | 929 | ||
928 | // No locking required since the SOG should not be in the scene yet - one can't change root parts after | 930 | // No locking required since the SOG should not be in the scene yet - one can't change root parts after |
929 | // the scene object has been attached to the scene | 931 | // the scene object has been attached to the scene |