aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs')
-rw-r--r--OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs9
1 files changed, 4 insertions, 5 deletions
diff --git a/OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs b/OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs
index 6af4050..65691fe 100644
--- a/OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs
+++ b/OpenSim/Region/CoreModules/World/Wind/Plugins/ConfigurableWind.cs
@@ -103,7 +103,7 @@ namespace OpenSim.Region.CoreModules.World.Wind.Plugins
103 } 103 }
104 } 104 }
105 105
106 public void WindUpdate(uint frame) 106 public bool WindUpdate(uint frame)
107 { 107 {
108 double avgAng = m_avgDirection * (Math.PI/180.0f); 108 double avgAng = m_avgDirection * (Math.PI/180.0f);
109 double varDir = m_varDirection * (Math.PI/180.0f); 109 double varDir = m_varDirection * (Math.PI/180.0f);
@@ -125,10 +125,8 @@ namespace OpenSim.Region.CoreModules.World.Wind.Plugins
125 offset = Math.Sin(theta) * Math.Sin(theta*4) + (Math.Sin(theta*13) / 3); 125 offset = Math.Sin(theta) * Math.Sin(theta*4) + (Math.Sin(theta*13) / 3);
126 double windSpeed = m_avgStrength + (m_varStrength * offset); 126 double windSpeed = m_avgStrength + (m_varStrength * offset);
127 127
128 if (windSpeed<0) 128 if (windSpeed < 0)
129 windSpeed=0; 129 windSpeed = -windSpeed;
130
131
132 130
133 m_curPredominateWind.X = (float)Math.Cos(windDir); 131 m_curPredominateWind.X = (float)Math.Cos(windDir);
134 m_curPredominateWind.Y = (float)Math.Sin(windDir); 132 m_curPredominateWind.Y = (float)Math.Sin(windDir);
@@ -144,6 +142,7 @@ namespace OpenSim.Region.CoreModules.World.Wind.Plugins
144 m_windSpeeds[y * 16 + x] = m_curPredominateWind; 142 m_windSpeeds[y * 16 + x] = m_curPredominateWind;
145 } 143 }
146 } 144 }
145 return true;
147 } 146 }
148 147
149 public Vector3 WindSpeed(float fX, float fY, float fZ) 148 public Vector3 WindSpeed(float fX, float fY, float fZ)