From cd9e5df7825161fe0cb97f1dd80d06d0e548d304 Mon Sep 17 00:00:00 2001 From: Glowbal Date: Sat, 5 Sep 2015 11:25:56 +0200 Subject: [PATCH] Clean up of handleDamage. Fixes some debug code --- addons/medical/functions/fnc_handleDamage.sqf | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/addons/medical/functions/fnc_handleDamage.sqf b/addons/medical/functions/fnc_handleDamage.sqf index 7226926700..fe06a47e9a 100644 --- a/addons/medical/functions/fnc_handleDamage.sqf +++ b/addons/medical/functions/fnc_handleDamage.sqf @@ -28,10 +28,10 @@ if !(local _unit) exitWith { private ["_damageReturn", "_typeOfDamage", "_minLethalDamage", "_newDamage", "_typeIndex", "_preventDeath"]; // bug, assumed fixed, @todo excessive testing, if nothing happens remove -/*if (typeName _projectile == "OBJECT") then { +if (typeName _projectile == "OBJECT") then { _projectile = typeOf _projectile; _this set [4, _projectile]; -};*/ +}; TRACE_3("ACE_DEBUG: HandleDamage",_selection,_damage, _unit); @@ -44,16 +44,14 @@ if (_selection != "" && {!(_selection in GVAR(SELECTIONS))}) exitWith {0}; //@to // Exit if we disable damage temporarily if !(_unit getVariable [QGVAR(allowDamage), true]) exitWith { + TRACE_3("ACE_DEBUG: HandleDamage damage disabled.",_selection,damage _unit, _unit); if (_selection == "") then { damage _unit } else { _unit getHit _selection }; - TRACE_3("ACE_DEBUG: HandleDamage damage disabled.",_selection,damage _unit, _unit); }; -//if (true) exitWith {nil};// - // Get return damage _damageReturn = _damage;