mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Nightvision - Improve NVG Brightness adjustment limits (#10136)
* Update fnc_changeNVGBrightness.sqf * Update XEH_postInit.sqf * Update addons/nightvision/XEH_postInit.sqf Co-authored-by: PabstMirror <pabstmirror@gmail.com> * Update XEH_postInit.sqf * Update fnc_changeNVGBrightness.sqf * Update nightvision-framework.md * load order independence Co-authored-by: PabstMirror <pabstmirror@gmail.com> --------- Co-authored-by: PabstMirror <pabstmirror@gmail.com> Co-authored-by: Grim <69561145+LinkIsGrim@users.noreply.github.com>
This commit is contained in:
parent
6a25e9365a
commit
90d855c2c5
@ -21,6 +21,9 @@ GVAR(ppeffectRadialBlur) = -1;
|
||||
GVAR(ppeffectColorCorrect) = -1;
|
||||
GVAR(ppeffectBlur) = -1;
|
||||
|
||||
if (isNil QGVAR(const_MaxBrightness)) then { GVAR(const_MaxBrightness) = 0; };
|
||||
if (isNil QGVAR(const_MinBrightness)) then { GVAR(const_MinBrightness) = -6; };
|
||||
|
||||
GVAR(isUsingMagnification) = false;
|
||||
|
||||
["CBA_settingsInitialized", {
|
||||
|
@ -23,7 +23,7 @@ private _effectsEnabled = GVAR(effectScaling) != 0;
|
||||
private _defaultBrightness = [-3, 0] select _effectsEnabled;
|
||||
|
||||
private _brightness = _player getVariable [QGVAR(NVGBrightness), _defaultBrightness];
|
||||
_brightness = ((_brightness + _changeInBrightness) min 0) max -6;
|
||||
_brightness = ((_brightness + _changeInBrightness) min GVAR(const_MaxBrightness)) max GVAR(const_MinBrightness);
|
||||
_player setVariable [QGVAR(NVGBrightness), _brightness, false];
|
||||
|
||||
// Display default setting as 0
|
||||
|
@ -43,3 +43,10 @@ Additional color presets
|
||||
```cpp
|
||||
ace_nightvision_colorPreset[] = {0.0, {0.0, 0.0, 0.0, 0.0}, {1.1, 0.8, 1.9, 0.9}, {1, 1, 6, 0.0}}; // White Phosphor Preset
|
||||
```
|
||||
|
||||
## 3. Brightness Limits
|
||||
|
||||
```cpp
|
||||
ace_nightvision_const_maxBrightness = 0; // Defaults, change at your leisure
|
||||
ace_nightvision_const_minBrightness = -6;
|
||||
```
|
||||
|
Loading…
Reference in New Issue
Block a user