aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--OpenSim/Region/Physics/OdePlugin/OdePlugin.cs9
1 files changed, 9 insertions, 0 deletions
diff --git a/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs b/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs
index 5078f03..787cb12 100644
--- a/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs
+++ b/OpenSim/Region/Physics/OdePlugin/OdePlugin.cs
@@ -2025,8 +2025,17 @@ namespace OpenSim.Region.Physics.OdePlugin
2025 { 2025 {
2026 for (int x = 0; x < 512; x++) 2026 for (int x = 0; x < 512; x++)
2027 { 2027 {
2028 if (Single.IsNaN(resultarr2[y, x]) || Single.IsInfinity(resultarr2[y, x]))
2029 {
2030 m_log.Warn("[PHYSICS]: Non finite heightfield element detected. Setting it to 0");
2031 resultarr2[y, x] = 0;
2032 }
2033
2028 if (resultarr2[y, x] <= 0) 2034 if (resultarr2[y, x] <= 0)
2035 {
2029 returnarr[i] = 0.0000001f; 2036 returnarr[i] = 0.0000001f;
2037
2038 }
2030 else 2039 else
2031 returnarr[i] = resultarr2[y, x]; 2040 returnarr[i] = resultarr2[y, x];
2032 2041