aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs
diff options
context:
space:
mode:
authorMelanie2012-12-28 08:32:34 +0000
committerMelanie2012-12-28 08:32:34 +0000
commit3ab1bd04031ca0bc1039e4e1d267ea19d0017430 (patch)
tree3f2417f3b96e151642158d29d1982dee2bd850a8 /OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs
parentMerge branch 'master' into careminster (diff)
parentBulletSim: correct collision mask definition for linkset children. (diff)
downloadopensim-SC-3ab1bd04031ca0bc1039e4e1d267ea19d0017430.zip
opensim-SC-3ab1bd04031ca0bc1039e4e1d267ea19d0017430.tar.gz
opensim-SC-3ab1bd04031ca0bc1039e4e1d267ea19d0017430.tar.bz2
opensim-SC-3ab1bd04031ca0bc1039e4e1d267ea19d0017430.tar.xz
Merge branch 'master' into careminster
Conflicts: OpenSim/Region/Framework/Scenes/ScenePresence.cs
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs')
-rw-r--r--OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs b/OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs
index 3fde57b..0bdfbe3 100644
--- a/OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSDynamics.cs
@@ -573,6 +573,9 @@ namespace OpenSim.Region.Physics.BulletSPlugin
573 BulletSimAPI.SetMassProps2(Prim.PhysBody.ptr, m_vehicleMass, localInertia); 573 BulletSimAPI.SetMassProps2(Prim.PhysBody.ptr, m_vehicleMass, localInertia);
574 BulletSimAPI.UpdateInertiaTensor2(Prim.PhysBody.ptr); 574 BulletSimAPI.UpdateInertiaTensor2(Prim.PhysBody.ptr);
575 575
576 Vector3 grav = PhysicsScene.DefaultGravity * (1f - Prim.Buoyancy);
577 BulletSimAPI.SetGravity2(Prim.PhysBody.ptr, grav);
578
576 VDetailLog("{0},BSDynamics.Refresh,mass={1},frict={2},inert={3},aDamp={4}", 579 VDetailLog("{0},BSDynamics.Refresh,mass={1},frict={2},inert={3},aDamp={4}",
577 Prim.LocalID, m_vehicleMass, friction, localInertia, angularDamping); 580 Prim.LocalID, m_vehicleMass, friction, localInertia, angularDamping);
578 } 581 }
@@ -819,6 +822,9 @@ namespace OpenSim.Region.Physics.BulletSPlugin
819 { 822 {
820 if (!IsActive) return; 823 if (!IsActive) return;
821 824
825 if (PhysicsScene.VehiclePhysicalLoggingEnabled)
826 BulletSimAPI.DumpRigidBody2(PhysicsScene.World.ptr, Prim.PhysBody.ptr);
827
822 ForgetKnownVehicleProperties(); 828 ForgetKnownVehicleProperties();
823 829
824 MoveLinear(pTimestep); 830 MoveLinear(pTimestep);
@@ -833,6 +839,9 @@ namespace OpenSim.Region.Physics.BulletSPlugin
833 // for the physics engine to note the changes so an UpdateProperties event will happen. 839 // for the physics engine to note the changes so an UpdateProperties event will happen.
834 PushKnownChanged(); 840 PushKnownChanged();
835 841
842 if (PhysicsScene.VehiclePhysicalLoggingEnabled)
843 BulletSimAPI.DumpRigidBody2(PhysicsScene.World.ptr, Prim.PhysBody.ptr);
844
836 VDetailLog("{0},BSDynamics.Step,done,pos={1},force={2},velocity={3},angvel={4}", 845 VDetailLog("{0},BSDynamics.Step,done,pos={1},force={2},velocity={3},angvel={4}",
837 Prim.LocalID, VehiclePosition, Prim.Force, VehicleVelocity, VehicleRotationalVelocity); 846 Prim.LocalID, VehiclePosition, Prim.Force, VehicleVelocity, VehicleRotationalVelocity);
838 } 847 }