DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
ScriptConsoleWeatherTab.c
См. документацию.
2{
3 static void SetDefaultValues()
4 {
5
6 }
7}
8
10{
11 protected ref Timer m_RPCTimer = new Timer();
12 protected const int INTERPOLATION_MAX = 920;
13 protected const int DURATION_MAX = 960;
14
15 // FOG
16 protected SliderWidget m_FogValueSetSlider;
17 protected SliderWidget m_FogValueGetSlider;
18
20
21 protected SliderWidget m_FogInterpolationTimeSlider;
22 protected SliderWidget m_FogDurationTimeSlider;
23
26
30
31 protected static float m_FogValue = -1;
32 protected static float m_FogInterpolationTimeValue;
33 protected static float m_FogDurationTimeValue = -1;
34
35 // OVERCAST
36 protected SliderWidget m_OvercastValueSetSlider;
37 protected SliderWidget m_OvercastValueGetSlider;
38
40
41 protected SliderWidget m_OvercastInterpolationTimeSlider;
42 protected SliderWidget m_OvercastDurationTimeSlider;
43
46
50
51 protected static float m_OvercastValue = -1;
52 protected static float m_OvercastInterpolationTimeValue;
53 protected static float m_OvercastDurationTimeValue = -1;
54
55 // Rain
56 protected SliderWidget m_RainValueSetSlider;
57 protected SliderWidget m_RainValueGetSlider;
58
60
61 protected SliderWidget m_RainInterpolationTimeSlider;
62 protected SliderWidget m_RainDurationTimeSlider;
63
66
70
71 protected static float m_RainValue = -1;
72 protected static float m_RainInterpolationTimeValue;
73 protected static float m_RainDurationTimeValue = -1;
74
75 // Snowfall
76 protected SliderWidget m_SnowfallValueSetSlider;
77 protected SliderWidget m_SnowfallValueGetSlider;
78
80
81 protected SliderWidget m_SnowfallInterpolationTimeSlider;
82 protected SliderWidget m_SnowfallDurationTimeSlider;
83
86
90
91 protected static float m_SnowfallValue = -1;
92 protected static float m_SnowfallInterpolationTimeValue;
93 protected static float m_SnowfallDurationTimeValue = -1;
94
95 // Vol Fog
97 protected SliderWidget m_VolFogDistanceDensitySlider;
101
103 protected SliderWidget m_VolFogDistanceDensityTimeSlider;
107
109 protected SliderWidget m_VolFogHeightDensitySlider;
113
115 protected SliderWidget m_VolFogHeightDensityTimeSlider;
119
121 protected SliderWidget m_VolFogHeightBiasSlider;
125
127 protected SliderWidget m_VolFogHeightBiasTimeSlider;
131
132 protected static float m_VolFogDistanceDensityValue = -1;
133 protected static float m_VolFogDistanceDensityTimeValue;
134 protected static float m_VolFogHeightDensityValue = -1;
135 protected static float m_VolFogHeightDensityTimeValue;
136 protected static float m_VolFogHeightBiasValue = -1;
137 protected static float m_VolFogHeightBiasTimeValue;
138
139 // Wind Magnitude
140 protected SliderWidget m_WindMValueSetSlider;
141 protected SliderWidget m_WindMValueGetSlider;
142
144
145 protected SliderWidget m_WindMInterpolationTimeSlider;
146 protected SliderWidget m_WindMDurationTimeSlider;
147
150
154
155 protected static float m_WindMagnitudeValue = -1;
156 protected static float m_WindMInterpolationTimeValue;
157 protected static float m_WindMDurationTimeValue = -1;
158
159 // Wind Direction
160 protected SliderWidget m_WindDValueSetSlider;
161 protected SliderWidget m_WindDValueGetSlider;
162
164
165 protected SliderWidget m_WindDInterpolationTimeSlider;
166 protected SliderWidget m_WindDDurationTimeSlider;
167
170
174
175 protected static float m_WindDirectionValue = -1;
176 protected static float m_WindDInterpolationTimeValue;
177 protected static float m_WindDDurationTimeValue = -1;
178
179 // Other
180 protected ButtonWidget m_HideUIButton;
181 protected ImageWidget m_HideUIIcon;
182
183 protected ButtonWidget m_LoadPresetButton;
184 protected ButtonWidget m_DeletePresetButton;
185 protected ButtonWidget m_SavePresetButton;
186
187 protected ButtonWidget m_CopyButton;
188 protected ButtonWidget m_PasteButton;
189 protected ButtonWidget m_ResetButton;
190 protected ButtonWidget m_UpdateButton;
191 protected ButtonWidget m_ApplyButton;
192
195
196 protected bool m_UIVisibilityState = true;
198 protected ref ScriptConsolePresetsList m_WeatherPresetsList;
200 protected bool m_IsCAPSPressed;
201 protected bool m_CanUseMovement;
202 protected bool m_IsSavingPreset;
203
205 {
206 // FOG
207 m_FogValue = m_FogValueSetSlider.GetCurrent() / 100;
210
211 // OVERCAST
212 m_OvercastValue = m_OvercastValueSetSlider.GetCurrent() / 100;
215
216 // Rain
217 m_RainValue = m_RainValueSetSlider.GetCurrent() / 100;
220
221 // Snowfall
222 m_SnowfallValue = m_SnowfallValueSetSlider.GetCurrent() / 100;
225
226 // Vol Fog
229
232
235 }
236
237 void ScriptConsoleWeatherTab(Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent = null)
238 {
239 // FOG
240 m_FogValueSetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderFogValue"));
241 m_FogValueGetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderFogActualValue"));
242 m_FogValueSetText = TextWidget.Cast(root.FindAnyWidget("TextFogValueActual"));
243
244 m_FogInterpolationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderFogTarget"));
245 m_FogDurationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderFogDuration"));
246
247 m_FogInterpolationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxFogTarget"));
248 m_FogDurationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxFogDuration"));
249
250 m_FogValueEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxFogValue"));
251 m_FogInterpolationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxFogTarget"));
252 m_FogDurationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxFogDuration"));
253
254 // OVERCAST
255 m_OvercastValueSetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderOvercastValue"));
256 m_OvercastValueGetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderOvercastActualValue"));
257 m_OvercastValueSetText = TextWidget.Cast(root.FindAnyWidget("TextOvercastValueActual"));
258
259 m_OvercastInterpolationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderOvercastTarget"));
260 m_OvercastDurationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderOvercastDuration"));
261
262 m_OvercastInterpolationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxOvercastTarget"));
263 m_OvercastDurationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxOvercastDuration"));
264
265 m_OvercastValueEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxOvercastValue"));
266 m_OvercastInterpolationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxOvercastTarget"));
267 m_OvercastDurationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxOvercastDuration"));
268
269 // Rain
270 m_RainValueSetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderRainValue"));
271 m_RainValueGetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderRainActualValue"));
272 m_RainValueSetText = TextWidget.Cast(root.FindAnyWidget("TextRainValueActual"));
273
274 m_RainInterpolationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderRainTarget"));
275 m_RainDurationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderRainDuration"));
276
277 m_RainInterpolationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxRainTarget"));
278 m_RainDurationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxRainDuration"));
279
280 m_RainValueEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxRainValue"));
281 m_RainInterpolationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxRainTarget"));
282 m_RainDurationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxRainDuration"));
283
284 // Snowfall
285 m_SnowfallValueSetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderSnowfallValue"));
286 m_SnowfallValueGetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderSnowfallActualValue"));
287 m_SnowfallValueSetText = TextWidget.Cast(root.FindAnyWidget("TextSnowfallValueActual"));
288
289 m_SnowfallInterpolationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderSnowfallTarget"));
290 m_SnowfallDurationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderSnowfallDuration"));
291
292 m_SnowfallInterpolationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxSnowfallTarget"));
293 m_SnowfallDurationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxSnowfallDuration"));
294
295 m_SnowfallValueEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxSnowfallValue"));
296 m_SnowfallInterpolationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxSnowfallTarget"));
297 m_SnowfallDurationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxSnowfallDuration"));
298
299 // Vol Fog
300 m_VolFogDistanceDensityEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxVolfogDDValue"));
301 m_VolFogDistanceDensitySlider = SliderWidget.Cast(root.FindAnyWidget("SliderVolfogDD"));
302 m_VolFogDistanceDensitySlider.SetMinMax(0, 1);
303 m_VolFogDistanceDensitySlider.SetStep(0.01);
304 m_VolFogDistanceDensityMinText = TextWidget.Cast(root.FindAnyWidget("TextMinVolfogDDValue"));
305 m_VolFogDistanceDensityMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxVolfogDDValue"));
306 m_VolFogDistanceDensitySetText = TextWidget.Cast(root.FindAnyWidget("TextVolfogDDValueActual"));
307
308 m_VolFogDistanceDensityTimeEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxVolfogDDTValue"));
309 m_VolFogDistanceDensityTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderVolfogDDTime"));
310 m_VolFogDistanceDensityTimeMinText = TextWidget.Cast(root.FindAnyWidget("TextMinVolfogDDTValue"));
311 m_VolFogDistanceDensityTimeMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxVolfogDDTValue"));
312 m_VolFogDistanceDensityTimeSetText = TextWidget.Cast(root.FindAnyWidget("TextVolfogDDTValueActual"));
313
314 m_VolFogHeightDensityEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxVolfogHDValue"));
315 m_VolFogHeightDensitySlider = SliderWidget.Cast(root.FindAnyWidget("SliderVolfogHD"));
316 m_VolFogHeightDensitySlider.SetMinMax(0, 1);
317 m_VolFogHeightDensitySlider.SetStep(0.01);
318 m_VolFogHeightDensityMinText = TextWidget.Cast(root.FindAnyWidget("TextMinVolfogHDValue"));
319 m_VolFogHeightDensityMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxVolfogHDValue"));
320 m_VolFogHeightDensitySetText = TextWidget.Cast(root.FindAnyWidget("TextVolfogHDValueActual"));
321
322 m_VolFogHeightDensityTimeEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxVolfogHDTValue"));
323 m_VolFogHeightDensityTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderVolfogHDTime"));
324 m_VolFogHeightDensityTimeMinText = TextWidget.Cast(root.FindAnyWidget("TextMinVolfogHDTValue"));
325 m_VolFogHeightDensityTimeMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxVolfogHDTValue"));
326 m_VolFogHeightDensityTimeSetText = TextWidget.Cast(root.FindAnyWidget("TextVolfogHDTValueActual"));
327
328 m_VolFogHeightBiasEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxVolfogHBValue"));
329 m_VolFogHeightBiasSlider = SliderWidget.Cast(root.FindAnyWidget("SliderVolfogHB"));
330 m_VolFogHeightBiasSlider.SetMinMax(-500, 500);
331 m_VolFogHeightBiasMinText = TextWidget.Cast(root.FindAnyWidget("TextMinVolfogHBValue"));
332 m_VolFogHeightBiasMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxVolfogHBValue"));
333 m_VolFogHeightBiasSetText = TextWidget.Cast(root.FindAnyWidget("TextVolfogHBValueActual"));
334
335 m_VolFogHeightBiasTimeEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxVolfogHBTValue"));
336 m_VolFogHeightBiasTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderVolfogHBTime"));
337 m_VolFogHeightBiasTimeMinText = TextWidget.Cast(root.FindAnyWidget("TextMinVolfogHBTValue"));
338 m_VolFogHeightBiasTimeMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxVolfogHbTValue"));
339 m_VolFogHeightBiasTimeSetText = TextWidget.Cast(root.FindAnyWidget("TextVolfogHBTValueActual"));
340
341 // Wind Magnitude
342 m_WindMValueSetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindMValue"));
343 m_WindMValueSetSlider.SetMinMax(0, 20);
344 m_WindMValueSetSlider.SetStep(0.1);
345 m_WindMValueGetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindMActualValue"));
346 m_WindMValueGetSlider.SetMinMax(0, 20);
347 m_WindMValueGetSlider.SetStep(0.1);
348
349 m_WindMValueSetText = TextWidget.Cast(root.FindAnyWidget("TextWindMValueActual"));
350
351 m_WindMInterpolationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindMTarget"));
352 m_WindMDurationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindMDuration"));
353
354 m_WindMInterpolationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxWindMTarget"));
355 m_WindMDurationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxWindMDuration"));
356
357 m_WindMValueEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxWindMValue"));
358 m_WindMInterpolationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxWindMTarget"));
359 m_WindMDurationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxWindMDuration"));
360
361 // Wind Direction
362 m_WindDValueSetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindDValue"));
363 m_WindDValueSetSlider.SetMinMax(-3.14, 3.14);
364 m_WindDValueSetSlider.SetStep(0.01);
365
366 m_WindDValueGetSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindDActualValue"));
367 m_WindDValueGetSlider.SetMinMax(-3.14, 3.14);
368 m_WindDValueGetSlider.SetStep(0.01);
369
370 m_WindDValueSetText = TextWidget.Cast(root.FindAnyWidget("TextWindDValueActual"));
371
372 m_WindDInterpolationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindDTarget"));
373 m_WindDDurationTimeSlider = SliderWidget.Cast(root.FindAnyWidget("SliderWindDDuration"));
374
375 m_WindDInterpolationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxWindDTarget"));
376 m_WindDDurationMaxText = TextWidget.Cast(root.FindAnyWidget("TextMaxWindDDuration"));
377
378 m_WindDValueEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxWindDValue"));
379 m_WindDInterpolationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxWindDTarget"));
380 m_WindDDurationEditbox = EditBoxWidget.Cast(root.FindAnyWidget("EditBoxWindDDuration"));
381
382 //Other
383 m_HideUIButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonHide"));
384 m_HideUIIcon = ImageWidget.Cast(root.FindAnyWidget("ButtonHideIcon"));
385 m_HideUIIcon.LoadImageFile(0, "set:dayz_gui image:PasswordEyeOpen");
386 m_HideUIIcon.LoadImageFile(1, "set:dayz_gui image:PasswordEyeClose");
387 m_HideUIIcon.SetImage(1);
388
389 m_CopyButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonCopy"));
390 m_PasteButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonPaste"));
391 m_ResetButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonReset"));
392 m_UpdateButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonUpdate"));
393 m_ApplyButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonApply"));
394
395 m_LoadPresetButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonLoadPreset"));
396 m_DeletePresetButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonDeletePreset"));
397 m_SavePresetButton = ButtonWidget.Cast(root.FindAnyWidget("ButtonSavePreset"));
398 m_WeatherPresetEditbox = EditBoxWidget.Cast(root.FindAnyWidget("WeatherPresetName"));
399
400 m_WeatherPresetsPanel = root.FindAnyWidget("WeatherPresetsPanel");
401 m_WeatherPresetsList = new ScriptConsolePresetsList(m_WeatherPresetsPanel, this);
402 m_WeatherPresetsList.m_ItemSelected.Insert(OnListItemSelected);
403
404 InitValues();
406 }
407
409 {
410 m_WeatherPresetsList.ClearList();
411
412 for (int i = 0; i < m_ConfigDebugProfile.GetWeatherPresets().Count(); i++)
413 {
414 ScriptConsoleWeatherPreset preset = m_ConfigDebugProfile.GetWeatherPresets()[i];
415 if (!preset)
416 {
417 ErrorEx("Could not load DOF preset entry!");
418 continue;
419 }
420
421 m_WeatherPresetsList.AddListItem(preset.Name, 0, i);
422 }
423 }
424
425 protected void ResetValues()
426 {
427 // FOG
428 m_FogValueEditbox.SetText("0");
429 m_FogDurationEditbox.SetText(DURATION_MAX.ToString());
430 m_FogInterpolationEditbox.SetText("0");
431
432 // OVERCAST
433 m_OvercastValueEditbox.SetText("0");
434 m_OvercastDurationEditbox.SetText(DURATION_MAX.ToString());
436
437 // Rain
438 m_RainValueEditbox.SetText("0");
439 m_RainDurationEditbox.SetText(DURATION_MAX.ToString());
440 m_RainInterpolationEditbox.SetText("0");
441
442 // Snowfall
443 m_SnowfallValueEditbox.SetText("0");
444 m_SnowfallDurationEditbox.SetText(DURATION_MAX.ToString());
446
447 // Vol Fog
450
451 m_VolFogHeightDensityEditbox.SetText("0");
453
454 m_VolFogHeightBiasEditbox.SetText("0");
456
457 // Wind Magnitude
458 m_WindMValueEditbox.SetText("0");
459 m_WindMDurationEditbox.SetText(DURATION_MAX.ToString());
460 m_WindMInterpolationEditbox.SetText("0");
461
462 // Wind Direction
463 m_WindDValueEditbox.SetText("0");
464 m_WindDDurationEditbox.SetText(DURATION_MAX.ToString());
465 m_WindDInterpolationEditbox.SetText("0");
466
468
469 //FOG
470 m_FogValue = 0;
473
474 // OVERCAST
475 m_OvercastValue = 0;
478
479 //RAIN
480 m_RainValue = 0;
483
484 //SNOWFALL
485 m_SnowfallValue = 0;
488
489 // Vol Fog
492
495
498
499 // Wind Magnitude
503
504 // Wind Direction
508 }
509
510 protected void InitValues(bool forceCurrent = false)
511 {
512 // FOG
513 float fogVal = m_FogValue;
514 if (forceCurrent || m_FogValue == -1)
515 {
516 fogVal = GetGame().GetWeather().GetFog().GetActual();
517 }
518 m_FogValueEditbox.SetText(fogVal.ToString());
519
521
522 if (m_FogDurationTimeValue == -1)
525
527 m_FogDurationMaxText.SetText(DURATION_MAX.ToString());
528
529 // OVERCAST
530 float overcastVal = m_OvercastValue;
531 if (forceCurrent || m_OvercastValue == -1)
532 {
533 overcastVal = GetGame().GetWeather().GetOvercast().GetActual();
534 }
535 m_OvercastValueEditbox.SetText(overcastVal.ToString());
536
538
539
543
545 m_OvercastDurationMaxText.SetText(DURATION_MAX.ToString());
546
547 // RAIN
548 float rainVal = m_RainValue;
549 if (forceCurrent || m_RainValue == -1)
550 {
551 rainVal = GetGame().GetWeather().GetRain().GetActual();
552 }
553
554 m_RainValueEditbox.SetText(rainVal.ToString());
556
557 if (m_RainDurationTimeValue == -1)
560
562 m_RainDurationMaxText.SetText(DURATION_MAX.ToString());
563
564 // SNOWFALL
565 float snowfallVal = m_SnowfallValue;
566 if (forceCurrent || m_SnowfallValue == -1)
567 {
568 snowfallVal = GetGame().GetWeather().GetSnowfall().GetActual();
569 }
570
571 m_SnowfallValueEditbox.SetText(snowfallVal.ToString());
573
577
579 m_SnowfallDurationMaxText.SetText(DURATION_MAX.ToString());
580
581 // VOLFOG
582 float volFogDistanceDensityValue = m_VolFogDistanceDensityValue;
583 if (forceCurrent || m_VolFogDistanceDensityValue == -1)
584 {
585 volFogDistanceDensityValue = GetGame().GetWeather().GetDynVolFogDistanceDensity();
586 }
587
588 m_VolFogDistanceDensityEditbox.SetText(volFogDistanceDensityValue.ToString());
589
592
593 float volFogHeightDensityValue = m_VolFogHeightDensityValue;
594 if (forceCurrent || m_VolFogHeightDensityValue == -1)
595 {
596 volFogHeightDensityValue = GetGame().GetWeather().GetDynVolFogHeightDensity();
597 }
598
599 m_VolFogHeightDensityEditbox.SetText(volFogHeightDensityValue.ToString());
600
603
604 float volFogHeightBiasValue = m_VolFogHeightBiasValue;
605 if (forceCurrent /*|| m_VolFogHeightBiasValue == -500*/)
606 {
607 volFogHeightBiasValue = GetGame().GetWeather().GetDynVolFogHeightBias();
608 }
609
610 m_VolFogHeightBiasEditbox.SetText(volFogHeightBiasValue.ToString());
611
614
615 // Wind Magnitude
616 float windMagnitudeVal = m_WindMagnitudeValue;
617 if (forceCurrent || m_WindMagnitudeValue == -1)
618 {
619 windMagnitudeVal = GetGame().GetWeather().GetWindMagnitude().GetActual();
620 }
621
622 m_WindMValueEditbox.SetText(windMagnitudeVal.ToString());
624
625 if (m_WindMDurationTimeValue == -1)
628
630 m_WindMDurationMaxText.SetText(DURATION_MAX.ToString());
631
632 // Wind Direction
633 float windDirectionVal = m_WindDirectionValue;
634 if (forceCurrent || m_WindDirectionValue == -1)
635 {
636 windDirectionVal = GetGame().GetWeather().GetWindDirection().GetActual();
637 }
638
639 m_WindDValueEditbox.SetText(windDirectionVal.ToString());
641
642 if (m_WindDDurationTimeValue == -1)
645
647 m_WindDDurationMaxText.SetText(DURATION_MAX.ToString());
648
650 }
651
652 protected void PasteValues(string clipboard)
653 {
654 TStringArray values = new TStringArray();
655 clipboard.Split(" ", values);
656 if (values.Count() >= 9)
657 {
658 // FOG
659 m_FogValueEditbox.SetText(values.Get(0));
660 m_FogInterpolationEditbox.SetText(values.Get(1));
661 m_FogDurationEditbox.SetText(values.Get(2));
662 // OVERCAST
663 m_OvercastValueEditbox.SetText(values.Get(3));
664 m_OvercastInterpolationEditbox.SetText(values.Get(4));
665 m_OvercastDurationEditbox.SetText(values.Get(5));
666 // RAIN
667 m_RainValueEditbox.SetText(values.Get(6));
668 m_RainInterpolationEditbox.SetText(values.Get(7));
669 m_RainDurationEditbox.SetText(values.Get(8));
670
671 if (values.Count() >= 12)
672 {
673 // SNOWFALL
674 m_SnowfallValueEditbox.SetText(values.Get(9));
675 m_SnowfallInterpolationEditbox.SetText(values.Get(10));
676 m_SnowfallDurationEditbox.SetText(values.Get(11));
677 }
678
679 if (values.Count() >= 18)
680 {
681 // VOL FOG
682 m_VolFogDistanceDensityEditbox.SetText(values.Get(12));
683 m_VolFogDistanceDensityTimeEditbox.SetText(values.Get(13));
684 m_VolFogHeightDensityEditbox.SetText(values.Get(14));
685 m_VolFogHeightDensityTimeEditbox.SetText(values.Get(15));
686 m_VolFogHeightBiasEditbox.SetText(values.Get(16));
687 m_VolFogHeightBiasTimeEditbox.SetText(values.Get(17));
688 }
689
690 if (values.Count() >= 24)
691 {
692 // WIND MAGNITUDE
693 m_WindMValueEditbox.SetText(values.Get(18));
694 m_WindMInterpolationEditbox.SetText(values.Get(19));
695 m_WindMDurationEditbox.SetText(values.Get(20));
696 // WIND DIRECTION
697 m_WindDValueEditbox.SetText(values.Get(21));
698 m_WindDInterpolationEditbox.SetText(values.Get(22));
699 m_WindDDurationEditbox.SetText(values.Get(23));
700 }
701 }
702 }
703
704 protected string CopyValues()
705 {
706 string output;
707
708 // FOG
709 output += m_FogValueEditbox.GetText();
710 output += " ";
711 output += m_FogInterpolationEditbox.GetText();
712 output += " ";
713 output += m_FogDurationEditbox.GetText();
714 output += " ";
715 // OVERCAST
716 output += m_OvercastValueEditbox.GetText();
717 output += " ";
718 output += m_OvercastInterpolationEditbox.GetText();
719 output += " ";
720 output += m_OvercastDurationEditbox.GetText();
721 output += " ";
722 // RAIN
723 output += m_RainValueEditbox.GetText();
724 output += " ";
725 output += m_RainInterpolationEditbox.GetText();
726 output += " ";
727 output += m_RainDurationEditbox.GetText();
728 output += " ";
729 // SNOWFALL
730 output += m_SnowfallValueEditbox.GetText();
731 output += " ";
732 output += m_SnowfallInterpolationEditbox.GetText();
733 output += " ";
734 output += m_SnowfallDurationEditbox.GetText();
735 output += " ";
736 // VOLFOG
737 output += m_VolFogDistanceDensityEditbox.GetText();
738 output += " ";
739 output += m_VolFogDistanceDensityTimeEditbox.GetText();
740 output += " ";
741 output += m_VolFogHeightDensityEditbox.GetText();
742 output += " ";
743 output += m_VolFogHeightDensityTimeEditbox.GetText();
744 output += " ";
745 output += m_VolFogHeightBiasEditbox.GetText();
746 output += " ";
747 output += m_VolFogHeightBiasTimeEditbox.GetText();
748 output += " ";
749 // WIND MAGNITUDE
750 output += m_WindMValueEditbox.GetText();
751 output += " ";
752 output += m_WindMInterpolationEditbox.GetText();
753 output += " ";
754 output += m_WindMDurationEditbox.GetText();
755 output += " ";
756 // WIND DIRECTION
757 output += m_WindDValueEditbox.GetText();
758 output += " ";
759 output += m_WindDInterpolationEditbox.GetText();
760 output += " ";
761 output += m_WindDDurationEditbox.GetText();
762
763 return output;
764 }
765
766 override bool OnChange(Widget w, int x, int y, bool finished)
767 {
768 bool rmbDrag = (GetMouseState(MouseState.RIGHT) & MB_PRESSED_MASK);
769 bool immDrag = (GetMouseState(MouseState.LEFT) & MB_PRESSED_MASK) && KeyState(KeyCode.KC_LSHIFT);
770
771 if (rmbDrag)
772 {
773 if (w == m_FogValueSetSlider)
774 {
775 m_OvercastValueSetSlider.SetCurrent(m_FogValueSetSlider.GetCurrent());
776 m_RainValueSetSlider.SetCurrent(m_FogValueSetSlider.GetCurrent());
777 m_SnowfallValueSetSlider.SetCurrent(m_FogValueSetSlider.GetCurrent());
778 }
779 else if (w == m_OvercastValueSetSlider)
780 {
781 m_FogValueSetSlider.SetCurrent(m_OvercastValueSetSlider.GetCurrent());
782 m_RainValueSetSlider.SetCurrent(m_OvercastValueSetSlider.GetCurrent());
783 m_SnowfallValueSetSlider.SetCurrent(m_OvercastValueSetSlider.GetCurrent());
784 }
785 else if (w == m_RainValueSetSlider)
786 {
787 m_FogValueSetSlider.SetCurrent(m_RainValueSetSlider.GetCurrent());
788 m_OvercastValueSetSlider.SetCurrent(m_RainValueSetSlider.GetCurrent());
789 m_SnowfallValueSetSlider.SetCurrent(m_RainValueSetSlider.GetCurrent());
790 }
791 else if (w == m_SnowfallValueSetSlider)
792 {
793 m_FogValueSetSlider.SetCurrent(m_SnowfallValueSetSlider.GetCurrent());
794 m_OvercastValueSetSlider.SetCurrent(m_SnowfallValueSetSlider.GetCurrent());
795 m_RainValueSetSlider.SetCurrent(m_SnowfallValueSetSlider.GetCurrent());
796 }
797 else if (w == m_FogInterpolationTimeSlider)
798 {
802 }
804 {
808 }
809
810 else if (w == m_RainInterpolationTimeSlider)
811 {
815 }
817 {
821 }
822 else if (w == m_FogDurationTimeSlider)
823 {
824 m_RainDurationTimeSlider.SetCurrent(m_FogDurationTimeSlider.GetCurrent());
827 }
828 else if (w == m_RainDurationTimeSlider)
829 {
830 m_FogDurationTimeSlider.SetCurrent(m_RainDurationTimeSlider.GetCurrent());
833 }
834 else if (w == m_OvercastDurationTimeSlider)
835 {
839 }
840 else if (w == m_SnowfallDurationTimeSlider)
841 {
845 }
846 }
847
848 SliderWidget slider = SliderWidget.Cast(w);
849 if (slider)
850 {
851 if ((rmbDrag||immDrag) && !m_RPCTimer.IsRunning())
852 {
854 m_RPCTimer.Run(0.25, this, "InvokeSendRPC");
855 }
857 return true;
858 }
859
860 EditBoxWidget box = EditBoxWidget.Cast(w);
861 if (box)
862 {
864 return true;
865 }
866
867 return false;
868 }
869
871 {
872 //fog
873 float editboxFogValue = m_FogValueEditbox.GetText().ToFloat();
874 m_FogValueSetSlider.SetCurrent(editboxFogValue * 100);
875
876 float editboxFogInterpolation = m_FogInterpolationEditbox.GetText().ToFloat();
877 m_FogInterpolationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxFogInterpolation) * 100);
878
879 float editboxFogDuration = m_FogDurationEditbox.GetText().ToFloat();
880 m_FogDurationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxFogDuration) * 100);
881
882 //overcast
883 float editboxOvercastValue = m_OvercastValueEditbox.GetText().ToFloat();
884 m_OvercastValueSetSlider.SetCurrent(editboxOvercastValue * 100);
885
886 float editboxOvercastInterpolation = m_OvercastInterpolationEditbox.GetText().ToFloat();
887 m_OvercastInterpolationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxOvercastInterpolation) * 100);
888
889 float editboxOvercastDuration = m_OvercastDurationEditbox.GetText().ToFloat();
890 m_OvercastDurationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxOvercastDuration) * 100);
891
892 //rain
893 float editboxRainValue = m_RainValueEditbox.GetText().ToFloat();
894 m_RainValueSetSlider.SetCurrent(editboxRainValue * 100);
895
896 float editboxRainInterpolation = m_RainInterpolationEditbox.GetText().ToFloat();
897 m_RainInterpolationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxRainInterpolation) * 100);
898
899 float editboxRainDuration = m_RainDurationEditbox.GetText().ToFloat();
900 m_RainDurationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxRainDuration) * 100);
901
902 //snowfall
903 float editboxSnowfallValue = m_SnowfallValueEditbox.GetText().ToFloat();
904 m_SnowfallValueSetSlider.SetCurrent(editboxSnowfallValue * 100);
905
906 float editboxSnowfallInterpolation = m_SnowfallInterpolationEditbox.GetText().ToFloat();
907 m_SnowfallInterpolationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxSnowfallInterpolation) * 100);
908
909 float editboxSnowfallDuration = m_SnowfallDurationEditbox.GetText().ToFloat();
910 m_SnowfallDurationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxSnowfallDuration) * 100);
911
912 // vol fog
913 float editboxVolFogDistanceDensity = m_VolFogDistanceDensityEditbox.GetText().ToFloat();
914 m_VolFogDistanceDensitySlider.SetCurrent(editboxVolFogDistanceDensity);
915
916 float editboxVolFogDistanceDensityTime = m_VolFogDistanceDensityTimeEditbox.GetText().ToFloat();
917 m_VolFogDistanceDensityTimeSlider.SetCurrent(Math.InverseLerp(0,DURATION_MAX,editboxVolFogDistanceDensityTime) * 100);
918
919 float editboxVolFogHeightDensity = m_VolFogHeightDensityEditbox.GetText().ToFloat();
920 m_VolFogHeightDensitySlider.SetCurrent(editboxVolFogHeightDensity);
921
922 float editboxVolFogHeightDensityTime = m_VolFogHeightDensityTimeEditbox.GetText().ToFloat();
923 m_VolFogHeightDensityTimeSlider.SetCurrent(Math.InverseLerp(0,DURATION_MAX,editboxVolFogHeightDensityTime) * 100);
924
925 float editboxVolFogHeightBias = m_VolFogHeightBiasEditbox.GetText().ToFloat();
926 m_VolFogHeightBiasSlider.SetCurrent(editboxVolFogHeightBias);
927
928 float editboxVolFogHeightBiasTime = m_VolFogHeightBiasTimeEditbox.GetText().ToFloat();
929 m_VolFogHeightBiasTimeSlider.SetCurrent(Math.InverseLerp(0,DURATION_MAX,editboxVolFogHeightBiasTime) * 100);
930
931 // wind magnitude
932 float editboxWindMValue = m_WindMValueEditbox.GetText().ToFloat();
933 m_WindMValueSetSlider.SetCurrent(editboxWindMValue);
934
935 float editboxWindMInterpolation = m_WindMInterpolationEditbox.GetText().ToFloat();
936 m_WindMInterpolationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxWindMInterpolation) * 100);
937
938 float editboxWindMDuration = m_WindMDurationEditbox.GetText().ToFloat();
939 m_WindMDurationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxWindMDuration) * 100);
940
941 // wind direction
942 float editboxWindDValue = m_WindDValueEditbox.GetText().ToFloat();
943 m_WindDValueSetSlider.SetCurrent(editboxWindDValue);
944
945 float editboxWindDInterpolation = m_WindDInterpolationEditbox.GetText().ToFloat();
946 m_WindDInterpolationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxWindDInterpolation) * 100);
947
948 float editboxWindDDuration = m_WindDDurationEditbox.GetText().ToFloat();
949 m_WindDDurationTimeSlider.SetCurrent(Math.InverseLerp(0,INTERPOLATION_MAX,editboxWindDDuration) * 100);
950 }
951
953 {
954 //fog
957
960
961 m_FogValue = m_FogValueSetSlider.GetCurrent() / 100;
962 m_FogValueEditbox.SetText(m_FogValue.ToString());
963
964 //overcast
967
970
971 m_OvercastValue = m_OvercastValueSetSlider.GetCurrent() / 100;
972 m_OvercastValueEditbox.SetText(m_OvercastValue.ToString());
973
974 //rain
977
980
981 m_RainValue = m_RainValueSetSlider.GetCurrent() / 100;
982 m_RainValueEditbox.SetText(m_RainValue.ToString());
983
984 //snowfall
987
990
991 m_SnowfallValue = m_SnowfallValueSetSlider.GetCurrent() / 100;
992 m_SnowfallValueEditbox.SetText(m_SnowfallValue.ToString());
993
994 // vol fog
997
1000
1003
1006
1009
1012
1013 //wind magnitude
1016
1019
1021 m_WindMValueEditbox.SetText(m_WindMagnitudeValue.ToString());
1022
1023 //wind direction
1026
1029
1031 m_WindDValueEditbox.SetText(m_WindDirectionValue.ToString());
1032 }
1033
1034 override bool OnClick(Widget w, int x, int y, int button)
1035 {
1036 if (w == m_HideUIButton)
1037 {
1039 }
1040 else if (w == m_ApplyButton)
1041 {
1043 return true;
1044 }
1045 else if (w == m_UpdateButton)
1046 {
1047 InitValues(true);
1048 return true;
1049 }
1050 else if (w == m_ResetButton)
1051 {
1052 ResetValues();
1053 InitValues(true);
1054 return true;
1055 }
1056 else if (w == m_CopyButton)
1057 {
1058 string output = CopyValues();
1059 GetGame().CopyToClipboard(output);
1060 return true;
1061 }
1062
1063 else if (w == m_PasteButton)
1064 {
1065 string input;
1066 GetGame().CopyFromClipboard(input);
1067 PasteValues(input);
1069 return true;
1070 }
1071 else if (w == m_LoadPresetButton)
1072 {
1074 return true;
1075 }
1076 else if (w == m_SavePresetButton)
1077 {
1079 return true;
1080 }
1081 else if (w == m_DeletePresetButton)
1082 {
1084 return true;
1085 }
1086
1087 return false;
1088 }
1089
1090 protected void SaveWeatherPreset()
1091 {
1092 if (m_IsSavingPreset || m_WeatherPresetEditbox.GetText() == "")
1093 return;
1094
1095 m_IsSavingPreset = true;
1096 m_ConfigDebugProfile.AddWeatherPreset(m_WeatherPresetEditbox.GetText(), m_OvercastValueEditbox.GetText().ToFloat(), m_RainValueEditbox.GetText().ToFloat(), m_SnowfallValueEditbox.GetText().ToFloat(), m_FogValueEditbox.GetText().ToFloat(), m_WindMValueEditbox.GetText().ToFloat(), m_WindDValueEditbox.GetText().ToFloat(), m_VolFogDistanceDensityEditbox.GetText().ToFloat(), m_VolFogHeightDensityEditbox.GetText().ToFloat(), m_VolFogHeightBiasEditbox.GetText().ToFloat());
1098 m_IsSavingPreset = false;
1099 }
1100
1101 protected void DeleteWeatherPreset()
1102 {
1104 return;
1105
1106 m_ConfigDebugProfile.RemoveWeatherPreset(m_SelectedWeatherPreset.Name);
1108 }
1109
1110 protected void LoadWeatherPreset()
1111 {
1113 return;
1114
1115 m_OvercastValueSetSlider.SetCurrent(m_SelectedWeatherPreset.WOvercast * 100);
1116 m_RainValueSetSlider.SetCurrent(m_SelectedWeatherPreset.WRain * 100);
1117 m_SnowfallValueSetSlider.SetCurrent(m_SelectedWeatherPreset.WSnow * 100);
1118 m_FogValueSetSlider.SetCurrent(m_SelectedWeatherPreset.WFog * 100);
1119 m_WindMValueSetSlider.SetCurrent(m_SelectedWeatherPreset.WWindMagnitude);
1124
1127 InvokeSendRPC();
1128 }
1129
1130 protected void OnListItemSelected(int row, int column)
1131 {
1132 m_SelectedWeatherPreset = m_ConfigDebugProfile.GetWeatherPresets().Get(row);
1134 }
1135
1136 protected void ToogleUIVisibility()
1137 {
1139 m_ScriptConsole.ShowMenuBackground(m_UIVisibilityState);
1140 m_Root.FindAnyWidget("WeatherRoot").Show(m_UIVisibilityState);
1142 }
1143
1144 //RPC data where each value is strickly as shown in the UI on the sliders
1146 {
1148 // FOG
1149 data.m_FogValue = m_FogValueSetSlider.GetCurrent() / 100;
1151 data.m_FogDuration = m_FogDurationTimeSlider.GetCurrent() / 100 * DURATION_MAX;
1152
1153 // Rain
1154 data.m_RainValue = m_RainValueSetSlider.GetCurrent() / 100;
1156 data.m_RainDuration = m_RainDurationTimeSlider.GetCurrent() / 100 * DURATION_MAX;
1157
1158 // OVERCAST
1159 data.m_OvercastValue = m_OvercastValueSetSlider.GetCurrent() / 100;
1162
1163 // SNOWFALL
1164 data.m_SnowfallValue = m_SnowfallValueSetSlider.GetCurrent() / 100;
1167
1168 // VOLFOG
1171
1174
1175 data.m_VolFogHeightBias = m_VolFogHeightBiasSlider.GetCurrent();
1177
1178 // Wind Magnitude
1179 data.m_WindMagnitudeValue = m_WindMValueSetSlider.GetCurrent();
1181 data.m_WindMDuration = m_WindMDurationTimeSlider.GetCurrent() / 100 * DURATION_MAX;
1182
1183 // Wind Direction
1184 data.m_WindDirectionValue = m_WindDValueSetSlider.GetCurrent();
1186 data.m_WindDDuration = m_WindDDurationTimeSlider.GetCurrent() / 100 * DURATION_MAX;
1187
1188 return data;
1189 }
1190
1191 //RPC data where the duration and interpolation times are forced(their slider values are ignored) to allow for immediate change and lasting effect
1193 {
1194 Print(ToString() + "::GetRPCDataImmediate");
1196 // FOG
1197 data.m_FogValue = m_FogValueSetSlider.GetCurrent() / 100;
1198 data.m_FogInterpolation = 0;
1199 data.m_FogDuration = 960;
1200
1201 // Rain
1202 data.m_RainValue = m_RainValueSetSlider.GetCurrent() / 100;
1203 data.m_RainInterpolation = 0;
1204 data.m_RainDuration = 960;
1205
1206 // OVERCAST
1207 data.m_OvercastValue = m_OvercastValueSetSlider.GetCurrent() / 100;
1208 data.m_OvercastInterpolation = 0;
1209 data.m_OvercastDuration = 960;
1210
1211 // SNOWFALL
1212 data.m_SnowfallValue = m_SnowfallValueSetSlider.GetCurrent() / 100;
1213 data.m_SnowfallInterpolation = 0;
1214 data.m_SnowfallDuration = 960;
1215
1216 // VOLFOG
1219
1222
1223 data.m_VolFogHeightBias = m_VolFogHeightBiasSlider.GetCurrent();
1225
1226 // Wind Magnitude
1227 data.m_WindMagnitudeValue = m_WindMValueSetSlider.GetCurrent();
1228 data.m_WindMInterpolation = 0;
1229 data.m_WindMDuration = 960;
1230
1231 // Wind Direction
1232 data.m_WindDirectionValue = m_WindDValueSetSlider.GetCurrent();
1233 data.m_WindDInterpolation = 0;
1234 data.m_WindDDuration = 960;
1235
1236 return data;
1237 }
1238
1239 protected void SendRPC(DebugWeatherRPCData data)
1240 {
1241 Print(ToString() + "::SendRPC");
1242 PlayerIdentity identity = null;
1243 if (GetGame().GetPlayer())
1244 {
1245 identity = GetGame().GetPlayer().GetIdentity();
1246 }
1247
1248 GetGame().RPCSingleParam(null, ERPCs.DEV_SET_WEATHER, new Param1<DebugWeatherRPCData>(data), true, identity);
1249 }
1250
1251 protected void InvokeSendRPC()
1252 {
1253 Print(ToString() + "::InvokeSendRPC");
1255 //m_RPCTimer.Stop();
1256 }
1257
1258 protected void UpdateWeatherValues()
1259 {
1260 float overcast = GetGame().GetWeather().GetOvercast().GetActual();
1261 m_OvercastValueGetSlider.SetCurrent(overcast * 100);
1262 m_OvercastValueSetText.SetText(overcast.ToString());
1263
1264 float fog = GetGame().GetWeather().GetFog().GetActual();
1265 m_FogValueGetSlider.SetCurrent(fog * 100);
1266 m_FogValueSetText.SetText(fog.ToString());
1267
1268 float rain = GetGame().GetWeather().GetRain().GetActual();
1269 m_RainValueGetSlider.SetCurrent(rain * 100);
1270 m_RainValueSetText.SetText(rain.ToString());
1271
1272 float snowfall = GetGame().GetWeather().GetSnowfall().GetActual();
1273 m_SnowfallValueGetSlider.SetCurrent(snowfall * 100);
1274 m_SnowfallValueSetText.SetText(snowfall.ToString());
1275
1276 float volFogDistanceDensity = GetGame().GetWeather().GetDynVolFogDistanceDensity();
1277 //m_VolFogDistanceDensitySlider.SetCurrent(volFogDistanceDensity * 100);
1278 m_VolFogDistanceDensitySetText.SetText(volFogDistanceDensity.ToString());
1279
1280 float volFogHeightDensity = GetGame().GetWeather().GetDynVolFogHeightDensity();
1281 //m_VolFogHeightDensitySlider.SetCurrent(volFogHeightDensity * 100);
1282 m_VolFogHeightDensitySetText.SetText(volFogHeightDensity.ToString());
1283
1284 float volFogHeightBias = GetGame().GetWeather().GetDynVolFogHeightBias();
1285 //m_VolFogHeightBiasSlider.SetCurrent(volFogHeightBias * 100);
1286 m_VolFogHeightBiasSetText.SetText(volFogHeightBias.ToString());
1287
1288 float windMagnitude = GetGame().GetWeather().GetWindMagnitude().GetActual();
1289 m_WindMValueGetSlider.SetCurrent(windMagnitude);
1290 m_WindMValueSetText.SetText(windMagnitude.ToString());
1291
1292 float windDirection = GetGame().GetWeather().GetWindDirection().GetActual();
1293 m_WindDValueGetSlider.SetCurrent(windDirection);
1294 m_WindDValueSetText.SetText(windDirection.ToString());
1295 }
1296
1297 override void Update(float timeslice)
1298 {
1299 super.Update(timeslice);
1300
1302
1303 m_IsCAPSPressed = KeyState(KeyCode.KC_CAPITAL);
1305 {
1306 if (GetGame() && GetGame().GetMission() && GetGame().GetUIManager())
1307 {
1311 }
1312 }
1314 {
1315 if (GetGame() && GetGame().GetMission() && GetGame().GetUIManager())
1316 {
1317 m_MouseMovementEnabled = false;
1320 }
1321 }
1322
1324 {
1325 m_CanUseMovement = true;
1326 GetGame().GetMission().RemoveActiveInputExcludes({"UAMoveForward", "UAMoveBack", "UAMoveLeft", "UAMoveRight", "UAWalkRunTemp"});
1327 }
1329 {
1330 m_CanUseMovement = false;
1331 GetGame().GetMission().AddActiveInputExcludes({"UAMoveForward", "UAMoveBack", "UAMoveLeft", "UAMoveRight", "UAWalkRunTemp"});
1332 }
1333 }
1334
1335 override bool OnMouseEnter(Widget w, int x, int y)
1336 {
1337 ButtonHighlight(w);
1338 return false;
1339 }
1340
1341 override bool OnMouseLeave(Widget w, Widget enterW, int x, int y)
1342 {
1343 ButtonNormal(w);
1344 return false;
1345 }
1346
1347 protected void ButtonHighlight(Widget w)
1348 {
1349 ButtonWidget wb;
1350 if (Class.CastTo(wb, w))
1351 {
1352 if (wb.GetName() == "ButtonHide")
1353 {
1354 ImageWidget iw = ImageWidget.Cast(wb.FindAnyWidget(wb.GetName() + "Icon"));
1355 iw.SetColor(ARGB(255, 0, 0, 0));
1356 }
1357 else
1358 {
1359 wb.SetTextColor(ARGB(255, 0, 0, 0));
1360 }
1361 }
1362 }
1363
1364 protected void ButtonNormal(Widget w)
1365 {
1366 ButtonWidget wb;
1367 if (Class.CastTo(wb, w))
1368 {
1369 if (wb.GetName() == "ButtonHide")
1370 {
1371 ImageWidget iw = ImageWidget.Cast(wb.FindAnyWidget(wb.GetName() + "Icon"));
1372 iw.SetColor(ARGB(255, 255, 255, 255));
1373 }
1374 else
1375 {
1376 wb.SetTextColor(ARGB(255, 255, 255, 255));
1377 }
1378 }
1379 }
1380}
1381
1383{
1385
1386 void ScriptConsoleWeatherWindTab(Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent = null)
1387 {
1388 m_Parent = parent;
1390 }
1391}
void SendRPC()
Определения DisplayStatus.c:167
ERPCs
Определения ERPCs.c:2
proto string ToString()
Icon x
Icon y
PlayerBase GetPlayer()
Определения ModifierBase.c:51
override void InitValues()
Определения PPERequestData.c:147
void ScriptConsoleWeatherPreset(string name, float overcast, float rain, float snow, float fog, float windMagnitude, float windDir, float volFogDD, float volFogHD, float volFogHB)
Определения PluginConfigDebugProfile.c:34
PluginConfigDebugProfile m_ConfigDebugProfile
Определения PluginItemDiagnostic.c:58
@ Count
Определения RandomGeneratorSyncManager.c:8
SliderWidget m_SnowfallValueGetSlider
Определения ScriptConsoleWeatherTab.c:77
static float m_OvercastInterpolationTimeValue
Определения ScriptConsoleWeatherTab.c:52
TextWidget m_WindMDurationMaxText
Определения ScriptConsoleWeatherTab.c:149
SliderWidget m_WindDInterpolationTimeSlider
Определения ScriptConsoleWeatherTab.c:165
ButtonWidget m_CopyButton
Определения ScriptConsoleWeatherTab.c:187
ButtonWidget m_HideUIButton
Определения ScriptConsoleWeatherTab.c:180
EditBoxWidget m_FogDurationEditbox
Определения ScriptConsoleWeatherTab.c:29
TextWidget m_VolFogHeightDensityMinText
Определения ScriptConsoleWeatherTab.c:110
SliderWidget m_OvercastValueGetSlider
Определения ScriptConsoleWeatherTab.c:37
void ToogleUIVisibility()
Определения ScriptConsoleWeatherTab.c:1136
DebugWeatherRPCData GetRPCDataNormal()
Определения ScriptConsoleWeatherTab.c:1145
static float m_RainInterpolationTimeValue
Определения ScriptConsoleWeatherTab.c:72
ScriptConsoleWeatherPreset m_SelectedWeatherPreset
Определения ScriptConsoleWeatherTab.c:197
void InvokeSendRPC()
Определения ScriptConsoleWeatherTab.c:1251
SliderWidget m_RainValueSetSlider
Определения ScriptConsoleWeatherTab.c:56
TextWidget m_VolFogHeightBiasMaxText
Определения ScriptConsoleWeatherTab.c:123
static float m_VolFogHeightBiasValue
Определения ScriptConsoleWeatherTab.c:136
bool m_IsCAPSPressed
Определения ScriptConsoleWeatherTab.c:200
bool m_MouseMovementEnabled
Определения ScriptConsoleWeatherTab.c:199
EditBoxWidget m_SnowfallValueEditbox
Определения ScriptConsoleWeatherTab.c:87
SliderWidget m_VolFogHeightDensityTimeSlider
Определения ScriptConsoleWeatherTab.c:115
SliderWidget m_VolFogHeightBiasTimeSlider
Определения ScriptConsoleWeatherTab.c:127
EditBoxWidget m_VolFogHeightBiasTimeEditbox
Определения ScriptConsoleWeatherTab.c:126
EditBoxWidget m_VolFogHeightBiasEditbox
Определения ScriptConsoleWeatherTab.c:120
void SaveWeatherPreset()
Определения ScriptConsoleWeatherTab.c:1090
EditBoxWidget m_VolFogDistanceDensityTimeEditbox
Определения ScriptConsoleWeatherTab.c:102
static float m_VolFogDistanceDensityValue
Определения ScriptConsoleWeatherTab.c:132
void ResetValues()
Определения ScriptConsoleWeatherTab.c:425
TextWidget m_VolFogHeightDensitySetText
Определения ScriptConsoleWeatherTab.c:112
TextWidget m_WindMValueSetText
Определения ScriptConsoleWeatherTab.c:143
void UpdateSliderValues()
Определения ScriptConsoleWeatherTab.c:870
TextWidget m_VolFogHeightBiasSetText
Определения ScriptConsoleWeatherTab.c:124
void UpdateWeatherValues()
Определения ScriptConsoleWeatherTab.c:1258
TextWidget m_VolFogHeightBiasMinText
Определения ScriptConsoleWeatherTab.c:122
static float m_WindMInterpolationTimeValue
Определения ScriptConsoleWeatherTab.c:156
void DeleteWeatherPreset()
Определения ScriptConsoleWeatherTab.c:1101
SliderWidget m_WindDDurationTimeSlider
Определения ScriptConsoleWeatherTab.c:166
static float m_WindDInterpolationTimeValue
Определения ScriptConsoleWeatherTab.c:176
SliderWidget m_VolFogDistanceDensityTimeSlider
Определения ScriptConsoleWeatherTab.c:103
TextWidget m_VolFogHeightBiasTimeMaxText
Определения ScriptConsoleWeatherTab.c:129
static float m_RainDurationTimeValue
Определения ScriptConsoleWeatherTab.c:73
bool m_IsSavingPreset
Определения ScriptConsoleWeatherTab.c:202
TextWidget m_WindDDurationMaxText
Определения ScriptConsoleWeatherTab.c:169
TextWidget m_SnowfallInterpolationMaxText
Определения ScriptConsoleWeatherTab.c:84
TextWidget m_VolFogDistanceDensitySetText
Определения ScriptConsoleWeatherTab.c:100
TextWidget m_VolFogHeightDensityTimeMaxText
Определения ScriptConsoleWeatherTab.c:117
static float m_SnowfallDurationTimeValue
Определения ScriptConsoleWeatherTab.c:93
EditBoxWidget m_FogValueEditbox
Определения ScriptConsoleWeatherTab.c:27
SliderWidget m_RainDurationTimeSlider
Определения ScriptConsoleWeatherTab.c:62
SliderWidget m_FogValueSetSlider
Определения ScriptConsoleWeatherTab.c:16
SliderWidget m_SnowfallValueSetSlider
Определения ScriptConsoleWeatherTab.c:76
SliderWidget m_FogValueGetSlider
Определения ScriptConsoleWeatherTab.c:17
EditBoxWidget m_SnowfallInterpolationEditbox
Определения ScriptConsoleWeatherTab.c:88
SliderWidget m_FogDurationTimeSlider
Определения ScriptConsoleWeatherTab.c:22
TextWidget m_VolFogDistanceDensityTimeMinText
Определения ScriptConsoleWeatherTab.c:104
EditBoxWidget m_OvercastDurationEditbox
Определения ScriptConsoleWeatherTab.c:49
EditBoxWidget m_WeatherPresetEditbox
Определения ScriptConsoleWeatherTab.c:194
static float m_VolFogHeightDensityValue
Определения ScriptConsoleWeatherTab.c:134
ButtonWidget m_LoadPresetButton
Определения ScriptConsoleWeatherTab.c:183
EditBoxWidget m_FogInterpolationEditbox
Определения ScriptConsoleWeatherTab.c:28
EditBoxWidget m_VolFogHeightDensityTimeEditbox
Определения ScriptConsoleWeatherTab.c:114
static float m_FogValue
Определения ScriptConsoleWeatherTab.c:31
ButtonWidget m_PasteButton
Определения ScriptConsoleWeatherTab.c:188
ButtonWidget m_ResetButton
Определения ScriptConsoleWeatherTab.c:189
void PasteValues(string clipboard)
Определения ScriptConsoleWeatherTab.c:652
SliderWidget m_OvercastInterpolationTimeSlider
Определения ScriptConsoleWeatherTab.c:41
TextWidget m_RainInterpolationMaxText
Определения ScriptConsoleWeatherTab.c:64
static float m_RainValue
Определения ScriptConsoleWeatherTab.c:71
static float m_VolFogHeightDensityTimeValue
Определения ScriptConsoleWeatherTab.c:135
TextWidget m_SnowfallValueSetText
Определения ScriptConsoleWeatherTab.c:79
SliderWidget m_WindMInterpolationTimeSlider
Определения ScriptConsoleWeatherTab.c:145
static float m_WindMagnitudeValue
Определения ScriptConsoleWeatherTab.c:155
EditBoxWidget m_WindMInterpolationEditbox
Определения ScriptConsoleWeatherTab.c:152
static float m_OvercastDurationTimeValue
Определения ScriptConsoleWeatherTab.c:53
static float m_WindDirectionValue
Определения ScriptConsoleWeatherTab.c:175
SliderWidget m_SnowfallInterpolationTimeSlider
Определения ScriptConsoleWeatherTab.c:81
void ScriptConsoleWeatherTab(Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent=null)
Определения ScriptConsoleWeatherTab.c:237
DebugWeatherRPCData GetRPCDataImmediate()
Определения ScriptConsoleWeatherTab.c:1192
EditBoxWidget m_VolFogHeightDensityEditbox
Определения ScriptConsoleWeatherTab.c:108
TextWidget m_SnowfallDurationMaxText
Определения ScriptConsoleWeatherTab.c:85
TextWidget m_VolFogDistanceDensityMinText
Определения ScriptConsoleWeatherTab.c:98
EditBoxWidget m_WindDValueEditbox
Определения ScriptConsoleWeatherTab.c:171
EditBoxWidget m_WindMDurationEditbox
Определения ScriptConsoleWeatherTab.c:153
ButtonWidget m_DeletePresetButton
Определения ScriptConsoleWeatherTab.c:184
TextWidget m_OvercastInterpolationMaxText
Определения ScriptConsoleWeatherTab.c:44
TextWidget m_WindDInterpolationMaxText
Определения ScriptConsoleWeatherTab.c:168
TextWidget m_VolFogHeightBiasTimeMinText
Определения ScriptConsoleWeatherTab.c:128
bool m_UIVisibilityState
Определения ScriptConsoleWeatherTab.c:196
SliderWidget m_RainInterpolationTimeSlider
Определения ScriptConsoleWeatherTab.c:61
string CopyValues()
Определения ScriptConsoleWeatherTab.c:704
static float m_SnowfallInterpolationTimeValue
Определения ScriptConsoleWeatherTab.c:92
void ReloadWeatherPresetsList()
Определения ScriptConsoleWeatherTab.c:408
SliderWidget m_RainValueGetSlider
Определения ScriptConsoleWeatherTab.c:57
TextWidget m_FogValueSetText
Определения ScriptConsoleWeatherTab.c:19
TextWidget m_FogInterpolationMaxText
Определения ScriptConsoleWeatherTab.c:24
Widget m_WeatherPresetsPanel
Определения ScriptConsoleWeatherTab.c:193
SliderWidget m_WindMValueSetSlider
Определения ScriptConsoleWeatherTab.c:140
TextWidget m_VolFogHeightDensityTimeMinText
Определения ScriptConsoleWeatherTab.c:116
static float m_WindDDurationTimeValue
Определения ScriptConsoleWeatherTab.c:177
TextWidget m_VolFogDistanceDensityTimeMaxText
Определения ScriptConsoleWeatherTab.c:105
static float m_VolFogHeightBiasTimeValue
Определения ScriptConsoleWeatherTab.c:137
class ScriptConsoleWeatherValues m_RPCTimer
static float m_WindMDurationTimeValue
Определения ScriptConsoleWeatherTab.c:157
void ~ScriptConsoleWeatherTab()
Определения ScriptConsoleWeatherTab.c:204
SliderWidget m_WindDValueSetSlider
Определения ScriptConsoleWeatherTab.c:160
TextWidget m_VolFogHeightBiasTimeSetText
Определения ScriptConsoleWeatherTab.c:130
TextWidget m_VolFogHeightDensityMaxText
Определения ScriptConsoleWeatherTab.c:111
void ButtonNormal(Widget w)
Определения ScriptConsoleWeatherTab.c:1364
EditBoxWidget m_WindMValueEditbox
Определения ScriptConsoleWeatherTab.c:151
TextWidget m_VolFogDistanceDensityTimeSetText
Определения ScriptConsoleWeatherTab.c:106
static float m_FogInterpolationTimeValue
Определения ScriptConsoleWeatherTab.c:32
SliderWidget m_WindMValueGetSlider
Определения ScriptConsoleWeatherTab.c:141
void LoadWeatherPreset()
Определения ScriptConsoleWeatherTab.c:1110
ButtonWidget m_SavePresetButton
Определения ScriptConsoleWeatherTab.c:185
SliderWidget m_SnowfallDurationTimeSlider
Определения ScriptConsoleWeatherTab.c:82
TextWidget m_RainDurationMaxText
Определения ScriptConsoleWeatherTab.c:65
EditBoxWidget m_RainInterpolationEditbox
Определения ScriptConsoleWeatherTab.c:68
TextWidget m_OvercastDurationMaxText
Определения ScriptConsoleWeatherTab.c:45
SliderWidget m_VolFogHeightBiasSlider
Определения ScriptConsoleWeatherTab.c:121
SliderWidget m_FogInterpolationTimeSlider
Определения ScriptConsoleWeatherTab.c:21
static float m_SnowfallValue
Определения ScriptConsoleWeatherTab.c:91
EditBoxWidget m_VolFogDistanceDensityEditbox
Определения ScriptConsoleWeatherTab.c:96
const int DURATION_MAX
Определения ScriptConsoleWeatherTab.c:13
SliderWidget m_WindMDurationTimeSlider
Определения ScriptConsoleWeatherTab.c:146
void OnListItemSelected(int row, int column)
Определения ScriptConsoleWeatherTab.c:1130
EditBoxWidget m_OvercastValueEditbox
Определения ScriptConsoleWeatherTab.c:47
TextWidget m_VolFogDistanceDensityMaxText
Определения ScriptConsoleWeatherTab.c:99
ButtonWidget m_ApplyButton
Определения ScriptConsoleWeatherTab.c:191
TextWidget m_VolFogHeightDensityTimeSetText
Определения ScriptConsoleWeatherTab.c:118
SliderWidget m_VolFogDistanceDensitySlider
Определения ScriptConsoleWeatherTab.c:97
EditBoxWidget m_SnowfallDurationEditbox
Определения ScriptConsoleWeatherTab.c:89
ref ScriptConsolePresetsList m_WeatherPresetsList
Определения ScriptConsoleWeatherTab.c:198
SliderWidget m_OvercastValueSetSlider
Определения ScriptConsoleWeatherTab.c:36
TextWidget m_WindMInterpolationMaxText
Определения ScriptConsoleWeatherTab.c:148
static float m_OvercastValue
Определения ScriptConsoleWeatherTab.c:51
SliderWidget m_VolFogHeightDensitySlider
Определения ScriptConsoleWeatherTab.c:109
TextWidget m_RainValueSetText
Определения ScriptConsoleWeatherTab.c:59
void UpdateEditboxValues()
Определения ScriptConsoleWeatherTab.c:952
static float m_VolFogDistanceDensityTimeValue
Определения ScriptConsoleWeatherTab.c:133
EditBoxWidget m_RainDurationEditbox
Определения ScriptConsoleWeatherTab.c:69
const int INTERPOLATION_MAX
Определения ScriptConsoleWeatherTab.c:12
EditBoxWidget m_RainValueEditbox
Определения ScriptConsoleWeatherTab.c:67
TextWidget m_OvercastValueSetText
Определения ScriptConsoleWeatherTab.c:39
static float m_FogDurationTimeValue
Определения ScriptConsoleWeatherTab.c:33
EditBoxWidget m_OvercastInterpolationEditbox
Определения ScriptConsoleWeatherTab.c:48
EditBoxWidget m_WindDDurationEditbox
Определения ScriptConsoleWeatherTab.c:173
ImageWidget m_HideUIIcon
Определения ScriptConsoleWeatherTab.c:181
TextWidget m_FogDurationMaxText
Определения ScriptConsoleWeatherTab.c:25
EditBoxWidget m_WindDInterpolationEditbox
Определения ScriptConsoleWeatherTab.c:172
ButtonWidget m_UpdateButton
Определения ScriptConsoleWeatherTab.c:190
TextWidget m_WindDValueSetText
Определения ScriptConsoleWeatherTab.c:163
bool m_CanUseMovement
Определения ScriptConsoleWeatherTab.c:201
SliderWidget m_WindDValueGetSlider
Определения ScriptConsoleWeatherTab.c:161
SliderWidget m_OvercastDurationTimeSlider
Определения ScriptConsoleWeatherTab.c:42
void ButtonHighlight(Widget w)
Определения ScriptConsoleWeatherTab.c:1347
Widget m_Root
Определения SizeToChild.c:91
proto native UIManager GetUIManager()
proto native void CopyToClipboard(string text)
proto native void RPCSingleParam(Object target, int rpc_type, Param param, bool guaranteed, PlayerIdentity recipient=null)
see CGame.RPC
proto native DayZPlayer GetPlayer()
proto native Weather GetWeather()
Returns weather controller object.
proto void CopyFromClipboard(out string text)
proto native Mission GetMission()
Super root of all classes in Enforce script.
Определения EnScript.c:11
float m_FogValue
Определения DebugWeatherRPCData.c:3
float m_RainDuration
Определения DebugWeatherRPCData.c:15
float m_OvercastInterpolation
Определения DebugWeatherRPCData.c:9
float m_SnowfallInterpolation
Определения DebugWeatherRPCData.c:11
float m_WindDirectionValue
Определения DebugWeatherRPCData.c:35
float m_SnowfallDuration
Определения DebugWeatherRPCData.c:16
float m_VolFogDistanceDensity
Определения DebugWeatherRPCData.c:18
float m_VolFogHeightBiasTime
Определения DebugWeatherRPCData.c:25
float m_WindMDuration
Определения DebugWeatherRPCData.c:33
float m_VolFogDistanceDensityTime
Определения DebugWeatherRPCData.c:19
float m_VolFogHeightDensityTime
Определения DebugWeatherRPCData.c:22
float m_WindDInterpolation
Определения DebugWeatherRPCData.c:36
float m_VolFogHeightDensity
Определения DebugWeatherRPCData.c:21
float m_SnowfallValue
Определения DebugWeatherRPCData.c:6
float m_WindDDuration
Определения DebugWeatherRPCData.c:37
float m_OvercastValue
Определения DebugWeatherRPCData.c:4
float m_FogInterpolation
Определения DebugWeatherRPCData.c:8
float m_FogDuration
Определения DebugWeatherRPCData.c:13
float m_RainValue
Определения DebugWeatherRPCData.c:5
float m_RainInterpolation
Определения DebugWeatherRPCData.c:10
float m_WindMInterpolation
Определения DebugWeatherRPCData.c:32
float m_VolFogHeightBias
Определения DebugWeatherRPCData.c:24
float m_OvercastDuration
Определения DebugWeatherRPCData.c:14
float m_WindMagnitudeValue
Определения DebugWeatherRPCData.c:31
Определения EnWidgets.c:354
Определения EnMath.c:7
void AddActiveInputExcludes(array< string > excludes)
void RemoveActiveInputExcludes(array< string > excludes, bool bForceSupress=false)
deprecated
The class that will be instanced (moddable)
Определения gameplay.c:389
bool OnMouseLeave(Widget w, Widget enterW, int x, int y)
void ScriptConsoleTabBase(Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent=null)
Определения ScriptConsoleTabBase.c:14
bool OnMouseEnter(Widget w, int x, int y)
ScriptConsoleTabBase m_Parent
Определения ScriptConsoleTabBase.c:10
bool OnChange(Widget w, int x, int y, bool finished)
bool OnClick(Widget w, int x, int y, int button)
static void SetDefaultValues()
Определения ScriptConsoleWeatherTab.c:3
void ScriptConsoleWeatherWindTab(Widget root, ScriptConsole console, Widget button, ScriptConsoleTabBase parent=null)
Определения ScriptConsoleWeatherTab.c:1386
ScriptConsoleWeatherTab m_WeatherTab
Определения ScriptConsoleWeatherTab.c:1384
Определения EnWidgets.c:220
Определения DayZPlayerImplement.c:63
void ShowUICursor(bool visible)
Определения UIManager.c:244
proto native Fog GetFog()
Returns a fog phenomenon object.
proto native float GetDynVolFogHeightBias()
Returns the current 'dynamic' volumetric fog height bias in meters.
proto native WindMagnitude GetWindMagnitude()
Returns a wind magnitude phenomenon object.
proto native Snowfall GetSnowfall()
Returns a snowfall phenomenon object.
proto native WindDirection GetWindDirection()
Returns a wind direction phenomenon object.
proto native Rain GetRain()
Returns a rain phenomenon object.
proto native Overcast GetOvercast()
Returns an overcast phenomenon object.
proto native float GetDynVolFogHeightDensity()
Returns the current 'dynamic' volumetric fog height density.
proto native float GetDynVolFogDistanceDensity()
Returns the current 'dynamic' volumetric fog distance density.
proto native float GetActual()
Определения EnWidgets.c:190
proto string ToString(bool simple=true)
proto native CGame GetGame()
proto void Print(void var)
Prints content of variable to console/log.
enum ShapeType ErrorEx
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.
array< string > TStringArray
Определения EnScript.c:685
KeyCode
Определения EnSystem.c:157
proto native int KeyState(KeyCode key)
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...
MouseState
Определения EnSystem.c:311
proto native int GetMouseState(MouseState index)
void Split(string sample, out array< string > output)
Splits string into array of strings separated by 'sample'.
Определения EnString.c:396
proto native Widget GetFocus()
proto native volatile void Update()
Определения PlayerSoundManager.c:125
proto native Widget GetWidgetUnderCursor()
int ARGB(int a, int r, int g, int b)
Определения proto.c:322