diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | 2 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs | 11 |
2 files changed, 8 insertions, 5 deletions
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index 473c802..ee0f674 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | |||
@@ -4851,7 +4851,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
4851 | { | 4851 | { |
4852 | m_parts.Clear(); | 4852 | m_parts.Clear(); |
4853 | m_sittingAvatars.Clear(); | 4853 | m_sittingAvatars.Clear(); |
4854 | m_rootPart = null; | 4854 | // m_rootPart = null; |
4855 | 4855 | ||
4856 | m_PlaySoundMasterPrim = null; | 4856 | m_PlaySoundMasterPrim = null; |
4857 | m_PlaySoundSlavePrims.Clear(); | 4857 | m_PlaySoundSlavePrims.Clear(); |
diff --git a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs index 098f1b4..ac8c32d 100644 --- a/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs +++ b/OpenSim/Region/Framework/Scenes/Tests/SceneObjectBasicTests.cs | |||
@@ -171,11 +171,14 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
171 | // Test that we don't get back an object for a local id that doesn't exist | 171 | // Test that we don't get back an object for a local id that doesn't exist |
172 | Assert.That(scene.GetGroupByPrim(999), Is.Null); | 172 | Assert.That(scene.GetGroupByPrim(999), Is.Null); |
173 | 173 | ||
174 | uint soid = so.LocalId; | ||
175 | uint spid = parts[partsToTestCount - 1].LocalId; | ||
176 | |||
174 | // Now delete the scene object and check again | 177 | // Now delete the scene object and check again |
175 | scene.DeleteSceneObject(so, false); | 178 | scene.DeleteSceneObject(so, false); |
176 | 179 | ||
177 | Assert.That(scene.GetGroupByPrim(so.LocalId), Is.Null); | 180 | Assert.That(scene.GetGroupByPrim(soid), Is.Null); |
178 | Assert.That(scene.GetGroupByPrim(parts[partsToTestCount - 1].LocalId), Is.Null); | 181 | Assert.That(scene.GetGroupByPrim(spid), Is.Null); |
179 | } | 182 | } |
180 | 183 | ||
181 | /// <summary> | 184 | /// <summary> |
@@ -194,12 +197,12 @@ namespace OpenSim.Region.Framework.Scenes.Tests | |||
194 | SceneObjectGroup so = SceneHelpers.AddSceneObject(scene); | 197 | SceneObjectGroup so = SceneHelpers.AddSceneObject(scene); |
195 | 198 | ||
196 | Assert.That(so.IsDeleted, Is.False); | 199 | Assert.That(so.IsDeleted, Is.False); |
200 | uint retrievedPartID = so.LocalId; | ||
197 | 201 | ||
198 | scene.DeleteSceneObject(so, false); | 202 | scene.DeleteSceneObject(so, false); |
199 | 203 | ||
200 | Assert.That(so.IsDeleted, Is.True); | 204 | SceneObjectPart retrievedPart = scene.GetSceneObjectPart(retrievedPartID); |
201 | 205 | ||
202 | SceneObjectPart retrievedPart = scene.GetSceneObjectPart(so.LocalId); | ||
203 | Assert.That(retrievedPart, Is.Null); | 206 | Assert.That(retrievedPart, Is.Null); |
204 | } | 207 | } |
205 | 208 | ||