aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Physics/OdePlugin/ODEPrim.cs24
1 files changed, 13 insertions, 11 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
index 312fd9c..50087a5 100644
--- a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
+++ b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs
@@ -1073,22 +1073,24 @@ namespace OpenSim.Region.Physics.OdePlugin
1073 } 1073 }
1074 private void changevelocity(float timestep) 1074 private void changevelocity(float timestep)
1075 { 1075 {
1076 while (ode.lockquery()) 1076 lock (ode)
1077 {
1078 }
1079 ode.dlock(_parent_scene.world);
1080
1081 System.Threading.Thread.Sleep(20);
1082 if (IsPhysical)
1083 { 1077 {
1084 if (Body != (IntPtr)0) 1078 while (ode.lockquery())
1085 { 1079 {
1086 d.BodySetLinearVel(Body, m_taintVelocity.X, m_taintVelocity.Y, m_taintVelocity.Z);
1087 } 1080 }
1088 } 1081 ode.dlock(_parent_scene.world);
1089 1082
1090 ode.dunlock(_parent_scene.world); 1083 System.Threading.Thread.Sleep(20);
1084 if (IsPhysical)
1085 {
1086 if (Body != (IntPtr)0)
1087 {
1088 d.BodySetLinearVel(Body, m_taintVelocity.X, m_taintVelocity.Y, m_taintVelocity.Z);
1089 }
1090 }
1091 1091
1092 ode.dunlock(_parent_scene.world);
1093 }
1092 //resetCollisionAccounting(); 1094 //resetCollisionAccounting();
1093 m_taintVelocity = PhysicsVector.Zero; 1095 m_taintVelocity = PhysicsVector.Zero;
1094 } 1096 }