Skip to content

Commit

Permalink
Update fnc_isInStableCondition.sqf
Browse files Browse the repository at this point in the history
  • Loading branch information
dgibso29 committed Jun 8, 2021
1 parent cc09981 commit ca2d59b
Showing 1 changed file with 1 addition and 18 deletions.
19 changes: 1 addition & 18 deletions addons/medical_status/functions/fnc_isInStableCondition.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -30,24 +30,7 @@ if (EGVAR(medical_treatment,allowPainPAK) == 0 && { IS_IN_PAIN(_unit) }) exitWit
if (EGVAR(medical_treatment,allowFracturesPAK) == 0 && { !(GET_FRACTURES(_unit) isEqualTo []) }) exitWith {false};


// Handle requiring at least bandaged wounds.
private _hasUnbandagedWounds = false;

if (EGVAR(medical_treatment,requiredWoundStatePAK) == 1) then
{
_openWounds = GET_OPEN_WOUNDS(_unit);
{
if(_x select 2 > 0) then
{
_hasUnbandagedWounds = true;
break;
};

} forEach _openWounds;
};

if(_hasUnbandagedWounds) exitWith { false };

if (EGVAR(medical_treatment,requiredWoundStatePAK) == 1) && {(GET_OPEN_WOUNDS(_unit) findIf {_x select 2 > 0}) != -1} exitWith {false};

// Require stitched wounds.
if (EGVAR(medical_treatment,requiredWoundStatePAK) == 2 && { !(count GET_OPEN_WOUNDS(_unit) == count GET_STITCHED_WOUNDS(_unit)) }) exitWith {false};
Expand Down

0 comments on commit ca2d59b

Please sign in to comment.