2016-05-30 16:37:03 +00:00
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2017-02-10 18:28:27 +00:00
|
|
|
if (GVAR(enableDebugTrace) && {!isMultiplayer}) then {
|
2016-05-30 16:37:03 +00:00
|
|
|
GVAR(traceFrags) = true;
|
|
|
|
GVAR(autoTrace) = true;
|
|
|
|
};
|
|
|
|
|
2016-10-26 22:16:31 +00:00
|
|
|
if (isServer) then {
|
|
|
|
[QGVAR(frag_eh), {_this call FUNC(frago);}] call CBA_fnc_addEventHandler;
|
2016-05-30 16:37:03 +00:00
|
|
|
};
|
|
|
|
|
2016-06-09 12:24:45 +00:00
|
|
|
["ace_settingsInitialized", {
|
2016-05-30 16:37:03 +00:00
|
|
|
if (!GVAR(enabled)) exitWith {};
|
|
|
|
|
|
|
|
// Register fire event handler
|
2016-12-01 17:01:55 +00:00
|
|
|
["ace_firedPlayer", LINKFUNC(fired)] call CBA_fnc_addEventHandler;
|
|
|
|
["ace_firedNonPlayer", LINKFUNC(fired)] call CBA_fnc_addEventHandler;
|
|
|
|
["ace_firedPlayerVehicle", LINKFUNC(fired)] call CBA_fnc_addEventHandler;
|
|
|
|
["ace_firedNonPlayerVehicle", LINKFUNC(fired)] call CBA_fnc_addEventHandler;
|
2016-05-30 16:37:03 +00:00
|
|
|
|
2016-12-01 17:01:55 +00:00
|
|
|
[LINKFUNC(masterPFH), 0, []] call CBA_fnc_addPerFrameHandler;
|
2016-06-09 12:24:45 +00:00
|
|
|
}] call CBA_fnc_addEventHandler;
|
2016-05-30 16:37:03 +00:00
|
|
|
|
2016-10-26 22:16:31 +00:00
|
|
|
// Cache for ammo type configs
|
2016-12-01 17:01:55 +00:00
|
|
|
GVAR(cacheRoundsTypesToTrack) = [false] call CBA_fnc_createNamespace;
|
|
|
|
|
|
|
|
#ifdef DEBUG_ENABLED_FRAG
|
|
|
|
[true, true, 30] call FUNC(dev_debugAmmo);
|
|
|
|
#endif
|
|
|
|
|