From 7c8ac4cc923248b7119892354191684d2288580d Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 18 Oct 2023 15:24:19 -0500 Subject: [PATCH 1/2] CSW - Handle static weapon be deleted --- addons/csw/functions/fnc_staticWeaponInit.sqf | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/csw/functions/fnc_staticWeaponInit.sqf b/addons/csw/functions/fnc_staticWeaponInit.sqf index 3b1d7ef66e6..fcef5df08e1 100644 --- a/addons/csw/functions/fnc_staticWeaponInit.sqf +++ b/addons/csw/functions/fnc_staticWeaponInit.sqf @@ -16,6 +16,7 @@ */ params ["_staticWeapon"]; +if (isNull _staticWeapon) exitWith { WARNING_1("%1 became null",_staticWeapon) }; private _typeOf = typeOf _staticWeapon; private _configOf = configOf _staticWeapon; private _configEnabled = (getNumber (_configOf >> "ace_csw" >> "enabled")) == 1; From 003d3c31cae0e2cc37eccdb952fc8ade1fe54c7a Mon Sep 17 00:00:00 2001 From: PabstMirror Date: Wed, 18 Oct 2023 15:46:12 -0500 Subject: [PATCH 2/2] add same fix to dragging --- addons/dragging/functions/fnc_initPerson.sqf | 1 + 1 file changed, 1 insertion(+) diff --git a/addons/dragging/functions/fnc_initPerson.sqf b/addons/dragging/functions/fnc_initPerson.sqf index fd166cfab98..6ac2b5d569d 100644 --- a/addons/dragging/functions/fnc_initPerson.sqf +++ b/addons/dragging/functions/fnc_initPerson.sqf @@ -16,6 +16,7 @@ */ params ["_unit"]; +if (isNull _unit) exitWith { WARNING_1("%1 became null",_unit) }; [_unit, true, [0, 1.1, 0.092], 180] call FUNC(setDraggable); [_unit, true, [0.4, -0.1, -1.25], 195] call FUNC(setCarryable); // Hard-coded selection: "LeftShoulder"