Allow Megaregions to start properly after an unclean shutdown

0.7-release
Melanie 2010-07-17 07:19:58 +01:00
parent 5182b9fcd2
commit 4e537a5a86
2 changed files with 4 additions and 1 deletions

View File

@ -136,6 +136,7 @@ namespace OpenSim.Region.Framework.Scenes
protected SceneCommunicationService m_sceneGridService; protected SceneCommunicationService m_sceneGridService;
public bool LoginsDisabled = true; public bool LoginsDisabled = true;
public bool LoadingPrims = false;
public new float TimeDilation public new float TimeDilation
{ {
@ -1879,6 +1880,7 @@ namespace OpenSim.Region.Framework.Scenes
/// </summary> /// </summary>
public virtual void LoadPrimsFromStorage(UUID regionID) public virtual void LoadPrimsFromStorage(UUID regionID)
{ {
LoadingPrims = true;
m_log.Info("[SCENE]: Loading objects from datastore"); m_log.Info("[SCENE]: Loading objects from datastore");
List<SceneObjectGroup> PrimsFromDB = m_storageManager.DataStore.LoadObjects(regionID); List<SceneObjectGroup> PrimsFromDB = m_storageManager.DataStore.LoadObjects(regionID);
@ -1902,6 +1904,7 @@ namespace OpenSim.Region.Framework.Scenes
} }
m_log.Info("[SCENE]: Loaded " + PrimsFromDB.Count.ToString() + " SceneObject(s)"); m_log.Info("[SCENE]: Loaded " + PrimsFromDB.Count.ToString() + " SceneObject(s)");
LoadingPrims = false;
} }

View File

@ -294,7 +294,7 @@ namespace OpenSim.Region.Framework.Scenes
if ((m_scene.TestBorderCross(val - Vector3.UnitX, Cardinals.E) || m_scene.TestBorderCross(val + Vector3.UnitX, Cardinals.W) if ((m_scene.TestBorderCross(val - Vector3.UnitX, Cardinals.E) || m_scene.TestBorderCross(val + Vector3.UnitX, Cardinals.W)
|| m_scene.TestBorderCross(val - Vector3.UnitY, Cardinals.N) || m_scene.TestBorderCross(val + Vector3.UnitY, Cardinals.S)) || m_scene.TestBorderCross(val - Vector3.UnitY, Cardinals.N) || m_scene.TestBorderCross(val + Vector3.UnitY, Cardinals.S))
&& !IsAttachmentCheckFull()) && !IsAttachmentCheckFull() && (!m_scene.LoadingPrims))
{ {
m_scene.CrossPrimGroupIntoNewRegion(val, this, true); m_scene.CrossPrimGroupIntoNewRegion(val, this, true);
} }