diff options
Diffstat (limited to 'OpenSim/Region')
4 files changed, 21 insertions, 19 deletions
diff --git a/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs b/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs index 916148b..64567db 100644 --- a/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs +++ b/OpenSim/Region/Framework/Scenes/AsyncSceneObjectGroupDeleter.cs | |||
@@ -105,7 +105,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
105 | if (permissionToDelete) | 105 | if (permissionToDelete) |
106 | { | 106 | { |
107 | foreach (SceneObjectGroup g in objectGroups) | 107 | foreach (SceneObjectGroup g in objectGroups) |
108 | g.DeleteGroup(false); | 108 | g.DeleteGroupFromScene(false); |
109 | } | 109 | } |
110 | } | 110 | } |
111 | 111 | ||
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index ef97dfc..8a90bc8 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -2120,7 +2120,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2120 | EventManager.TriggerParcelPrimCountTainted(); | 2120 | EventManager.TriggerParcelPrimCountTainted(); |
2121 | } | 2121 | } |
2122 | 2122 | ||
2123 | group.DeleteGroup(silent); | 2123 | group.DeleteGroupFromScene(silent); |
2124 | 2124 | ||
2125 | // m_log.DebugFormat("[SCENE]: Exit DeleteSceneObject() for {0} {1}", group.Name, group.UUID); | 2125 | // m_log.DebugFormat("[SCENE]: Exit DeleteSceneObject() for {0} {1}", group.Name, group.UUID); |
2126 | } | 2126 | } |
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index dc6509d..f9a8d41 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | |||
@@ -29,6 +29,7 @@ using System; | |||
29 | using System.Collections.Generic; | 29 | using System.Collections.Generic; |
30 | using System.Drawing; | 30 | using System.Drawing; |
31 | using System.IO; | 31 | using System.IO; |
32 | using System.Linq; | ||
32 | using System.Threading; | 33 | using System.Threading; |
33 | using System.Xml; | 34 | using System.Xml; |
34 | using System.Xml.Serialization; | 35 | using System.Xml.Serialization; |
@@ -1234,28 +1235,29 @@ namespace OpenSim.Region.Framework.Scenes | |||
1234 | /// must be handled by the caller. | 1235 | /// must be handled by the caller. |
1235 | /// | 1236 | /// |
1236 | /// <param name="silent">If true then deletion is not broadcast to clients</param> | 1237 | /// <param name="silent">If true then deletion is not broadcast to clients</param> |
1237 | public void DeleteGroup(bool silent) | 1238 | public void DeleteGroupFromScene(bool silent) |
1238 | { | 1239 | { |
1240 | List<SceneObjectPart> parts; | ||
1241 | |||
1239 | lock (m_parts) | 1242 | lock (m_parts) |
1243 | parts = m_parts.Values.ToList(); | ||
1244 | |||
1245 | foreach (SceneObjectPart part in parts) | ||
1240 | { | 1246 | { |
1241 | foreach (SceneObjectPart part in m_parts.Values) | 1247 | Scene.ForEachScenePresence(delegate(ScenePresence avatar) |
1242 | { | 1248 | { |
1243 | // part.Inventory.RemoveScriptInstances(); | 1249 | if (avatar.ParentID == LocalId) |
1244 | Scene.ForEachScenePresence(delegate(ScenePresence avatar) | ||
1245 | { | 1250 | { |
1246 | if (avatar.ParentID == LocalId) | 1251 | avatar.StandUp(); |
1247 | { | 1252 | } |
1248 | avatar.StandUp(); | ||
1249 | } | ||
1250 | 1253 | ||
1251 | if (!silent) | 1254 | if (!silent) |
1252 | { | 1255 | { |
1253 | part.UpdateFlag = 0; | 1256 | part.UpdateFlag = 0; |
1254 | if (part == m_rootPart) | 1257 | if (part == m_rootPart) |
1255 | avatar.ControllingClient.SendKillObject(m_regionHandle, part.LocalId); | 1258 | avatar.ControllingClient.SendKillObject(m_regionHandle, part.LocalId); |
1256 | } | 1259 | } |
1257 | }); | 1260 | }); |
1258 | } | ||
1259 | } | 1261 | } |
1260 | } | 1262 | } |
1261 | 1263 | ||
diff --git a/OpenSim/Region/OptionalModules/ContentManagementSystem/CMModel.cs b/OpenSim/Region/OptionalModules/ContentManagementSystem/CMModel.cs index fd59138..0b02a9f 100644 --- a/OpenSim/Region/OptionalModules/ContentManagementSystem/CMModel.cs +++ b/OpenSim/Region/OptionalModules/ContentManagementSystem/CMModel.cs | |||
@@ -263,7 +263,7 @@ namespace OpenSim.Region.OptionalModules.ContentManagement | |||
263 | scene.PhysicsScene.RemovePrim(((SceneObjectGroup)scene.Entities[uuid]).RootPart.PhysActor); | 263 | scene.PhysicsScene.RemovePrim(((SceneObjectGroup)scene.Entities[uuid]).RootPart.PhysActor); |
264 | scene.SendKillObject(scene.Entities[uuid].LocalId); | 264 | scene.SendKillObject(scene.Entities[uuid].LocalId); |
265 | scene.SceneGraph.DeleteSceneObject(uuid, false); | 265 | scene.SceneGraph.DeleteSceneObject(uuid, false); |
266 | ((SceneObjectGroup)scene.Entities[uuid]).DeleteGroup(false); | 266 | ((SceneObjectGroup)scene.Entities[uuid]).DeleteGroupFromScene(false); |
267 | } | 267 | } |
268 | catch(Exception e) | 268 | catch(Exception e) |
269 | { | 269 | { |