Fix humanity hit for units in vehicles

The only change is a removal of this check and the corresponding
tabs/spacing:

if (_object == player) then {

That returns false if the player is in a vehicle. It is not needed since
PVCDZ_plr_Humanity EH only fires on the intended player now (sent with
PVC instead of PV).
This commit is contained in:
ebaydayz
2016-10-01 13:43:30 -04:00
parent 0a17804e36
commit 8ea21a2c81

View File

@@ -3,7 +3,6 @@ _object = _this select 0;
_change = _this select 1; _change = _this select 1;
_wait = if (count _this > 2) then { _this select 2 } else { 0 }; _wait = if (count _this > 2) then { _this select 2 } else { 0 };
if (_object == player) then {
_humanity = (player getVariable["humanity",0]) + _change; _humanity = (player getVariable["humanity",0]) + _change;
player setVariable["humanity",_humanity,true]; player setVariable["humanity",_humanity,true];
if (_change < 0) then { //non-bandit player can be "punished" in next "_wait" seconds w/o loosing humanity if (_change < 0) then { //non-bandit player can be "punished" in next "_wait" seconds w/o loosing humanity
@@ -72,4 +71,3 @@ if (_object == player) then {
}; };
*/ */
};