Dayz Explorer 1.29.162510
Loading...
Searching...
No Matches
chernarusplus.c
Go to the documentation of this file.
1//#define WEATHER_DATA_LOGGING
3{
4 //-------test variables & methods ------
5 #ifdef WEATHER_DATA_LOGGING
6 int overcastChangeCount = 0;
7 int badWeatherCount = 0;
8 int cloudyWeatherCount = 0;
9 int clearWeatherCount = 0;
10 int startYear = 0;
11 int startMonth = 0;
12 int startDay = 0;
13 int startHour = 0;
14 int startMinute = 0;
15 int currentDay = 0;
16 int daysToRun = 10;
17 bool dayInit = false;
18 #endif
19 //------------------------
20
21 //All Chernarus firing coordinates
22 protected static const ref array<vector> CHERNARUS_ARTY_STRIKE_POS =
23 {
24 "-500.00 165.00 5231.69",
25 "-500.00 300.00 9934.41",
26 "10406.86 192.00 15860.00",
27 "4811.75 370.00 15860.00",
28 "-500.00 453.00 15860.00"
29 };
30
31 override void Init()
32 {
33 super.Init();
34
35 // new temperature curve settings
36 m_Sunrise_Jan = 8.54;
37 m_Sunset_Jan = 15.52;
38 m_Sunrise_Jul = 3.26;
39 m_Sunset_Jul = 20.73;
40
41 int tempIdx;
42 m_MinTemps = {-3,-2,0,4,9,14,18,17,13,11,9,0}; //{-3,-2,0,4,9,14,18,17,12,7,4,0} original values
43 if (CfgGameplayHandler.GetEnvironmentMinTemps() && CfgGameplayHandler.GetEnvironmentMinTemps().Count() == 12)
44 {
45 for (tempIdx = 0; tempIdx < CfgGameplayHandler.GetEnvironmentMinTemps().Count(); tempIdx++)
46 {
47 m_MinTemps[tempIdx] = CfgGameplayHandler.GetEnvironmentMinTemps().Get(tempIdx);
48 }
49 }
50
51 m_MaxTemps = {3,5,7,14,19,24,26,25,18,14,10,5}; //{3,5,7,14,19,24,26,25,21,16,10,5} original values
52 if (CfgGameplayHandler.GetEnvironmentMaxTemps() && CfgGameplayHandler.GetEnvironmentMaxTemps().Count() == 12)
53 {
54 for (tempIdx = 0; tempIdx < CfgGameplayHandler.GetEnvironmentMaxTemps().Count(); tempIdx++)
55 {
56 m_MaxTemps[tempIdx] = CfgGameplayHandler.GetEnvironmentMaxTemps().Get(tempIdx);
57 }
58 }
59
61
62 m_WorldWindCoef = 0.4;
63 m_CloudsTemperatureEffectModifier = 2.0;
64 m_TemperaturePerHeightReductionModifier = 0.012;
65
67
68 if (g_Game.IsServer() || !g_Game.IsMultiplayer())
69 {
70 m_Weather.GetSnowfall().SetLimits(0, 0);
71 m_Weather.SetDynVolFogHeightBias(m_WeatherDefaultSettings.m_DefaultHeigthBias);
72
73 if (g_Game.IsMultiplayer())
74 {
75 float startingOvercast = Math.RandomFloat(0.2,0.75);
76 m_Weather.GetOvercast().Set(startingOvercast,0,5); //forcing a random weather at a clean server start and an instant change for overcast
77 CalculateVolFog(startingOvercast, m_Weather.GetWindSpeed(), 0);
78 }
79 }
80 }
81
82 override void SetupWeatherSettings()
83 {
84 super.SetupWeatherSettings();
85
86 m_WeatherDefaultSettings.m_StormThreshold = 0.9;
87 m_WeatherDefaultSettings.m_GlobalSuddenChance = 0;
88 m_WeatherDefaultSettings.m_BadWeatherSuddenChance = 0;
89 m_WeatherDefaultSettings.m_DefaultHeigthBias = 50;
90 }
91
92 override bool WeatherOnBeforeChange( EWeatherPhenomenon type, float actual, float change, float time )
93 {
94 #ifdef WEATHER_DATA_LOGGING
95 if ( !dayInit )
96 {
97 g_Game.GetWorld().GetDate(startYear, startMonth, startDay, startHour, startMinute);
98 dayInit = true;
99 }
100 #endif
101
102 float phmnTime = 5;
103 float phmnLength = 10;
104 float phmnValue = 0;
105
106 m_Weather.SetStorm( 1.0, m_WeatherDefaultSettings.m_StormThreshold, 45 );
107 m_Weather.GetSnowfall().SetLimits(0, 0);
108
109 m_Weather.SetRainThresholds( m_WeatherDefaultSettings.m_RainThreshold, 1.0, 60 );
110 m_Weather.SetWindMaximumSpeed( 20 );
111
112 if (m_Weather.GetDynVolFogHeightBias() < m_WeatherDefaultSettings.m_DefaultHeigthBias)
113 {
114 m_Weather.SetDynVolFogHeightBias(m_WeatherDefaultSettings.m_DefaultHeigthBias);
115 }
116
117 switch (type)
118 {
119 //-----------------------------------------------------------------------------------------------------------------------------
120 case EWeatherPhenomenon.OVERCAST:
121 {
122 #ifdef WEATHER_DATA_LOGGING
123 overcastChangeCount++;
124 #endif
125
126 float windDirection, windMag;
127
128 //went something goes wrong choose some default random weather
129 phmnValue = Math.RandomFloatInclusive( 0.2, 0.7 );
130 phmnTime = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinTime, m_WeatherDefaultSettings.m_OvercastMaxTime );
131 phmnLength = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinLength, m_WeatherDefaultSettings.m_OvercastMaxLength );
132
133 //----
134 //calculate next weather
135 m_Chance = Math.RandomIntInclusive( 0, 100 );
136
137 //--
138 if ( m_LastWeather == WorldDataWeatherConstants.CLEAR_WEATHER )
139 {
140 m_ClearWeatherChance -= ( m_StepValue * m_SameWeatherCnt); //decrease the chance of the same weather
141 }
142
143 if ( m_LastWeather == WorldDataWeatherConstants.CLOUDY_WEATHER )
144 {
145 m_ClearWeatherChance += ( m_StepValue * m_SameWeatherCnt); //increase the chance of the better weather
146 }
147
148 if ( m_LastWeather == WorldDataWeatherConstants.BAD_WEATHER )
149 {
150 m_ClearWeatherChance += m_StepValue; //increase the chance of the better weather slightly
151 m_BadWeatherChance += (( m_StepValue * m_SameWeatherCnt ) + m_StepValue ); //decrease the chance of the same weather rapidly
152 }
153
154 //----
156 {
157 m_ChoosenWeather = WorldDataWeatherConstants.CLEAR_WEATHER;
158 if ( m_LastWeather == WorldDataWeatherConstants.CLEAR_WEATHER )
160 }
161 else if ( m_Chance > m_BadWeatherChance )
162 {
163 m_ChoosenWeather = WorldDataWeatherConstants.BAD_WEATHER;
164 if ( m_LastWeather == WorldDataWeatherConstants.BAD_WEATHER )
166 }
167 else
168 {
169 m_ChoosenWeather = WorldDataWeatherConstants.CLOUDY_WEATHER;
170 if ( m_LastWeather == WorldDataWeatherConstants.CLOUDY_WEATHER )
172 }
173
176
177 m_ClearWeatherChance = m_WeatherDefaultSettings.m_ClearWeatherChance;
178 m_BadWeatherChance = m_WeatherDefaultSettings.m_BadWeatherChance;
179
180 //----
181 //set choosen weather
182 if ( m_ChoosenWeather == WorldDataWeatherConstants.CLEAR_WEATHER )
183 {
184 m_LastWeather = WorldDataWeatherConstants.CLEAR_WEATHER;
185 #ifdef WEATHER_DATA_LOGGING
186 clearWeatherCount++;
187 #endif
188
189 phmnValue = Math.RandomFloatInclusive( 0.0, 0.3 );
190 phmnTime = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinTime, m_WeatherDefaultSettings.m_OvercastMaxTime );
191 phmnLength = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinLength, m_WeatherDefaultSettings.m_OvercastMaxLength );
192 }
193
194 if ( m_ChoosenWeather == WorldDataWeatherConstants.CLOUDY_WEATHER )
195 {
196 m_LastWeather = WorldDataWeatherConstants.CLOUDY_WEATHER;
197 #ifdef WEATHER_DATA_LOGGING
198 cloudyWeatherCount++;
199 #endif
200
201 phmnValue = Math.RandomFloatInclusive( 0.3, 0.6 );
202 phmnTime = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinTime, m_WeatherDefaultSettings.m_OvercastMaxTime );
203 phmnLength = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinLength, m_WeatherDefaultSettings.m_OvercastMaxLength );
204 }
205
206 if ( m_ChoosenWeather == WorldDataWeatherConstants.BAD_WEATHER )
207 {
208 m_LastWeather = WorldDataWeatherConstants.BAD_WEATHER;
209 #ifdef WEATHER_DATA_LOGGING
210 badWeatherCount++;
211 #endif
212
213 phmnValue = Math.RandomFloatInclusive( 0.6, 1.0 );
214 phmnTime = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinTime, m_WeatherDefaultSettings.m_OvercastMaxTime );
215 phmnLength = Math.RandomIntInclusive( m_WeatherDefaultSettings.m_OvercastMinLength, m_WeatherDefaultSettings.m_OvercastMaxLength );
216 }
217
218 m_Weather.GetOvercast().Set( phmnValue, phmnTime, phmnLength );
219
220 CalculateWind( m_ChoosenWeather, false, windMag, windDirection );
221 m_Weather.GetWindMagnitude().Set( windMag, phmnTime * WIND_MAGNITUDE_TIME_MULTIPLIER , phmnTime * (1 - WIND_MAGNITUDE_TIME_MULTIPLIER) ); // magnitude change happens during the overcast change, after overcast change finishes wind will decrease a bit
222 m_Weather.GetWindDirection().Set( windDirection, phmnTime * WIND_DIRECTION_TIME_MULTIPLIER , phmnTime - (phmnTime * WIND_DIRECTION_TIME_MULTIPLIER) + phmnLength + 1000 );
223
224 CalculateVolFog(phmnValue, windMag, phmnTime);
225
226 Debug.WeatherLog(string.Format("Chernarus::Weather::Overcast:: (%1) overcast: %2", g_Game.GetDayTime(), actual));
227 Debug.WeatherLog(string.Format("Chernarus::Weather::Overcast::Rain:: (%1) %2", g_Game.GetDayTime(), m_Weather.GetRain().GetActual()));
228
229 #ifdef WEATHER_DATA_LOGGING
230 int testYear = 0;
231 int testMonth = 0;
232 int testDay = 0;
233 int testHour = 0;
234 int testMinute = 0;
235 g_Game.GetWorld().GetDate(testYear, testMonth, testDay, testHour, testMinute);
236
237 if ( testDay - startDay > currentDay && testHour - startHour >= 0 && testMinute - startMinute >= 0 )
238 {
239 FileHandle file = OpenFile("$profile:OvercastCountsCharnarus" + (currentDay + 1) + ".log", FileMode.WRITE);
240 FPrintln(file, "================================================================");
241 FPrintln(file," ================== Day " + (currentDay + 1) + " ================== ");
242 FPrintln(file, "================================================================");
243 FPrintln(file, "Overcast Change Count: " + overcastChangeCount);
244 FPrintln(file, "Bad Weather Change Count: " + badWeatherCount);
245 FPrintln(file, "Cloudy Weather Count: " + cloudyWeatherCount);
246 FPrintln(file, "Clear Weather Count: " + clearWeatherCount);
247
248 currentDay++;
249 CloseFile(file);
250 if ( currentDay == daysToRun )
251 {
252 g_Game.RequestExit(IDC_MAIN_QUIT);
253 }
254
255 overcastChangeCount = 0;
256 badWeatherCount = 0;
257 cloudyWeatherCount = 0;
258 clearWeatherCount = 0;
259 }
260 #endif
261
262 return true;
263 }
264 //-----------------------------------------------------------------------------------------------------------------------------
265 case EWeatherPhenomenon.RAIN:
266 {
267 float actualOvercast = m_Weather.GetOvercast().GetActual();
268
269 m_Chance = Math.RandomIntInclusive( 0, 100 );
270 phmnValue = 0.2;
271 phmnTime = 90;
272 phmnLength = 30;
273
274 if ( actualOvercast <= m_WeatherDefaultSettings.m_RainThreshold )
275 {
276 m_Weather.GetRain().Set( 0.0, m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
277 Debug.WeatherLog(string.Format("Chernarus::Weather::Rain::ForceEnd:: (%1) %2 -> 0", g_Game.GetDayTime(), actual));
278 return true;
279 }
280
281 if ( actualOvercast > m_WeatherDefaultSettings.m_StormThreshold )
282 {
283 phmnValue = Math.RandomFloatInclusive( 0.8, 1.0 );
284 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
285 phmnLength = 0;
286
287 m_Weather.GetRain().Set( phmnValue, phmnTime, phmnLength );
288 Debug.WeatherLog(string.Format("Chernarus::Weather::Rain::ForceStorm:: (%1) %2 -> %3", g_Game.GetDayTime(), actual, phmnValue));
289 return true;
290 }
291
292 //make a differnce in "normal rain"
293 if ( actualOvercast < 0.75 )
294 {
295 if ( m_Chance < 30 )
296 {
297 phmnValue = Math.RandomFloatInclusive( 0.1, 0.3 );
298 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
299 phmnLength = 0;
300 }
301 else if ( m_Chance < 60 )
302 {
303 phmnValue = Math.RandomFloatInclusive( 0.2, 0.5 );
304 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
305 phmnLength = 0;
306 }
307 else if ( m_Chance < 80 )
308 {
309 phmnValue = Math.RandomFloatInclusive( 0.0, 0.2 );
310 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
311 phmnLength = 0;
312 }
313 else //also have the chance to not have rain at all
314 {
315 phmnValue = 0;
316 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
317 phmnLength = m_WeatherDefaultSettings.m_RainLengthMax;
318 }
319 }
320 else
321 {
322 if ( m_Chance < 25 )
323 {
324 phmnValue = Math.RandomFloatInclusive( 0.5, 0.7 );
325 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
326 phmnLength = 0;
327 }
328 else if ( m_Chance < 50 )
329 {
330 phmnValue = Math.RandomFloatInclusive( 0.2, 0.4 );
331 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
332 phmnLength = 0;
333 }
334 else if ( m_Chance < 75 )
335 {
336 phmnValue = Math.RandomFloatInclusive( 0.4, 0.6 );
337 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
338 phmnLength = 0;
339 }
340 else //also have the chance to not have rain at all
341 {
342 phmnValue = 0;
343 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
344 phmnLength = m_WeatherDefaultSettings.m_RainLengthMax;
345 }
346 }
347
348 m_Weather.GetRain().Set( phmnValue, phmnTime, phmnLength );
349
350 Debug.WeatherLog(string.Format("Chernarus::Weather::Rain:: (%1) %2", g_Game.GetDayTime(), actual));
351
352 return true;
353 }
354 //-----------------------------------------------------------------------------------------------------------------------------
355 case EWeatherPhenomenon.FOG:
356 {
357 float fogMin = 0.0;
358 float fogMax = 0.15;
359 float fogTime = 1800.0;
360
361 float fogyMorning = Math.RandomFloatInclusive( 0.0, 1.0 );
362
363 if ( fogyMorning > 0.85 )
364 {
365 if ( (g_Game.GetDayTime() > 4 && g_Game.GetDayTime() < 7 ) )
366 {
367 fogMin = 0.10;
368 fogMax = 0.35;
369 fogTime = 300;
370 }
371 }
372
373 if ( m_Weather.GetOvercast().GetActual() < 0.3 )
374 {
375 fogMin = 0.0;
376 fogMax = 0.08;
377 fogTime = 900.0;
378 }
379
380 m_Weather.GetFog().Set( Math.RandomFloatInclusive( fogMin, fogMax ), fogTime, 0);
381
382 Debug.WeatherLog(string.Format("Chernarus::Weather::Fog:: (%1) %2", g_Game.GetDayTime(), actual));
383
384 return true;
385 }
386 //-----------------------------------------------------------------------------------------------------------------------------
387 case EWeatherPhenomenon.WIND_MAGNITUDE:
388 {
389 phmnTime = Math.RandomInt( m_WeatherDefaultSettings.m_RainTimeMin, m_WeatherDefaultSettings.m_RainTimeMax );
390 m_Weather.GetWindMagnitude().Set(m_Weather.GetWindMagnitude().GetActual() * 0.75, phmnTime , m_WeatherDefaultSettings.m_OvercastMaxLength); // next change will be happen with the overcast change
391
392 return true;
393 }
394 }
395
396 return false;
397 }
398
399 protected override void CalculateWind(int newWeather, bool suddenChange, out float magnitude, out float direction)
400 {
401 magnitude = 5;
402 direction = 0;
403
404 float windChance = Math.RandomIntInclusive( 0, 100 );
405
406 if ( newWeather == WorldDataWeatherConstants.CLEAR_WEATHER )
407 {
408 if ( windChance < 30 )
409 {
410 magnitude = Math.RandomFloatInclusive( 6 , 10 );
411 direction = Math.RandomFloatInclusive( -1.0 , -0.5);
412 }
413 else if ( windChance < 75 )
414 {
415 magnitude = Math.RandomFloatInclusive( 8 , 12 );
416 direction = Math.RandomFloatInclusive( -1.3 , -0.9);
417 }
418 else
419 {
420 magnitude = Math.RandomFloatInclusive( 4 , 6 );
421 direction = Math.RandomFloatInclusive( -0.6 , 0.0);
422 }
423
424 }
425 else if ( newWeather == WorldDataWeatherConstants.CLOUDY_WEATHER )
426 {
427 if ( windChance < 45 )
428 {
429 magnitude = Math.RandomFloatInclusive( 6 , 10 );
430 direction = Math.RandomFloatInclusive( -3.14 , -2.4);
431 }
432 else if ( windChance < 90 )
433 {
434 magnitude = Math.RandomFloatInclusive( 8 , 12 );
435 direction = Math.RandomFloatInclusive( -2.6, -2.0);
436 }
437 else
438 {
439 magnitude = Math.RandomFloatInclusive( 10 , 14 );
440 direction = Math.RandomFloatInclusive( -2.2 , -1.4);
441 }
442 }
443 else
444 {
445 if ( suddenChange || m_Weather.GetOvercast().GetActual() > m_WeatherDefaultSettings.m_StormThreshold || m_Weather.GetOvercast().GetForecast() - m_Weather.GetOvercast().GetActual() >= 0.4 )
446 {
447 magnitude = Math.RandomFloatInclusive( 14 , 17 );
448 direction = Math.RandomFloatInclusive( 0.9 , 1.45);
449 }
450 else if ( windChance < 45 )
451 {
452 magnitude = Math.RandomFloatInclusive( 9 , 12 );
453 direction = Math.RandomFloatInclusive( 1.45, 1.7);
454 }
455 else if ( windChance < 90 )
456 {
457 magnitude = Math.RandomFloatInclusive( 7 , 10 );
458 direction = Math.RandomFloatInclusive( 1.6 , 2);
459 }
460 else
461 {
462 magnitude = Math.RandomFloatInclusive( 4 , 8 );
463 direction = Math.RandomFloatInclusive( 1.9, 2.2 );
464 }
465 }
466 }
467
468 protected override void CalculateVolFog(float lerpValue, float windMagnitude, float changeTime)
469 {
470 float distanceDensity, heigthDensity, heightBias;
471 int year, month, day, hour, minute;
472 g_Game.GetWorld().GetDate(year, month, day, hour, minute);
473
474 if ( hour < 9 && hour >= 5 )
475 {
476 distanceDensity = Math.Lerp( 0.015, 0.05, lerpValue ) * Math.Clamp(1 - (windMagnitude / m_Weather.GetWindMaximumSpeed()), 0.1, 1);
477 heigthDensity = Math.Lerp( 0.8, 1, lerpValue);
478
479 heightBias = m_Weather.GetDynVolFogHeightBias();
480
481 if (heightBias == m_WeatherDefaultSettings.m_DefaultHeigthBias) //checks if the randomization has been done
482 {
483 int diceRoll = Math.RandomIntInclusive(1,100);
484
485 if (diceRoll < 50)
486 {
487 heightBias = Math.RandomInt(m_WeatherDefaultSettings.m_DefaultHeigthBias + 1, 80);
488 }
489 else if (diceRoll < 85)
490 {
491 heightBias = Math.RandomInt(80, 120);
492 }
493 else
494 {
495 heightBias = Math.RandomInt(120, 200);
496 }
497 }
498 }
499 else if ( hour < 18 && hour >= 9 )
500 {
501 distanceDensity = Math.Lerp( 0.01, 0.05, lerpValue ) * Math.Clamp(1 - (windMagnitude / m_Weather.GetWindMaximumSpeed()), 0.1, 1);
502 heigthDensity = Math.Lerp( 0.9, 1, lerpValue);
503 heightBias = m_WeatherDefaultSettings.m_DefaultHeigthBias;
504 }
505 else
506 {
507 distanceDensity = Math.Lerp( 0.01, 0.03, lerpValue ) * Math.Clamp(1 - (windMagnitude / m_Weather.GetWindMaximumSpeed()), 0.1, 1);
508 heigthDensity = Math.Lerp( 0.9, 1, lerpValue);
509 heightBias = m_WeatherDefaultSettings.m_DefaultHeigthBias;
510 }
511
512 m_Weather.SetDynVolFogDistanceDensity(distanceDensity, changeTime);
513 m_Weather.SetDynVolFogHeightDensity(heigthDensity, changeTime);
514 m_Weather.SetDynVolFogHeightBias(heightBias, changeTime);
515 }
516
517 bool LogWeatherData() //called from mission file to check if the logging should start
518 {
519 #ifdef WEATHER_DATA_LOGGING
520 return true;
521 #endif
522 return false;
523 }
524
526 const int CLEAR_WEATHER = 1;
527 const int CLOUDY_WEATHER = 2;
528 const int BAD_WEATHER = 3;
529
531 const int OVERCAST_MIN_TIME = 600;
532 const int OVERCAST_MAX_TIME = 900;
533
534 const float RAIN_THRESHOLD = 0.6;
535 const int RAIN_TIME_MIN = 60;
536 const int RAIN_TIME_MAX = 120;
537 const float STORM_THRESHOLD = 0.9;
538
541
543 protected int m_stepValue = m_StepValue;
544 protected int m_chance = m_Chance;
545
548}
override void CalculateVolFog(float lerpValue, float windMagnitude, float changeTime)
const int CLOUDY_WEATHER
override void Init()
const int CLEAR_WEATHER
DEPRECATED (see WorldDataWeatherConstants).
const int OVERCAST_MIN_TIME
DEPRECATED (see WorldDataWeatherSettings).
const float RAIN_THRESHOLD
override void CalculateWind(int newWeather, bool suddenChange, out float magnitude, out float direction)
const int RAIN_TIME_MAX
override void SetupWeatherSettings()
const int OVERCAST_MAX_TIME
static const ref array< vector > CHERNARUS_ARTY_STRIKE_POS
override bool WeatherOnBeforeChange(EWeatherPhenomenon type, float actual, float change, float time)
const float STORM_THRESHOLD
const int RAIN_TIME_MIN
Definition debug.c:2
Definition enmath.c:7
float WIND_DIRECTION_TIME_MULTIPLIER
Definition worlddata.c:16
float m_Sunset_Jan
Definition worlddata.c:25
float m_WorldWindCoef
Definition worlddata.c:39
float m_Sunrise_Jan
Definition worlddata.c:24
int m_ClearWeatherChance
Definition worlddata.c:37
ref WorldDataWeatherSettings m_WeatherDefaultSettings
Definition worlddata.c:31
void WorldData()
Definition worlddata.c:50
ref array< vector > m_FiringPos
Definition worlddata.c:28
int m_Chance
Definition worlddata.c:46
int m_LastWeather
Definition worlddata.c:48
float m_MaxTemps[12]
Definition worlddata.c:22
int m_SameWeatherCnt
Definition worlddata.c:44
float m_MinTemps[12]
Definition worlddata.c:23
int m_BadWeatherChance
weather related
Definition worlddata.c:36
int m_StepValue
Definition worlddata.c:45
float WIND_MAGNITUDE_TIME_MULTIPLIER
Definition worlddata.c:15
float m_UniversalTemperatureSourceCapModifier
Definition worlddata.c:41
Weather m_Weather
Definition worlddata.c:18
float m_Sunset_Jul
Definition worlddata.c:27
int m_ChoosenWeather
Definition worlddata.c:47
float m_Sunrise_Jul
Definition worlddata.c:26
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
DayZGame g_Game
Definition dayzgame.c:3942
FileMode
Definition ensystem.c:383
proto void CloseFile(FileHandle file)
Close the File.
proto FileHandle OpenFile(string name, FileMode mode)
Opens File.
int[] FileHandle
Definition ensystem.c:390
proto void FPrintln(FileHandle file, void var)
Write to file and add new line.
const int IDC_MAIN_QUIT
Definition constants.c:144
EWeatherPhenomenon
Definition weather.c:11