Added support for displaying a treatment icon for the action

This commit is contained in:
Glowbal 2015-02-23 18:19:35 +01:00
parent fe0363ab48
commit 4a64716420

View File

@ -16,7 +16,7 @@
#include "script_component.hpp"
private ["_caller", "_target", "_selectionName", "_className", "_config", "_availableLevels", "_medicRequired", "_items", "_locations", "_return", "_callbackSuccess", "_callbackFailure", "_callbackProgress", "_treatmentTime", "_callerAnim", "_patietAnim"];
private ["_caller", "_target", "_selectionName", "_className", "_config", "_availableLevels", "_medicRequired", "_items", "_locations", "_return", "_callbackSuccess", "_callbackFailure", "_callbackProgress", "_treatmentTime", "_callerAnim", "_patietAnim", "_iconDisplayed"];
_caller = _this select 0;
_target = _this select 1;
_selectionName = _this select 2;
@ -91,4 +91,9 @@ if (vehicle _caller == _caller && {_callerAnim != ""}) then {
[_caller, _callerAnim] call EFUNC(common,doAnimation);
};
_iconDisplayed = getText (_config >> "actionIconPath");
if (_iconDisplayed != "") then {
[QGVAR(treatmentActionIcon), true, _iconDisplayed, [1,1,1,1], getNumber(_config >> "actionIconDisplayTime");] call EFUNC(common,displayIcon);
};
true;