diff options
Diffstat (limited to 'OpenSim/Region/Physics/OdePlugin')
-rw-r--r-- | OpenSim/Region/Physics/OdePlugin/ODECharacter.cs | 4 | ||||
-rw-r--r-- | OpenSim/Region/Physics/OdePlugin/ODEPrim.cs | 25 | ||||
-rw-r--r-- | OpenSim/Region/Physics/OdePlugin/OdeScene.cs | 17 |
3 files changed, 10 insertions, 36 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs b/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs index c736557..f3b0630 100644 --- a/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs +++ b/OpenSim/Region/Physics/OdePlugin/ODECharacter.cs | |||
@@ -100,7 +100,7 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
100 | private bool m_hackSentFly = false; | 100 | private bool m_hackSentFly = false; |
101 | private int m_requestedUpdateFrequency = 0; | 101 | private int m_requestedUpdateFrequency = 0; |
102 | private Vector3 m_taintPosition; | 102 | private Vector3 m_taintPosition; |
103 | internal bool m_avatarplanted = false; | 103 | |
104 | /// <summary> | 104 | /// <summary> |
105 | /// Hold set forces so we can process them outside physics calculations. This prevents race conditions if we set force | 105 | /// Hold set forces so we can process them outside physics calculations. This prevents race conditions if we set force |
106 | /// while calculatios are going on | 106 | /// while calculatios are going on |
@@ -413,7 +413,7 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
413 | set | 413 | set |
414 | { | 414 | { |
415 | m_iscollidingObj = value; | 415 | m_iscollidingObj = value; |
416 | if (value && !m_avatarplanted) | 416 | if (value) |
417 | m_pidControllerActive = false; | 417 | m_pidControllerActive = false; |
418 | else | 418 | else |
419 | m_pidControllerActive = true; | 419 | m_pidControllerActive = true; |
diff --git a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs index a59f63f..2e78de5 100644 --- a/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs +++ b/OpenSim/Region/Physics/OdePlugin/ODEPrim.cs | |||
@@ -67,14 +67,6 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
67 | private int m_expectedCollisionContacts = 0; | 67 | private int m_expectedCollisionContacts = 0; |
68 | 68 | ||
69 | /// <summary> | 69 | /// <summary> |
70 | /// Gets collide bits so that we can still perform land collisions if a mesh fails to load. | ||
71 | /// </summary> | ||
72 | private int BadMeshAssetCollideBits | ||
73 | { | ||
74 | get { return m_isphysical ? (int)CollisionCategories.Land : 0; } | ||
75 | } | ||
76 | |||
77 | /// <summary> | ||
78 | /// Is this prim subject to physics? Even if not, it's still solid for collision purposes. | 70 | /// Is this prim subject to physics? Even if not, it's still solid for collision purposes. |
79 | /// </summary> | 71 | /// </summary> |
80 | public override bool IsPhysical | 72 | public override bool IsPhysical |
@@ -164,7 +156,7 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
164 | 156 | ||
165 | private PrimitiveBaseShape _pbs; | 157 | private PrimitiveBaseShape _pbs; |
166 | private OdeScene _parent_scene; | 158 | private OdeScene _parent_scene; |
167 | 159 | ||
168 | /// <summary> | 160 | /// <summary> |
169 | /// The physics space which contains prim geometries | 161 | /// The physics space which contains prim geometries |
170 | /// </summary> | 162 | /// </summary> |
@@ -3341,6 +3333,7 @@ Console.WriteLine(" JointCreateFixed"); | |||
3341 | m_material = pMaterial; | 3333 | m_material = pMaterial; |
3342 | } | 3334 | } |
3343 | 3335 | ||
3336 | |||
3344 | private void CheckMeshAsset() | 3337 | private void CheckMeshAsset() |
3345 | { | 3338 | { |
3346 | if (_pbs.SculptEntry && !m_assetFailed && _pbs.SculptTexture != UUID.Zero) | 3339 | if (_pbs.SculptEntry && !m_assetFailed && _pbs.SculptTexture != UUID.Zero) |
@@ -3350,14 +3343,14 @@ Console.WriteLine(" JointCreateFixed"); | |||
3350 | { | 3343 | { |
3351 | RequestAssetDelegate assetProvider = _parent_scene.RequestAssetMethod; | 3344 | RequestAssetDelegate assetProvider = _parent_scene.RequestAssetMethod; |
3352 | if (assetProvider != null) | 3345 | if (assetProvider != null) |
3353 | assetProvider(_pbs.SculptTexture, MeshAssetReceived); | 3346 | assetProvider(_pbs.SculptTexture, MeshAssetReveived); |
3354 | }); | 3347 | }); |
3355 | } | 3348 | } |
3356 | } | 3349 | } |
3357 | 3350 | ||
3358 | private void MeshAssetReceived(AssetBase asset) | 3351 | void MeshAssetReveived(AssetBase asset) |
3359 | { | 3352 | { |
3360 | if (asset != null && asset.Data != null && asset.Data.Length > 0) | 3353 | if (asset.Data != null && asset.Data.Length > 0) |
3361 | { | 3354 | { |
3362 | if (!_pbs.SculptEntry) | 3355 | if (!_pbs.SculptEntry) |
3363 | return; | 3356 | return; |
@@ -3370,12 +3363,6 @@ Console.WriteLine(" JointCreateFixed"); | |||
3370 | m_taintshape = true; | 3363 | m_taintshape = true; |
3371 | _parent_scene.AddPhysicsActorTaint(this); | 3364 | _parent_scene.AddPhysicsActorTaint(this); |
3372 | } | 3365 | } |
3373 | else | ||
3374 | { | ||
3375 | m_log.WarnFormat( | ||
3376 | "[ODE PRIM]: Could not get mesh/sculpt asset {0} for {1} at {2} in {3}", | ||
3377 | _pbs.SculptTexture, Name, _position, _parent_scene.Name); | ||
3378 | } | ||
3379 | } | 3366 | } |
3380 | } | 3367 | } |
3381 | } | 3368 | } \ No newline at end of file |
diff --git a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs index d53bd90..7a50c4c 100644 --- a/OpenSim/Region/Physics/OdePlugin/OdeScene.cs +++ b/OpenSim/Region/Physics/OdePlugin/OdeScene.cs | |||
@@ -501,8 +501,6 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
501 | public int physics_logging_interval = 0; | 501 | public int physics_logging_interval = 0; |
502 | public bool physics_logging_append_existing_logfile = false; | 502 | public bool physics_logging_append_existing_logfile = false; |
503 | 503 | ||
504 | private bool avplanted = false; | ||
505 | private bool av_av_collisions_off = false; | ||
506 | 504 | ||
507 | public d.Vector3 xyz = new d.Vector3(128.1640f, 128.3079f, 25.7600f); | 505 | public d.Vector3 xyz = new d.Vector3(128.1640f, 128.3079f, 25.7600f); |
508 | public d.Vector3 hpr = new d.Vector3(125.5000f, -17.0000f, 0.0000f); | 506 | public d.Vector3 hpr = new d.Vector3(125.5000f, -17.0000f, 0.0000f); |
@@ -646,9 +644,6 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
646 | avMovementDivisorWalk = physicsconfig.GetFloat("av_movement_divisor_walk", 1.3f); | 644 | avMovementDivisorWalk = physicsconfig.GetFloat("av_movement_divisor_walk", 1.3f); |
647 | avMovementDivisorRun = physicsconfig.GetFloat("av_movement_divisor_run", 0.8f); | 645 | avMovementDivisorRun = physicsconfig.GetFloat("av_movement_divisor_run", 0.8f); |
648 | avCapRadius = physicsconfig.GetFloat("av_capsule_radius", 0.37f); | 646 | avCapRadius = physicsconfig.GetFloat("av_capsule_radius", 0.37f); |
649 | avplanted = physicsconfig.GetBoolean("av_planted", false); | ||
650 | av_av_collisions_off = physicsconfig.GetBoolean("av_av_collisions_off", false); | ||
651 | |||
652 | IsAvCapsuleTilted = physicsconfig.GetBoolean("av_capsule_tilted", false); | 647 | IsAvCapsuleTilted = physicsconfig.GetBoolean("av_capsule_tilted", false); |
653 | 648 | ||
654 | contactsPerCollision = physicsconfig.GetInt("contacts_per_collision", 80); | 649 | contactsPerCollision = physicsconfig.GetInt("contacts_per_collision", 80); |
@@ -668,8 +663,6 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
668 | meshSculptLOD = physicsconfig.GetFloat("mesh_lod", 32f); | 663 | meshSculptLOD = physicsconfig.GetFloat("mesh_lod", 32f); |
669 | MeshSculptphysicalLOD = physicsconfig.GetFloat("mesh_physical_lod", 16f); | 664 | MeshSculptphysicalLOD = physicsconfig.GetFloat("mesh_physical_lod", 16f); |
670 | m_filterCollisions = physicsconfig.GetBoolean("filter_collisions", false); | 665 | m_filterCollisions = physicsconfig.GetBoolean("filter_collisions", false); |
671 | |||
672 | |||
673 | 666 | ||
674 | if (Environment.OSVersion.Platform == PlatformID.Unix) | 667 | if (Environment.OSVersion.Platform == PlatformID.Unix) |
675 | { | 668 | { |
@@ -1316,10 +1309,6 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
1316 | if ((p1 is OdePrim) && (((OdePrim)p1).m_isVolumeDetect)) | 1309 | if ((p1 is OdePrim) && (((OdePrim)p1).m_isVolumeDetect)) |
1317 | skipThisContact = true; // No collision on volume detect prims | 1310 | skipThisContact = true; // No collision on volume detect prims |
1318 | 1311 | ||
1319 | if (av_av_collisions_off) | ||
1320 | if ((p1 is OdeCharacter) && (p2 is OdeCharacter)) | ||
1321 | skipThisContact = true; | ||
1322 | |||
1323 | if (!skipThisContact && (p2 is OdePrim) && (((OdePrim)p2).m_isVolumeDetect)) | 1312 | if (!skipThisContact && (p2 is OdePrim) && (((OdePrim)p2).m_isVolumeDetect)) |
1324 | skipThisContact = true; // No collision on volume detect prims | 1313 | skipThisContact = true; // No collision on volume detect prims |
1325 | 1314 | ||
@@ -1983,8 +1972,7 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
1983 | 1972 | ||
1984 | newAv.Flying = isFlying; | 1973 | newAv.Flying = isFlying; |
1985 | newAv.MinimumGroundFlightOffset = minimumGroundFlightOffset; | 1974 | newAv.MinimumGroundFlightOffset = minimumGroundFlightOffset; |
1986 | newAv.m_avatarplanted = avplanted; | 1975 | |
1987 | |||
1988 | return newAv; | 1976 | return newAv; |
1989 | } | 1977 | } |
1990 | 1978 | ||
@@ -1999,7 +1987,6 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
1999 | 1987 | ||
2000 | internal void AddCharacter(OdeCharacter chr) | 1988 | internal void AddCharacter(OdeCharacter chr) |
2001 | { | 1989 | { |
2002 | chr.m_avatarplanted = avplanted; | ||
2003 | if (!_characters.Contains(chr)) | 1990 | if (!_characters.Contains(chr)) |
2004 | { | 1991 | { |
2005 | _characters.Add(chr); | 1992 | _characters.Add(chr); |
@@ -4320,4 +4307,4 @@ namespace OpenSim.Region.Physics.OdePlugin | |||
4320 | m_stats[ODEPrimUpdateFrameMsStatName] = 0; | 4307 | m_stats[ODEPrimUpdateFrameMsStatName] = 0; |
4321 | } | 4308 | } |
4322 | } | 4309 | } |
4323 | } | 4310 | } \ No newline at end of file |