diff --git a/addons/arsenal/missions/Arsenal.VR/CfgEventHandlers.hpp b/addons/arsenal/missions/Arsenal.VR/CfgEventHandlers.hpp index e75956f440..6e90665ffc 100644 --- a/addons/arsenal/missions/Arsenal.VR/CfgEventHandlers.hpp +++ b/addons/arsenal/missions/Arsenal.VR/CfgEventHandlers.hpp @@ -1,11 +1,12 @@ +// These files are from the VR mission, not the base addon folder class Extended_PreInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_preInit)); + init = QUOTE(call compile preprocessFileLineNumbers 'XEH_preInit.sqf'); }; }; class Extended_PostInit_EventHandlers { class ADDON { - init = QUOTE(call COMPILE_FILE(XEH_postInit)); + init = QUOTE(call compile preprocessFileLineNumbers 'XEH_postInit.sqf'); }; }; diff --git a/addons/arsenal/missions/Arsenal.VR/XEH_preInit.sqf b/addons/arsenal/missions/Arsenal.VR/XEH_preInit.sqf index 329d5fd1a5..6d6acca865 100644 --- a/addons/arsenal/missions/Arsenal.VR/XEH_preInit.sqf +++ b/addons/arsenal/missions/Arsenal.VR/XEH_preInit.sqf @@ -1,4 +1,6 @@ #include "script_component.hpp" +INFO("Loading VR Mission"); + PREP(onPause); PREP(createTarget); diff --git a/addons/arsenal/missions/Arsenal.VR/fnc_createTarget.sqf b/addons/arsenal/missions/Arsenal.VR/fnc_createTarget.sqf index 7ff1ea58e6..30eac04a7f 100644 --- a/addons/arsenal/missions/Arsenal.VR/fnc_createTarget.sqf +++ b/addons/arsenal/missions/Arsenal.VR/fnc_createTarget.sqf @@ -52,6 +52,10 @@ _target setVariable ["origin", _position]; _target addEventHandler ["killed", { params ["_target"]; + + // Killed may fire twice, 2nd will be null - https://github.com/acemod/ACE3/pull/7561 + if (isNull _target) exitWith { TRACE_1("Ignoring null death",_target); }; + private _position = _target getVariable ["origin", position _target]; private _varName = vehicleVarName _target;