aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
diff options
context:
space:
mode:
authorRobert Adams2013-02-07 17:05:40 -0800
committerRobert Adams2013-02-07 17:13:28 -0800
commit913965256fecd4e25e06fe374fa5d8b8712a3b15 (patch)
treeb82cbbe7d6e3ec56a5e0cd8dbcd94328f66efe64 /OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs
parentBulletSim: fix exceptions caused by setting physical properties before the pr... (diff)
downloadopensim-SC_OLD-913965256fecd4e25e06fe374fa5d8b8712a3b15.zip
opensim-SC_OLD-913965256fecd4e25e06fe374fa5d8b8712a3b15.tar.gz
opensim-SC_OLD-913965256fecd4e25e06fe374fa5d8b8712a3b15.tar.bz2
opensim-SC_OLD-913965256fecd4e25e06fe374fa5d8b8712a3b15.tar.xz
BulletSim: Adapt BulletSim to the newer physical properties. Viewer
dialog setting of friction, restitution, ... working.
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs')
-rwxr-xr-xOpenSim/Region/Physics/BulletSPlugin/BSPhysObject.cs4
1 files changed, 3 insertions, 1 deletions
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
79 TypeName = typeName; 79 TypeName = typeName;
80 80
81 // Initialize variables kept in base. 81 // Initialize variables kept in base.
82 GravityModifier = 1.0f; 82 GravModifier = 1.0f;
83 Gravity = new OMV.Vector3(0f, 0f, BSParam.Gravity); 83 Gravity = new OMV.Vector3(0f, 0f, BSParam.Gravity);
84 84
85 // We don't have any physical representation yet. 85 // We don't have any physical representation yet.
@@ -170,6 +170,8 @@ public abstract class BSPhysObject : PhysicsActor
170 public override void SetMaterial(int material) 170 public override void SetMaterial(int material)
171 { 171 {
172 Material = (MaterialAttributes.Material)material; 172 Material = (MaterialAttributes.Material)material;
173
174 // Setting the material sets the material attributes also.
173 MaterialAttributes matAttrib = BSMaterials.GetAttributes(Material, false); 175 MaterialAttributes matAttrib = BSMaterials.GetAttributes(Material, false);
174 Friction = matAttrib.friction; 176 Friction = matAttrib.friction;
175 Restitution = matAttrib.restitution; 177 Restitution = matAttrib.restitution;