ACE3/addons/medical_status/functions/fnc_isBeingCarried.sqf
Thomas Kooi 36f2c5fcc9 Minor code clean up (#6474)
* Minor code clean up
* refactor(medical): shorten some code
* refactor(medical): use macros for tourniquets
* refactor(medical): pull cache expiry values into script_macros_medical
2018-07-29 22:43:14 +01:00

24 lines
491 B
Plaintext

/*
* Author: PabstMirror
* Returns if a target is being carried. (from ace_dragging)
*
* Arguments:
* 0: Target Unit <OBJECT>
*
* Return Value:
* Is being carried <BOOL>
*
* Example:
* [bob] call ace_medical_status_fnc_isBeingCarried
*
* Public: No
*/
#include "script_component.hpp"
params ["_target"];
private _owner = _target getVariable [QEGVAR(common,owner), objNull];
!(isNull _owner)
&& {(_owner getVariable [QEGVAR(dragging,carriedObject), objNull]) == _target}