diff options
author | Melanie | 2011-05-24 03:37:25 +0200 |
---|---|---|
committer | Melanie | 2011-05-24 04:03:51 +0100 |
commit | 28c25d8477ff3cfd5751da1454fcd4cc33815a5e (patch) | |
tree | 51b42c26237deaaf4c0b59a51da857a2f47fd2c9 /OpenSim/Region/Framework/Scenes | |
parent | Create a method to force the script engine to save state from outside (diff) | |
download | opensim-SC_OLD-28c25d8477ff3cfd5751da1454fcd4cc33815a5e.zip opensim-SC_OLD-28c25d8477ff3cfd5751da1454fcd4cc33815a5e.tar.gz opensim-SC_OLD-28c25d8477ff3cfd5751da1454fcd4cc33815a5e.tar.bz2 opensim-SC_OLD-28c25d8477ff3cfd5751da1454fcd4cc33815a5e.tar.xz |
Allow disabling the legacy backup mechanism to avoid the object clone if
backup is not used.
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 9 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | 2 |
2 files changed, 10 insertions, 1 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index eabc9a6..4aae13c 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -204,6 +204,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
204 | 204 | ||
205 | private Timer m_mapGenerationTimer = new Timer(); | 205 | private Timer m_mapGenerationTimer = new Timer(); |
206 | private bool m_generateMaptiles; | 206 | private bool m_generateMaptiles; |
207 | private bool m_useBackup = true; | ||
207 | 208 | ||
208 | // private Dictionary<UUID, string[]> m_UserNamesCache = new Dictionary<UUID, string[]>(); | 209 | // private Dictionary<UUID, string[]> m_UserNamesCache = new Dictionary<UUID, string[]>(); |
209 | 210 | ||
@@ -459,6 +460,11 @@ namespace OpenSim.Region.Framework.Scenes | |||
459 | get { return m_sceneGraph; } | 460 | get { return m_sceneGraph; } |
460 | } | 461 | } |
461 | 462 | ||
463 | public bool UseBackup | ||
464 | { | ||
465 | get { return m_useBackup; } | ||
466 | } | ||
467 | |||
462 | // an instance to the physics plugin's Scene object. | 468 | // an instance to the physics plugin's Scene object. |
463 | public PhysicsScene PhysicsScene | 469 | public PhysicsScene PhysicsScene |
464 | { | 470 | { |
@@ -647,6 +653,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
647 | IConfig startupConfig = m_config.Configs["Startup"]; | 653 | IConfig startupConfig = m_config.Configs["Startup"]; |
648 | 654 | ||
649 | m_defaultDrawDistance = startupConfig.GetFloat("DefaultDrawDistance",m_defaultDrawDistance); | 655 | m_defaultDrawDistance = startupConfig.GetFloat("DefaultDrawDistance",m_defaultDrawDistance); |
656 | m_useBackup = startupConfig.GetBoolean("UseSceneBackup", m_useBackup); | ||
657 | if (!m_useBackup) | ||
658 | m_log.InfoFormat("[SCENE]: Backup has been disabled for {0}", RegionInfo.RegionName); | ||
650 | 659 | ||
651 | //Animation states | 660 | //Animation states |
652 | m_useFlySlow = startupConfig.GetBoolean("enableflyslow", false); | 661 | m_useFlySlow = startupConfig.GetBoolean("enableflyslow", false); |
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs index 19a9506..9b9374b 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectGroup.cs | |||
@@ -1335,7 +1335,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1335 | } | 1335 | } |
1336 | } | 1336 | } |
1337 | 1337 | ||
1338 | if (HasGroupChanged) | 1338 | if (m_scene.UseBackup && HasGroupChanged) |
1339 | { | 1339 | { |
1340 | // don't backup while it's selected or you're asking for changes mid stream. | 1340 | // don't backup while it's selected or you're asking for changes mid stream. |
1341 | if (isTimeToPersist() || forcedBackup) | 1341 | if (isTimeToPersist() || forcedBackup) |