Skip to content

Commit

Permalink
Prevent opening the medical menu if the player is unconscious (#6915)
Browse files Browse the repository at this point in the history
  • Loading branch information
TheMagnetar authored and PabstMirror committed Apr 2, 2019
1 parent db6dadb commit 24a533b
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions addons/medical_gui/functions/fnc_canOpenMenu.sqf
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
params ["_player", "_target"];

alive _player
&& {!IS_UNCONSCIOUS(_player)}
&& {!isNull _target}
&& {_player distance _target < GVAR(maxDistance) || {vehicle _player == vehicle _target}}
&& {GVAR(enableMedicalMenu) == 1 || {GVAR(enableMedicalMenu) == 2 && {vehicle _player != _player || {vehicle _target != _target}}}}

0 comments on commit 24a533b

Please sign in to comment.