Make SendKillObject send multiple localIDs in one packet. This avoids the

halting visual behavior of large group deletes and eliminates the packet flood
This commit is contained in:
Melanie
2010-10-08 11:31:52 +02:00
parent ba0afa53d3
commit 52dd547863
19 changed files with 79 additions and 53 deletions

View File

@@ -259,9 +259,10 @@ namespace OpenSim.Region.OptionalModules.ContentManagement
// I thought that the DeleteGroup() function would handle all of this, but it doesn't. I'm not sure WHAT it handles.
((SceneObjectGroup)scene.Entities[uuid]).DetachFromBackup();
scene.PhysicsScene.RemovePrim(((SceneObjectGroup)scene.Entities[uuid]).RootPart.PhysActor);
scene.SendKillObject(scene.Entities[uuid].LocalId);
scene.SendKillObject(new List<uint>() { scene.Entities[uuid].LocalId });
scene.SceneGraph.DeleteSceneObject(uuid, false);
((SceneObjectGroup)scene.Entities[uuid]).DeleteGroupFromScene(false);
scene.SendKillObject(new List<uint>() { ((SceneObjectGroup)scene.Entities[uuid]).LocalId });
}
catch(Exception e)
{

View File

@@ -175,7 +175,7 @@ namespace OpenSim.Region.OptionalModules.ContentManagement
//This is important because we are not IN any database.
//m_Entity.FakeDeleteGroup();
foreach (SceneObjectPart part in m_Entity.Parts)
client.SendKillObject(m_Entity.RegionHandle, part.LocalId);
client.SendKillObject(m_Entity.RegionHandle, new List<uint>() { part.LocalId });
}
/// <summary>
@@ -187,7 +187,7 @@ namespace OpenSim.Region.OptionalModules.ContentManagement
{
m_Entity.Scene.ForEachClient(
delegate(IClientAPI controller)
{ controller.SendKillObject(m_Entity.RegionHandle, part.LocalId); }
{ controller.SendKillObject(m_Entity.RegionHandle, new List<uint>() { part.LocalId }); }
);
}
}