aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs
diff options
context:
space:
mode:
authorUbitUmarov2017-01-05 19:32:57 +0000
committerUbitUmarov2017-01-05 19:32:57 +0000
commit254b26a7d51143d4e08229fa0b0fceabd76a41d0 (patch)
tree8ed65006e5dc04e69ceba67e31075a9e505e64f6 /OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs
parentMerge branch 'master' into httptests (diff)
parentMassive tab and trailing space cleanup (diff)
downloadopensim-SC-254b26a7d51143d4e08229fa0b0fceabd76a41d0.zip
opensim-SC-254b26a7d51143d4e08229fa0b0fceabd76a41d0.tar.gz
opensim-SC-254b26a7d51143d4e08229fa0b0fceabd76a41d0.tar.bz2
opensim-SC-254b26a7d51143d4e08229fa0b0fceabd76a41d0.tar.xz
fix merge
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs50
1 files changed, 25 insertions, 25 deletions
diff --git a/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs b/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs
index f7e1044..9cef3d5 100644
--- a/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs
+++ b/OpenSim/Region/PhysicsModules/ubOde/ODECharacter.cs
@@ -67,7 +67,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
67 StopERP3 = 7 + 512, 67 StopERP3 = 7 + 512,
68 StopCFM3 = 8 + 512 68 StopCFM3 = 8 + 512
69 } 69 }
70 70
71 public class OdeCharacter : PhysicsActor 71 public class OdeCharacter : PhysicsActor
72 { 72 {
73 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); 73 private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType);
@@ -121,7 +121,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
121 private float m_buoyancy = 0f; 121 private float m_buoyancy = 0f;
122 122
123 private bool m_freemove = false; 123 private bool m_freemove = false;
124 124
125// private string m_name = String.Empty; 125// private string m_name = String.Empty;
126 // other filter control 126 // other filter control
127 int m_colliderfilter = 0; 127 int m_colliderfilter = 0;
@@ -155,7 +155,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
155 public UUID m_uuid; 155 public UUID m_uuid;
156 public bool bad = false; 156 public bool bad = false;
157 157
158 float mu; 158 float mu;
159 159
160 // HoverHeight control 160 // HoverHeight control
161 private float m_PIDHoverHeight; 161 private float m_PIDHoverHeight;
@@ -218,7 +218,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
218 walkDivisor = walk_divisor; 218 walkDivisor = walk_divisor;
219 runDivisor = rundivisor; 219 runDivisor = rundivisor;
220 220
221 m_mass = m_density * m_size.X * m_size.Y * m_size.Z; ; // sure we have a default 221 m_mass = m_density * m_size.X * m_size.Y * m_size.Z; ; // sure we have a default
222 222
223 PID_D = basePID_D * m_mass * invtimeStep; 223 PID_D = basePID_D * m_mass * invtimeStep;
224 PID_P = basePID_P * m_mass * invtimeStep; 224 PID_P = basePID_P * m_mass * invtimeStep;
@@ -256,7 +256,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
256 256
257 public override uint LocalID 257 public override uint LocalID
258 { 258 {
259 get { return m_localID; } 259 get { return m_localID; }
260 set { m_localID = value; } 260 set { m_localID = value; }
261 } 261 }
262 262
@@ -508,7 +508,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
508 { 508 {
509 m_log.Warn("[PHYSICS]: Got a NaN AvatarSize from Scene on a Character"); 509 m_log.Warn("[PHYSICS]: Got a NaN AvatarSize from Scene on a Character");
510 } 510 }
511 511
512 } 512 }
513 /// <summary> 513 /// <summary>
514 /// This creates the Avatar's physical Surrogate at the position supplied 514 /// This creates the Avatar's physical Surrogate at the position supplied
@@ -636,7 +636,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
636 { 636 {
637 get 637 get
638 { 638 {
639 return m_targetVelocity; 639 return m_targetVelocity;
640 } 640 }
641 set 641 set
642 { 642 {
@@ -774,7 +774,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
774 774
775 PID_D = basePID_D * m_mass / _parent_scene.ODE_STEPSIZE; 775 PID_D = basePID_D * m_mass / _parent_scene.ODE_STEPSIZE;
776 PID_P = basePID_P * m_mass / _parent_scene.ODE_STEPSIZE; 776 PID_P = basePID_P * m_mass / _parent_scene.ODE_STEPSIZE;
777 777
778 Body = d.BodyCreate(_parent_scene.world); 778 Body = d.BodyCreate(_parent_scene.world);
779 779
780 _zeroFlag = false; 780 _zeroFlag = false;
@@ -900,7 +900,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
900 x = tx * cos - y * sin; 900 x = tx * cos - y * sin;
901 y = tx * sin + y * cos; 901 y = tx * sin + y * cos;
902 } 902 }
903 903
904 public bool Collide(IntPtr me, IntPtr other, bool reverse, ref d.ContactGeom contact, 904 public bool Collide(IntPtr me, IntPtr other, bool reverse, ref d.ContactGeom contact,
905 ref d.ContactGeom altContact , ref bool useAltcontact, ref bool feetcollision) 905 ref d.ContactGeom altContact , ref bool useAltcontact, ref bool feetcollision)
906 { 906 {
@@ -944,7 +944,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
944 } 944 }
945 } 945 }
946 return true; 946 return true;
947 } 947 }
948/* 948/*
949 d.AABB aabb; 949 d.AABB aabb;
950 d.GeomGetAABB(other,out aabb); 950 d.GeomGetAABB(other,out aabb);
@@ -1141,7 +1141,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1141 n.Y = 0f; 1141 n.Y = 0f;
1142 n.Z = 1.0f; 1142 n.Z = 1.0f;
1143 } 1143 }
1144 } 1144 }
1145 } 1145 }
1146 1146
1147 if (depth < 0.2f) 1147 if (depth < 0.2f)
@@ -1223,7 +1223,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1223 break; 1223 break;
1224 } // end switch (m_PIDHoverType) 1224 } // end switch (m_PIDHoverType)
1225 1225
1226 // don't go underground 1226 // don't go underground
1227 if (m_targetHoverHeight > terrainheight + 0.5f * (aabb.MaxZ - aabb.MinZ)) 1227 if (m_targetHoverHeight > terrainheight + 0.5f * (aabb.MaxZ - aabb.MinZ))
1228 { 1228 {
1229 float fz = (m_targetHoverHeight - localpos.Z); 1229 float fz = (m_targetHoverHeight - localpos.Z);
@@ -1248,7 +1248,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1248 } 1248 }
1249 } 1249 }
1250 } 1250 }
1251 1251
1252 //****************************************** 1252 //******************************************
1253 if (!m_iscolliding) 1253 if (!m_iscolliding)
1254 m_collideNormal.Z = 0; 1254 m_collideNormal.Z = 0;
@@ -1495,7 +1495,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1495 /// Used to copy variables from unmanaged space at heartbeat rate and also trigger scene updates acording 1495 /// Used to copy variables from unmanaged space at heartbeat rate and also trigger scene updates acording
1496 /// also outbounds checking 1496 /// also outbounds checking
1497 /// copy and outbounds now done in move(..) at ode rate 1497 /// copy and outbounds now done in move(..) at ode rate
1498 /// 1498 ///
1499 /// </summary> 1499 /// </summary>
1500 public void UpdatePositionAndVelocity() 1500 public void UpdatePositionAndVelocity()
1501 { 1501 {
@@ -1625,7 +1625,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1625 CollisionEventsThisFrame.Clear(); 1625 CollisionEventsThisFrame.Clear();
1626 } 1626 }
1627 } 1627 }
1628 } 1628 }
1629 } 1629 }
1630 1630
1631 public override bool SubscribedEvents() 1631 public override bool SubscribedEvents()
@@ -1697,7 +1697,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1697 _position.Z + (m_size.Z - oldsz) * 0.5f); 1697 _position.Z + (m_size.Z - oldsz) * 0.5f);
1698 1698
1699// Velocity = Vector3.Zero; 1699// Velocity = Vector3.Zero;
1700 m_targetVelocity = Vector3.Zero; 1700 m_targetVelocity = Vector3.Zero;
1701 1701
1702 _parent_scene.actor_name_map[collider] = (PhysicsActor)this; 1702 _parent_scene.actor_name_map[collider] = (PhysicsActor)this;
1703 _parent_scene.actor_name_map[capsule] = (PhysicsActor)this; 1703 _parent_scene.actor_name_map[capsule] = (PhysicsActor)this;
@@ -1717,7 +1717,7 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1717 d.BodySetPosition(Body, newPos.X, newPos.Y, newPos.Z); 1717 d.BodySetPosition(Body, newPos.X, newPos.Y, newPos.Z);
1718 _position = newPos; 1718 _position = newPos;
1719 m_freemove = false; 1719 m_freemove = false;
1720 m_pidControllerActive = true; 1720 m_pidControllerActive = true;
1721 } 1721 }
1722 1722
1723 private void changeOrientation(Quaternion newOri) 1723 private void changeOrientation(Quaternion newOri)
@@ -1772,35 +1772,35 @@ namespace OpenSim.Region.PhysicsModule.ubOde
1772 1772
1773 private void changeSetTorque(Vector3 newTorque) 1773 private void changeSetTorque(Vector3 newTorque)
1774 { 1774 {
1775 } 1775 }
1776 1776
1777 private void changeAddForce(Vector3 newForce) 1777 private void changeAddForce(Vector3 newForce)
1778 { 1778 {
1779 } 1779 }
1780 1780
1781 private void changeAddAngularForce(Vector3 arg) 1781 private void changeAddAngularForce(Vector3 arg)
1782 { 1782 {
1783 } 1783 }
1784 1784
1785 private void changeAngularLock(byte arg) 1785 private void changeAngularLock(byte arg)
1786 { 1786 {
1787 } 1787 }
1788 1788
1789 private void changeFloatOnWater(bool arg) 1789 private void changeFloatOnWater(bool arg)
1790 { 1790 {
1791 } 1791 }
1792 1792
1793 private void changeVolumedetetion(bool arg) 1793 private void changeVolumedetetion(bool arg)
1794 { 1794 {
1795 } 1795 }
1796 1796
1797 private void changeSelectedStatus(bool arg) 1797 private void changeSelectedStatus(bool arg)
1798 { 1798 {
1799 } 1799 }
1800 1800
1801 private void changeDisable(bool arg) 1801 private void changeDisable(bool arg)
1802 { 1802 {
1803 } 1803 }
1804 1804
1805 private void changeBuilding(bool arg) 1805 private void changeBuilding(bool arg)
1806 { 1806 {