aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/UbitOdePlugin
diff options
context:
space:
mode:
authorUbitUmarov2012-04-24 23:13:57 +0100
committerUbitUmarov2012-04-24 23:13:57 +0100
commit3da613adf5c803edfcca41f260017b96b1d80fb5 (patch)
tree4fb2c7213c562fd764a3cc51477e806ea8538198 /OpenSim/Region/Physics/UbitOdePlugin
parentSOG bug fix in UI object changes (diff)
downloadopensim-SC-3da613adf5c803edfcca41f260017b96b1d80fb5.zip
opensim-SC-3da613adf5c803edfcca41f260017b96b1d80fb5.tar.gz
opensim-SC-3da613adf5c803edfcca41f260017b96b1d80fb5.tar.bz2
opensim-SC-3da613adf5c803edfcca41f260017b96b1d80fb5.tar.xz
fix chODE loosing some part positions when doing isPhysical false
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Physics/UbitOdePlugin/ODEPrim.cs8
1 files changed, 3 insertions, 5 deletions
diff --git a/OpenSim/Region/Physics/UbitOdePlugin/ODEPrim.cs b/OpenSim/Region/Physics/UbitOdePlugin/ODEPrim.cs
index dc6c18d..2d587ab 100644
--- a/OpenSim/Region/Physics/UbitOdePlugin/ODEPrim.cs
+++ b/OpenSim/Region/Physics/UbitOdePlugin/ODEPrim.cs
@@ -2467,15 +2467,14 @@ namespace OpenSim.Region.Physics.OdePlugin
2467 { 2467 {
2468 if (prim_geom != IntPtr.Zero) 2468 if (prim_geom != IntPtr.Zero)
2469 { 2469 {
2470 d.Quaternion qtmp = new d.Quaternion { }; 2470 d.Quaternion qtmp;
2471 d.GeomCopyQuaternion(prim_geom, out qtmp); 2471 d.GeomCopyQuaternion(prim_geom, out qtmp);
2472 _orientation.W = qtmp.W; 2472 _orientation.W = qtmp.W;
2473 _orientation.X = qtmp.X; 2473 _orientation.X = qtmp.X;
2474 _orientation.Y = qtmp.Y; 2474 _orientation.Y = qtmp.Y;
2475 _orientation.Z = qtmp.Z; 2475 _orientation.Z = qtmp.Z;
2476 2476
2477 d.Vector3 lpos; 2477 d.Vector3 lpos = d.GeomGetPosition(prim_geom);
2478 d.GeomCopyPosition(prim_geom, out lpos);
2479 _position.X = lpos.X; 2478 _position.X = lpos.X;
2480 _position.Y = lpos.Y; 2479 _position.Y = lpos.Y;
2481 _position.Z = lpos.Z; 2480 _position.Z = lpos.Z;
@@ -3565,8 +3564,7 @@ namespace OpenSim.Region.Physics.OdePlugin
3565 { 3564 {
3566 bool lastZeroFlag = _zeroFlag; 3565 bool lastZeroFlag = _zeroFlag;
3567 3566
3568 d.Vector3 lpos; 3567 d.Vector3 lpos = d.GeomGetPosition(prim_geom);
3569 d.GeomCopyPosition(prim_geom, out lpos); // root position that is seem by rest of simulator
3570 3568
3571 d.Quaternion ori; 3569 d.Quaternion ori;
3572 d.GeomCopyQuaternion(prim_geom, out ori); 3570 d.GeomCopyQuaternion(prim_geom, out ori);