diff --git a/addons/laser/XEH_post_init.sqf b/addons/laser/XEH_post_init.sqf index a20e0b32b3..6904ee6c47 100644 --- a/addons/laser/XEH_post_init.sqf +++ b/addons/laser/XEH_post_init.sqf @@ -1,2 +1,3 @@ #include "script_component.hpp" NO_DEDICATED; + diff --git a/addons/noradio/CfgEventhandlers.hpp b/addons/noradio/CfgEventhandlers.hpp index ef3aa7ad62..b9248ac888 100644 --- a/addons/noradio/CfgEventhandlers.hpp +++ b/addons/noradio/CfgEventhandlers.hpp @@ -1,6 +1,6 @@ class Extended_PostInit_EventHandlers { - class ADDON { - clientInit = "call compile preprocessFileLineNumbers '\AGM_NoRadio\clientInit.sqf'"; - serverInit = "call compile preprocessFileLineNumbers '\AGM_NoRadio\serverInit.sqf'"; - }; + class ADDON { + clientInit = "QUOTE(call COMPILE_FILE(XEH_post_initClient)); + serverInit = "QUOTE(call COMPILE_FILE(XEH_post_initServer)); + }; }; \ No newline at end of file diff --git a/addons/noradio/XEH_post_initClient.sqf b/addons/noradio/XEH_post_initClient.sqf index 66bb17d500..ba21ba5f34 100644 --- a/addons/noradio/XEH_post_initClient.sqf +++ b/addons/noradio/XEH_post_initClient.sqf @@ -3,18 +3,18 @@ #include "script_component.hpp" 0 spawn { - waitUntil {!isNull AGM_player}; + waitUntil {!isNull AGM_player}; - [AGM_player] call AGM_Core_fnc_muteUnit; - AGM_player setVariable ["AGM_NoRadio_isMuted", true, true]; + [AGM_player] call AGM_Core_fnc_muteUnit; + AGM_player setVariable [QGVAR(isMuted), true, true]; }; [missionNamespace, "playerChanged", { - [_this select 0] call AGM_Core_fnc_muteUnit; - (_this select 0) setVariable ["AGM_NoRadio_isMuted", true, true]; + [_this select 0] call AGM_Core_fnc_muteUnit; + (_this select 0) setVariable [QGVAR(isMuted), true, true]; - if (!((_this select 1) getVariable ["AGM_isUnconscious", false]) && {alive (_this select 1)}) then { - [_this select 1] call AGM_Core_fnc_unmuteUnit; - }; - (_this select 1) setVariable ["AGM_NoRadio_isMuted", false, true]; + if (!((_this select 1) getVariable ["AGM_isUnconscious", false]) && {alive (_this select 1)}) then { + [_this select 1] call AGM_Core_fnc_unmuteUnit; + }; + (_this select 1) setVariable [QGVAR(isMuted), false, true]; }] call AGM_Core_fnc_addCustomEventHandler; diff --git a/addons/noradio/XEH_post_initServer.sqf b/addons/noradio/XEH_post_initServer.sqf index 4c6077f25f..90b7473144 100644 --- a/addons/noradio/XEH_post_initServer.sqf +++ b/addons/noradio/XEH_post_initServer.sqf @@ -3,8 +3,8 @@ #include "script_component.hpp" addMissionEventHandler ["HandleDisconnect", { - if !((_this select 0) getVariable ["AGM_isUnconscious", false]) then { - _this call AGM_Core_fnc_unmuteUnit; - }; - (_this select 0) setVariable ["AGM_NoRadio_isMuted", false, true]; + if !((_this select 0) getVariable ["ACE_isUnconscious", false]) then { //@ToDo: ai waking up will be silent? + _this call EFUNC(common,unMuteUnit); + }; + (_this select 0) setVariable [QGVAR(isMuted), false, true]; }];