From 913965256fecd4e25e06fe374fa5d8b8712a3b15 Mon Sep 17 00:00:00 2001 From: Robert Adams Date: Thu, 7 Feb 2013 17:05:40 -0800 Subject: BulletSim: Adapt BulletSim to the newer physical properties. Viewer dialog setting of friction, restitution, ... working. --- OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs') diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs index 0b35f3a..0d8bb03 100755 --- a/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs @@ -79,7 +79,7 @@ public abstract class BSPhysObject : PhysicsActor TypeName = typeName; // Initialize variables kept in base. - GravityModifier = 1.0f; + GravModifier = 1.0f; Gravity = new OMV.Vector3(0f, 0f, BSParam.Gravity); // We don't have any physical representation yet. @@ -170,6 +170,8 @@ public abstract class BSPhysObject : PhysicsActor public override void SetMaterial(int material) { Material = (MaterialAttributes.Material)material; + + // Setting the material sets the material attributes also. MaterialAttributes matAttrib = BSMaterials.GetAttributes(Material, false); Friction = matAttrib.friction; Restitution = matAttrib.restitution; -- cgit v1.1