diff options
Diffstat (limited to 'OpenSim/Region/Framework/Scenes')
-rw-r--r-- | OpenSim/Region/Framework/Scenes/EventManager.cs | 2 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/Scene.cs | 9 | ||||
-rw-r--r-- | OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | 2 |
3 files changed, 11 insertions, 2 deletions
diff --git a/OpenSim/Region/Framework/Scenes/EventManager.cs b/OpenSim/Region/Framework/Scenes/EventManager.cs index e2414eb..8691b91 100644 --- a/OpenSim/Region/Framework/Scenes/EventManager.cs +++ b/OpenSim/Region/Framework/Scenes/EventManager.cs | |||
@@ -2947,6 +2947,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2947 | { | 2947 | { |
2948 | foreach (Action<Scene> d in handler.GetInvocationList()) | 2948 | foreach (Action<Scene> d in handler.GetInvocationList()) |
2949 | { | 2949 | { |
2950 | m_log.InfoFormat("[EVENT MANAGER]: TriggerSceneShuttingDown invoque {0}", d.Method.Name.ToString()); | ||
2950 | try | 2951 | try |
2951 | { | 2952 | { |
2952 | d(s); | 2953 | d(s); |
@@ -2959,6 +2960,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
2959 | } | 2960 | } |
2960 | } | 2961 | } |
2961 | } | 2962 | } |
2963 | m_log.Info("[EVENT MANAGER]: TriggerSceneShuttingDown done"); | ||
2962 | } | 2964 | } |
2963 | 2965 | ||
2964 | public void TriggerOnRegionStarted(Scene scene) | 2966 | public void TriggerOnRegionStarted(Scene scene) |
diff --git a/OpenSim/Region/Framework/Scenes/Scene.cs b/OpenSim/Region/Framework/Scenes/Scene.cs index 4282b46..2543333 100644 --- a/OpenSim/Region/Framework/Scenes/Scene.cs +++ b/OpenSim/Region/Framework/Scenes/Scene.cs | |||
@@ -1335,9 +1335,11 @@ namespace OpenSim.Region.Framework.Scenes | |||
1335 | // Stop all client threads. | 1335 | // Stop all client threads. |
1336 | ForEachScenePresence(delegate(ScenePresence avatar) { avatar.ControllingClient.Close(); }); | 1336 | ForEachScenePresence(delegate(ScenePresence avatar) { avatar.ControllingClient.Close(); }); |
1337 | 1337 | ||
1338 | m_log.Debug("[SCENE]: Persisting changed objects"); | 1338 | m_log.Debug("[SCENE]: TriggerSceneShuttingDown"); |
1339 | EventManager.TriggerSceneShuttingDown(this); | 1339 | EventManager.TriggerSceneShuttingDown(this); |
1340 | 1340 | ||
1341 | m_log.Debug("[SCENE]: Persisting changed objects"); | ||
1342 | |||
1341 | EntityBase[] entities = GetEntities(); | 1343 | EntityBase[] entities = GetEntities(); |
1342 | foreach (EntityBase entity in entities) | 1344 | foreach (EntityBase entity in entities) |
1343 | { | 1345 | { |
@@ -1347,6 +1349,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1347 | } | 1349 | } |
1348 | } | 1350 | } |
1349 | 1351 | ||
1352 | m_log.Debug("[SCENE]: Graph close"); | ||
1350 | m_sceneGraph.Close(); | 1353 | m_sceneGraph.Close(); |
1351 | 1354 | ||
1352 | if (!GridService.DeregisterRegion(RegionInfo.RegionID)) | 1355 | if (!GridService.DeregisterRegion(RegionInfo.RegionID)) |
@@ -1359,6 +1362,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
1359 | // attempt to reference a null or disposed physics scene. | 1362 | // attempt to reference a null or disposed physics scene. |
1360 | if (PhysicsScene != null) | 1363 | if (PhysicsScene != null) |
1361 | { | 1364 | { |
1365 | m_log.Debug("[SCENE]: Dispose Physics"); | ||
1362 | PhysicsScene phys = PhysicsScene; | 1366 | PhysicsScene phys = PhysicsScene; |
1363 | // remove the physics engine from both Scene and SceneGraph | 1367 | // remove the physics engine from both Scene and SceneGraph |
1364 | PhysicsScene = null; | 1368 | PhysicsScene = null; |
@@ -1401,6 +1405,9 @@ namespace OpenSim.Region.Framework.Scenes | |||
1401 | } | 1405 | } |
1402 | // m_lastUpdate = Util.EnvironmentTickCount(); | 1406 | // m_lastUpdate = Util.EnvironmentTickCount(); |
1403 | 1407 | ||
1408 | // m_sceneGraph.PreparePhysicsSimulation(); | ||
1409 | |||
1410 | |||
1404 | m_heartbeatThread | 1411 | m_heartbeatThread |
1405 | = Watchdog.StartThread( | 1412 | = Watchdog.StartThread( |
1406 | Heartbeat, string.Format("Heartbeat ({0})", RegionInfo.RegionName), ThreadPriority.Normal, false, false); | 1413 | Heartbeat, string.Format("Heartbeat ({0})", RegionInfo.RegionName), ThreadPriority.Normal, false, false); |
diff --git a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs index 5714fdd..2191cfa 100644 --- a/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs +++ b/OpenSim/Region/Framework/Scenes/SceneObjectPart.cs | |||
@@ -813,7 +813,7 @@ namespace OpenSim.Region.Framework.Scenes | |||
813 | actor.Orientation = GetWorldRotation(); | 813 | actor.Orientation = GetWorldRotation(); |
814 | 814 | ||
815 | // Tell the physics engines that this prim changed. | 815 | // Tell the physics engines that this prim changed. |
816 | if (ParentGroup.Scene != null) | 816 | if (ParentGroup.Scene != null && ParentGroup.Scene.PhysicsScene != null) |
817 | ParentGroup.Scene.PhysicsScene.AddPhysicsActorTaint(actor); | 817 | ParentGroup.Scene.PhysicsScene.AddPhysicsActorTaint(actor); |
818 | } | 818 | } |
819 | 819 | ||