From 4809ef883bd22edfd6a6ab468fbdc7af8272e296 Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Sat, 24 Jun 2023 06:50:28 -0500 Subject: [PATCH] Optics - Increase width of hidePeripheralVision slightly to prevent gaps (#1568) --- addons/optics/fnc_initDisplayInterrupt.sqf | 2 +- addons/optics/fnc_loadScriptedOptic.sqf | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/addons/optics/fnc_initDisplayInterrupt.sqf b/addons/optics/fnc_initDisplayInterrupt.sqf index cda007f215..260923da1f 100644 --- a/addons/optics/fnc_initDisplayInterrupt.sqf +++ b/addons/optics/fnc_initDisplayInterrupt.sqf @@ -46,7 +46,7 @@ private _ctrlBlackRight = _display ctrlCreate ["RscText", IDC_BLACK_RIGHT]; private _width = THIRD_SCREEN_WIDTH; if (GVAR(hidePeripheralVision)) then { - _width = 0.5 - (_bodyPosition select 2)/2 - safezoneXAbs; + _width = 0.5 - (_bodyPosition select 2)/2 - safezoneXAbs + pixelW/2; }; _ctrlBlackLeft ctrlSetBackgroundColor [0,0,0,1]; diff --git a/addons/optics/fnc_loadScriptedOptic.sqf b/addons/optics/fnc_loadScriptedOptic.sqf index d1a982ec54..785d034c1d 100644 --- a/addons/optics/fnc_loadScriptedOptic.sqf +++ b/addons/optics/fnc_loadScriptedOptic.sqf @@ -85,7 +85,7 @@ _ctrlReticleSafezone ctrlCommit 0; private _width = THIRD_SCREEN_WIDTH; if (GVAR(hidePeripheralVision)) then { - _width = 0.5 - (_bodyPosition select 2)/2 - safezoneXAbs; + _width = 0.5 - (_bodyPosition select 2)/2 - safezoneXAbs + pixelW/2; }; _ctrlBlackLeft ctrlSetPositionW _width;