2015-02-21 23:44:11 +00:00
|
|
|
/*
|
|
|
|
* Author: Glowbal
|
|
|
|
* Check if unit has a tourniquet applied to the specified bodypart
|
|
|
|
*
|
|
|
|
* Arguments:
|
|
|
|
* 0: The Unit <OBJECT>
|
2016-10-05 22:54:57 +00:00
|
|
|
* 1: Body Part <STRING>
|
2015-02-21 23:44:11 +00:00
|
|
|
*
|
|
|
|
* ReturnValue:
|
|
|
|
* Has tourniquet applied <BOOL>
|
|
|
|
*
|
|
|
|
* Public: Yes
|
|
|
|
*/
|
|
|
|
#include "script_component.hpp"
|
|
|
|
|
2016-10-05 22:54:57 +00:00
|
|
|
params ["_target", "_bodyPart"];
|
2015-02-21 23:44:11 +00:00
|
|
|
|
2016-12-07 10:32:01 +00:00
|
|
|
private _index = ALL_BODY_PARTS find toLower _bodyPart;
|
|
|
|
|
|
|
|
if (_index < 0) exitWith { false };
|
|
|
|
|
|
|
|
((_target getVariable [QGVAR(tourniquets), [0,0,0,0,0,0]]) select _index) > 0
|