/* * Author: Glowbal, KoffeinFlummi * Increase the heart rate target of a local unit by given number during the given amount of seconds. * * Arguments: * 0: The unit * 1: value * 2: time until max. effect (seconds) * 3: time in system (seconds) * 4: callback * * Return Value: * None * * Public: Yes */ #include "script_component.hpp" params [["_unit", objNull, [objNull]], ["_value", 0, [0]], ["_timeTillMaxEffect", 1, [0]], ["_timeInSystem", 1, [0]], ["_callBack", {}, [{}]]]; private _adjustment = _unit getVariable [QEGVAR(medical,heartRateAdjustments), []]; _adjustment pushBack [_value, _timeTillMaxEffect, _timeInSystem, 0, _callBack]; _unit setVariable [QEGVAR(medical,heartRateAdjustments), _adjustment]; ["ace_heartRateAdjustmentAdded", [_unit, _value, _time]] call CBA_fnc_localEvent;