#include "..\script_component.hpp" /* * Function: forge_client_medical_fnc_onKilled * Author: IDSolutions * * [Description] * Handles the unit's death. * * Arguments: * 0: Unit * 1: Killer * 2: Instigator * 3: Use Effects * * Return Value: * None * * Example: * [player, objNull, objNull, true] call forge_client_medical_fnc_onKilled; * * Public: Yes */ params ["_unit", "_killer", "_instigator", "_useEffects"]; if (!isPlayer _unit) exitWith {}; private _unitPos = getPosATL _unit; private _bodyBag = createVehicle [QCLASS(bodyBag), _unitPos, [], 0, "NONE"]; [_unit] call FUNC(saveDroppedWeapons); [_unit, _bodyBag] call FUNC(moveInventory);