aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
diff options
context:
space:
mode:
authorJustin Clark-Casey (justincc)2012-12-13 01:12:12 +0000
committerJustin Clark-Casey (justincc)2012-12-13 01:12:12 +0000
commit8e8da20af2bf011098ebf68aae80d92da56dae65 (patch)
treeff368505aa31f0df0fe83d9990ad3c08abb5e02e /OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
parentFix sounds so that they play from inventory after teleport rather than only o... (diff)
parentBulletSim: fix problem of avatar's floating off the ground after unsitting. R... (diff)
downloadopensim-SC-8e8da20af2bf011098ebf68aae80d92da56dae65.zip
opensim-SC-8e8da20af2bf011098ebf68aae80d92da56dae65.tar.gz
opensim-SC-8e8da20af2bf011098ebf68aae80d92da56dae65.tar.bz2
opensim-SC-8e8da20af2bf011098ebf68aae80d92da56dae65.tar.xz
Merge branch 'master' of ssh://opensimulator.org/var/git/opensim
Diffstat (limited to 'OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs')
-rw-r--r--OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs8
1 files changed, 2 insertions, 6 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs b/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
index 35d22c0..19c29cc 100644
--- a/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
+++ b/OpenSim/Region/Physics/BulletSPlugin/BSPrim.cs
@@ -45,7 +45,6 @@ public sealed class BSPrim : BSPhysObject
45 private static readonly string LogHeader = "[BULLETS PRIM]"; 45 private static readonly string LogHeader = "[BULLETS PRIM]";
46 46
47 // _size is what the user passed. Scale is what we pass to the physics engine with the mesh. 47 // _size is what the user passed. Scale is what we pass to the physics engine with the mesh.
48 // Often Scale is unity because the meshmerizer will apply _size when creating the mesh.
49 private OMV.Vector3 _size; // the multiplier for each mesh dimension as passed by the user 48 private OMV.Vector3 _size; // the multiplier for each mesh dimension as passed by the user
50 49
51 private bool _grabbed; 50 private bool _grabbed;
@@ -93,7 +92,7 @@ public sealed class BSPrim : BSPhysObject
93 _physicsActorType = (int)ActorTypes.Prim; 92 _physicsActorType = (int)ActorTypes.Prim;
94 _position = pos; 93 _position = pos;
95 _size = size; 94 _size = size;
96 Scale = size; // the scale will be set by CreateGeom depending on object type 95 Scale = size; // prims are the size the user wants them to be (different for BSCharactes).
97 _orientation = rotation; 96 _orientation = rotation;
98 _buoyancy = 1f; 97 _buoyancy = 1f;
99 _velocity = OMV.Vector3.Zero; 98 _velocity = OMV.Vector3.Zero;
@@ -159,12 +158,10 @@ public sealed class BSPrim : BSPhysObject
159 // We presume the scale and size are the same. If scale must be changed for 158 // We presume the scale and size are the same. If scale must be changed for
160 // the physical shape, that is done when the geometry is built. 159 // the physical shape, that is done when the geometry is built.
161 _size = value; 160 _size = value;
161 Scale = _size;
162 ForceBodyShapeRebuild(false); 162 ForceBodyShapeRebuild(false);
163 } 163 }
164 } 164 }
165 // Scale is what we set in the physics engine. It is different than 'size' in that
166 // 'size' can be encorporated into the mesh. In that case, the scale is <1,1,1>.
167 public override OMV.Vector3 Scale { get; set; }
168 165
169 public override PrimitiveBaseShape Shape { 166 public override PrimitiveBaseShape Shape {
170 set { 167 set {
@@ -1369,7 +1366,6 @@ public sealed class BSPrim : BSPhysObject
1369 // Create the correct physical representation for this type of object. 1366 // Create the correct physical representation for this type of object.
1370 // Updates PhysBody and PhysShape with the new information. 1367 // Updates PhysBody and PhysShape with the new information.
1371 // Ignore 'forceRebuild'. This routine makes the right choices and changes of necessary. 1368 // Ignore 'forceRebuild'. This routine makes the right choices and changes of necessary.
1372 // Returns 'true' if either the body or the shape was changed.
1373 PhysicsScene.Shapes.GetBodyAndShape(false, PhysicsScene.World, this, null, delegate(BulletBody dBody) 1369 PhysicsScene.Shapes.GetBodyAndShape(false, PhysicsScene.World, this, null, delegate(BulletBody dBody)
1374 { 1370 {
1375 // Called if the current prim body is about to be destroyed. 1371 // Called if the current prim body is about to be destroyed.