aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Framework/Scenes/Scene.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Framework/Scenes/Scene.cs')
-rw-r--r--OpenSim/Region/Framework/Scenes/Scene.cs26
1 files changed, 19 insertions, 7 deletions
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs
index a22fb5f..a8bab5a 100644
--- a/OpenSim/Region/Framework/Scenes/Scene.cs
+++ b/OpenSim/Region/Framework/Scenes/Scene.cs
@@ -881,6 +881,15 @@ namespace OpenSim.Region.Framework.Scenes
881 /// <param name="seconds">float indicating duration before restart.</param> 881 /// <param name="seconds">float indicating duration before restart.</param>
882 public virtual void Restart(float seconds) 882 public virtual void Restart(float seconds)
883 { 883 {
884 Restart(seconds, true);
885 }
886
887 /// <summary>
888 /// Given float seconds, this will restart the region. showDialog will optionally alert the users.
889 /// </summary>
890 /// <param name="seconds">float indicating duration before restart.</param>
891 public virtual void Restart(float seconds, bool showDialog)
892 {
884 // notifications are done in 15 second increments 893 // notifications are done in 15 second increments
885 // so .. if the number of seconds is less then 15 seconds, it's not really a restart request 894 // so .. if the number of seconds is less then 15 seconds, it's not really a restart request
886 // It's a 'Cancel restart' request. 895 // It's a 'Cancel restart' request.
@@ -901,8 +910,11 @@ namespace OpenSim.Region.Framework.Scenes
901 m_restartTimer.Elapsed += new ElapsedEventHandler(RestartTimer_Elapsed); 910 m_restartTimer.Elapsed += new ElapsedEventHandler(RestartTimer_Elapsed);
902 m_log.Info("[REGION]: Restarting Region in " + (seconds / 60) + " minutes"); 911 m_log.Info("[REGION]: Restarting Region in " + (seconds / 60) + " minutes");
903 m_restartTimer.Start(); 912 m_restartTimer.Start();
904 m_dialogModule.SendNotificationToUsersInRegion( 913 if (showDialog)
905 UUID.Random(), String.Empty, RegionInfo.RegionName + ": Restarting in 2 Minutes"); 914 {
915 m_dialogModule.SendNotificationToUsersInRegion(
916 UUID.Random(), String.Empty, RegionInfo.RegionName + ": Restarting in " + (seconds / 60).ToString() + " Minutes");
917 }
906 } 918 }
907 } 919 }
908 920
@@ -1173,16 +1185,16 @@ namespace OpenSim.Region.Framework.Scenes
1173 // Check if any objects have reached their targets 1185 // Check if any objects have reached their targets
1174 CheckAtTargets(); 1186 CheckAtTargets();
1175 1187
1176 // Update SceneObjectGroups that have scheduled themselves for updates
1177 // Objects queue their updates onto all scene presences
1178 if (m_frame % m_update_objects == 0)
1179 m_sceneGraph.UpdateObjectGroups();
1180
1181 // Run through all ScenePresences looking for updates 1188 // Run through all ScenePresences looking for updates
1182 // Presence updates and queued object updates for each presence are sent to clients 1189 // Presence updates and queued object updates for each presence are sent to clients
1183 if (m_frame % m_update_presences == 0) 1190 if (m_frame % m_update_presences == 0)
1184 m_sceneGraph.UpdatePresences(); 1191 m_sceneGraph.UpdatePresences();
1185 1192
1193 // Update SceneObjectGroups that have scheduled themselves for updates
1194 // Objects queue their updates onto all scene presences
1195 if (m_frame % m_update_objects == 0)
1196 m_sceneGraph.UpdateObjectGroups();
1197
1186 int tmpPhysicsMS2 = Util.EnvironmentTickCount(); 1198 int tmpPhysicsMS2 = Util.EnvironmentTickCount();
1187 if ((m_frame % m_update_physics == 0) && m_physics_enabled) 1199 if ((m_frame % m_update_physics == 0) && m_physics_enabled)
1188 m_sceneGraph.UpdatePreparePhysics(); 1200 m_sceneGraph.UpdatePreparePhysics();