From b2824c82bbf2ca00b2d00f3c7677cb1347b5d892 Mon Sep 17 00:00:00 2001 From: jonpas Date: Sun, 16 Aug 2015 21:54:04 +0200 Subject: [PATCH] Removed redundant function --- addons/repair/functions/fnc_repairVehicle.sqf | 49 ------------------- 1 file changed, 49 deletions(-) delete mode 100644 addons/repair/functions/fnc_repairVehicle.sqf diff --git a/addons/repair/functions/fnc_repairVehicle.sqf b/addons/repair/functions/fnc_repairVehicle.sqf deleted file mode 100644 index 8313e4cdf1..0000000000 --- a/addons/repair/functions/fnc_repairVehicle.sqf +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Author: commy2 - * Starts a repair action with a progress bar. - * - * Arguments: - * 0: Unit that does the repairing - * 1: Vehicle to repair - * - * Return Value: - * None - * - * Example: - * [unit, vehicle, "hitpoint"] call ace_repair_fnc_repairVehicle - * - * Public: No - */ -#include "script_component.hpp" - -params ["_unit", "_vehicle", "_hitPoint"]; -TRACE_3("params",_unit,_vehicle,_hitPoint); - -// exit if not a valid hitpoint -if !(_hitPoint in ([_vehicle] call EFUNC(common,getHitPoints))) exitWith {}; - -// calculate time to fully repair the hitpoint -private ["_damage", "_time"]; - -_damage = _vehicle getHitPointDamage _hitPoint; - -_time = (5 + 10 * _damage) * ([1.5, 1] select ([_unit, GVAR(engineerSetting_Repair) + 1] call FUNC(isEngineer))); - -// get string of the hitpoint -private "_text"; -_text = format ["STR_ACE_Repair_%1", _hitPoint]; - -if (isLocalized _text) then { - _text = format [localize LSTRING(RepairingHitPoint), localize _text]; -} else { - _text = localize LSTRING(Repairing); -}; - -// open the loading bar -[_time, [_unit, _vehicle, _hitPoint], {_this call DFUNC(doRepair)}, {_this call DFUNC(doRepair)}, _text, {(_this select 0) call DFUNC(canRepair)}, []] call EFUNC(common,progressBar); - -// do animation -[_unit] call EFUNC(common,goKneeling); - -// @todo play sound