aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/Physics')
-rw-r--r--OpenSim/Region/Physics/OdePlugin/OdeScene.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
index 32e81e2..0db936f 100644
--- a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
+++ b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs
@@ -489,6 +489,8 @@ namespace OpenSim.Region.Physics.OdePlugin
489 /// </summary> 489 /// </summary>
490 internal Object OdeLock = new Object(); 490 internal Object OdeLock = new Object();
491 491
492 private bool _worldInitialized = false;
493
492 public IMesher mesher; 494 public IMesher mesher;
493 495
494 private IConfigSource m_config; 496 private IConfigSource m_config;
@@ -875,6 +877,8 @@ namespace OpenSim.Region.Physics.OdePlugin
875 staticPrimspace[i, j] = IntPtr.Zero; 877 staticPrimspace[i, j] = IntPtr.Zero;
876 } 878 }
877 } 879 }
880
881 _worldInitialized = true;
878 } 882 }
879 883
880// internal void waitForSpaceUnlock(IntPtr space) 884// internal void waitForSpaceUnlock(IntPtr space)
@@ -2896,6 +2900,8 @@ namespace OpenSim.Region.Physics.OdePlugin
2896 /// <returns>The number of frames simulated over that period.</returns> 2900 /// <returns>The number of frames simulated over that period.</returns>
2897 public override float Simulate(float timeStep) 2901 public override float Simulate(float timeStep)
2898 { 2902 {
2903 if (!_worldInitialized) return 11f;
2904
2899 int startFrameTick = CollectStats ? Util.EnvironmentTickCount() : 0; 2905 int startFrameTick = CollectStats ? Util.EnvironmentTickCount() : 0;
2900 int tempTick = 0, tempTick2 = 0; 2906 int tempTick = 0, tempTick2 = 0;
2901 2907
@@ -4017,6 +4023,8 @@ namespace OpenSim.Region.Physics.OdePlugin
4017 4023
4018 public override void Dispose() 4024 public override void Dispose()
4019 { 4025 {
4026 _worldInitialized = false;
4027
4020 m_rayCastManager.Dispose(); 4028 m_rayCastManager.Dispose();
4021 m_rayCastManager = null; 4029 m_rayCastManager = null;
4022 4030
@@ -4037,6 +4045,7 @@ namespace OpenSim.Region.Physics.OdePlugin
4037 d.WorldDestroy(world); 4045 d.WorldDestroy(world);
4038 //d.CloseODE(); 4046 //d.CloseODE();
4039 } 4047 }
4048
4040 } 4049 }
4041 4050
4042 public override Dictionary<uint, float> GetTopColliders() 4051 public override Dictionary<uint, float> GetTopColliders()