2016-09-18 17:48:49 +00:00
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2019-06-03 15:31:46 +00:00
|
|
|
[QEGVAR(medical_status,initialized), {
|
|
|
|
params ["_unit"];
|
|
|
|
|
|
|
|
// Clear all saved medical logs
|
|
|
|
{
|
|
|
|
_unit setVariable [_x, nil, true];
|
|
|
|
} forEach (_unit getVariable [QEGVAR(medical,allLogs), []]);
|
|
|
|
|
|
|
|
_unit setVariable [QEGVAR(medical,allLogs), [], true];
|
|
|
|
|
|
|
|
[_unit] call FUNC(checkItems);
|
|
|
|
}] call CBA_fnc_addEventHandler;
|
|
|
|
|
2017-03-25 16:36:37 +00:00
|
|
|
["loadout", FUNC(checkItems)] call CBA_fnc_addPlayerEventHandler;
|
|
|
|
|
2019-06-03 15:31:46 +00:00
|
|
|
// Handle body removal and litter on server
|
2016-09-19 08:05:16 +00:00
|
|
|
if (isServer) then {
|
2019-06-03 15:31:46 +00:00
|
|
|
[QGVAR(createLitterServer), FUNC(createLitterServer)] call CBA_fnc_addEventHandler;
|
|
|
|
["ace_placedInBodyBag", FUNC(removeBody)] call CBA_fnc_addEventHandler;
|
2016-09-19 08:05:16 +00:00
|
|
|
};
|
2016-10-05 22:54:57 +00:00
|
|
|
|
2019-06-03 15:31:46 +00:00
|
|
|
// Treatment events
|
|
|
|
[QGVAR(bandageLocal), FUNC(bandageLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(checkBloodPressureLocal), FUNC(checkBloodPressureLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(checkPulseLocal), FUNC(checkPulseLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(cprLocal), FUNC(cprLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(fullHealLocal), FUNC(fullHealLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(ivBagLocal), FUNC(ivBagLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(medicationLocal), FUNC(medicationLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(placeInBodyBag), FUNC(placeInBodyBag)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(splintLocal), FUNC(splintLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
[QGVAR(tourniquetLocal), FUNC(tourniquetLocal)] call CBA_fnc_addEventHandler;
|
|
|
|
|
|
|
|
// Logging events
|
|
|
|
[QGVAR(addToLog), FUNC(addToLog)] call CBA_fnc_addEventHandler;
|
2019-04-07 22:41:28 +00:00
|
|
|
[QGVAR(addToTriageCard), FUNC(addToTriageCard)] call CBA_fnc_addEventHandler;
|