diff options
author | Robert Adams | 2012-11-21 16:31:23 -0800 |
---|---|---|
committer | Robert Adams | 2012-11-21 16:43:53 -0800 |
commit | cbc7e7bf85bfd9e916146b0ae4a605996c24720b (patch) | |
tree | 9873174e8174ce230b2b0e8d30c490d0b79db745 /OpenSim/Region/Physics/BulletSPlugin/BSScene.cs | |
parent | BulletSim: Properly position mesh terrain on creation (fixes terrain not appe... (diff) | |
download | opensim-SC-cbc7e7bf85bfd9e916146b0ae4a605996c24720b.zip opensim-SC-cbc7e7bf85bfd9e916146b0ae4a605996c24720b.tar.gz opensim-SC-cbc7e7bf85bfd9e916146b0ae4a605996c24720b.tar.bz2 opensim-SC-cbc7e7bf85bfd9e916146b0ae4a605996c24720b.tar.xz |
BulletSim: Make avatar capsule so it is not circular.
Simple attempt to make avatars better shaped.
Replace parameter 'avatarCapsuleRadius' with 'avatarCapsuleWidth'
and 'avatarCapsuleDepth'.
More tweeking to avatar height calculation. A little better but
short avatar's feet are above the terrain and tall avatar's feet
are a little below the ground.
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Region/Physics/BulletSPlugin/BSScene.cs | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs b/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs index 0e73d04..27a78d1 100644 --- a/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs +++ b/OpenSim/Region/Physics/BulletSPlugin/BSScene.cs | |||
@@ -1185,14 +1185,18 @@ public sealed class BSScene : PhysicsScene, IPhysicsParameters | |||
1185 | (s,cf,p,v) => { s.m_params[0].avatarRestitution = cf.GetFloat(p, v); }, | 1185 | (s,cf,p,v) => { s.m_params[0].avatarRestitution = cf.GetFloat(p, v); }, |
1186 | (s) => { return s.m_params[0].avatarRestitution; }, | 1186 | (s) => { return s.m_params[0].avatarRestitution; }, |
1187 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarRestitution, p, l, v); } ), | 1187 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarRestitution, p, l, v); } ), |
1188 | new ParameterDefn("AvatarCapsuleRadius", "Radius of space around an avatar", | 1188 | new ParameterDefn("AvatarCapsuleWidth", "The distance between the sides of the avatar capsule", |
1189 | 0.37f, | 1189 | 0.6f, |
1190 | (s,cf,p,v) => { s.m_params[0].avatarCapsuleRadius = cf.GetFloat(p, v); }, | 1190 | (s,cf,p,v) => { s.m_params[0].avatarCapsuleWidth = cf.GetFloat(p, v); }, |
1191 | (s) => { return s.m_params[0].avatarCapsuleRadius; }, | 1191 | (s) => { return s.m_params[0].avatarCapsuleWidth; }, |
1192 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarCapsuleRadius, p, l, v); } ), | 1192 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarCapsuleWidth, p, l, v); } ), |
1193 | new ParameterDefn("AvatarCapsuleDepth", "The distance between the front and back of the avatar capsule", | ||
1194 | 0.45f, | ||
1195 | (s,cf,p,v) => { s.m_params[0].avatarCapsuleDepth = cf.GetFloat(p, v); }, | ||
1196 | (s) => { return s.m_params[0].avatarCapsuleDepth; }, | ||
1197 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarCapsuleDepth, p, l, v); } ), | ||
1193 | new ParameterDefn("AvatarCapsuleHeight", "Default height of space around avatar", | 1198 | new ParameterDefn("AvatarCapsuleHeight", "Default height of space around avatar", |
1194 | // 1.5f, | 1199 | 1.5f, |
1195 | 2.140599f, | ||
1196 | (s,cf,p,v) => { s.m_params[0].avatarCapsuleHeight = cf.GetFloat(p, v); }, | 1200 | (s,cf,p,v) => { s.m_params[0].avatarCapsuleHeight = cf.GetFloat(p, v); }, |
1197 | (s) => { return s.m_params[0].avatarCapsuleHeight; }, | 1201 | (s) => { return s.m_params[0].avatarCapsuleHeight; }, |
1198 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarCapsuleHeight, p, l, v); } ), | 1202 | (s,p,l,v) => { s.UpdateParameterObject(ref s.m_params[0].avatarCapsuleHeight, p, l, v); } ), |