diff --git a/SQF/dayz_code/actions/repair_vehicle.sqf b/SQF/dayz_code/actions/repair_vehicle.sqf index 2b8b23977..1e9863494 100644 --- a/SQF/dayz_code/actions/repair_vehicle.sqf +++ b/SQF/dayz_code/actions/repair_vehicle.sqf @@ -23,10 +23,10 @@ _hitpoints = _vehicle call vehicle_getHitpoints; _damagePercent = str(round(_damage * 100))+"% Damage"; if (_damage > 0) then { _color = switch true do { - case (_damage >= 0 && _damage <= 0.25): {"color='#00ff00'"}; //green - case (_damage > 0.25 && _damage <= 0.50): {"color='#ffff00'"}; //yellow - case (_damage > 0.50 && _damage <= 0.75): {"color='#ff8800'"}; //orange - case (_damage > 0.75 && _damage <= 1): {"color='#ff0000'"}; //red + case (_damage <= 0.25): {"color='#00ff00'"}; //green + case (_damage <= 0.50): {"color='#ffff00'"}; //yellow + case (_damage <= 0.75): {"color='#ff8800'"}; //orange + default {"color='#ff0000'"}; //red }; _cmpt = format[localize "str_actions_medical_09",_cmpt,_damagePercent]; diff --git a/SQF/dayz_code/actions/salvage_vehicle.sqf b/SQF/dayz_code/actions/salvage_vehicle.sqf index d1f114d66..7e6f9b5a8 100644 --- a/SQF/dayz_code/actions/salvage_vehicle.sqf +++ b/SQF/dayz_code/actions/salvage_vehicle.sqf @@ -58,10 +58,10 @@ if (_is6WheelType) then { _damagePercent = str(round(_damage * 100))+"% Damage"; if (_damage < 1 && _damage > 0) then { //Tempfix for issue where certain hitpoints on some vehicles do not get damaged and allow infinite removal _color = switch true do { - case (_damage >= 0 && _damage <= 0.25): {"color='#00ff00'"}; //green - case (_damage > 0.25 && _damage <= 0.50): {"color='#ffff00'"}; //yellow - case (_damage > 0.50 && _damage <= 0.75): {"color='#ff8800'"}; //orange - case (_damage > 0.75 && _damage <= 1): {"color='#ff0000'"}; //red + case (_damage <= 0.25): {"color='#00ff00'"}; //green + case (_damage <= 0.50): {"color='#ffff00'"}; //yellow + case (_damage <= 0.75): {"color='#ff8800'"}; //orange + default {"color='#ff0000'"}; //red }; _string = format[localize "str_actions_repair_01",_cmpt,_damagePercent]; _string = format["%2",_color,_string]; //Remove - Part