add sog TemporaryInstance flag
parent
8b77162020
commit
67bc086782
|
@ -195,6 +195,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
get { return m_hasGroupChanged; }
|
get { return m_hasGroupChanged; }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public bool TemporaryInstance = false;
|
||||||
|
|
||||||
private bool m_groupContainsForeignPrims = false;
|
private bool m_groupContainsForeignPrims = false;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -3294,9 +3296,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
|
|
||||||
// Now that we've aquired all of the old SOG's parts, remove the old SOG from the scene.
|
// Now that we've aquired all of the old SOG's parts, remove the old SOG from the scene.
|
||||||
m_scene.UnlinkSceneObject(objectGroup, true);
|
m_scene.UnlinkSceneObject(objectGroup, true);
|
||||||
objectGroup.IsDeleted = true;
|
objectGroup.m_parts.Clear(); // do not dispose the parts moved to new group
|
||||||
|
objectGroup.Dispose();
|
||||||
objectGroup.m_parts.Clear();
|
|
||||||
|
|
||||||
// Can't do this yet since backup still makes use of the root part without any synchronization
|
// Can't do this yet since backup still makes use of the root part without any synchronization
|
||||||
// objectGroup.m_rootPart = null;
|
// objectGroup.m_rootPart = null;
|
||||||
|
|
|
@ -420,6 +420,8 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
m_log.ErrorFormat("[UUID GATHERER]: Failed to get part - {0}", e);
|
m_log.ErrorFormat("[UUID GATHERER]: Failed to get part - {0}", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if(sceneObject.TemporaryInstance)
|
||||||
|
sceneObject.Dispose();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
@ -782,14 +784,20 @@ namespace OpenSim.Region.Framework.Scenes
|
||||||
if (CoalescedSceneObjectsSerializer.TryFromXml(xml, out coa))
|
if (CoalescedSceneObjectsSerializer.TryFromXml(xml, out coa))
|
||||||
{
|
{
|
||||||
foreach (SceneObjectGroup sog in coa.Objects)
|
foreach (SceneObjectGroup sog in coa.Objects)
|
||||||
|
{
|
||||||
|
sog.TemporaryInstance = true;
|
||||||
AddForInspection(sog);
|
AddForInspection(sog);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
SceneObjectGroup sog = SceneObjectSerializer.FromOriginalXmlFormat(xml);
|
SceneObjectGroup sog = SceneObjectSerializer.FromOriginalXmlFormat(xml);
|
||||||
|
|
||||||
if (null != sog)
|
if (null != sog)
|
||||||
|
{
|
||||||
|
sog.TemporaryInstance = true;
|
||||||
AddForInspection(sog);
|
AddForInspection(sog);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue