ACE3/addons/hearing/XEH_preInit.sqf
BrettMayson 464ab0cefb
Tools - Add HEMTT SQF support and fix commas are not semicolons (#9663)
Co-authored-by: johnb432 <58661205+johnb432@users.noreply.github.com>
Co-authored-by: PabstMirror <pabstmirror@gmail.com>
Co-authored-by: jonpas <jonpas33@gmail.com>
2023-12-07 03:20:47 +00:00

27 lines
687 B
Plaintext

#include "script_component.hpp"
ADDON = false;
PREP_RECOMPILE_START;
#include "XEH_PREP.hpp"
PREP_RECOMPILE_END;
#include "initSettings.inc.sqf"
["CBA_loadoutSet", {
params ["_unit", "_loadout", "_extendedInfo"];
if (_extendedInfo getOrDefault ["ace_earplugs", false]) then {
_unit setVariable ["ACE_hasEarPlugsIn", true, true];
[[true]] remoteExec [QFUNC(updateVolume), _unit];
};
}] call CBA_fnc_addEventHandler;
["CBA_loadoutGet", {
params ["_unit", "_loadout", "_extendedInfo"];
if (_unit getVariable ["ACE_hasEarPlugsin", false]) then {
_extendedInfo set ["ace_earplugs", true]
};
}] call CBA_fnc_addEventHandler;
ADDON = true;