mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Added startCallback config entry
This commit is contained in:
parent
5c89232306
commit
0d329e0f63
@ -252,6 +252,7 @@ class GVAR(Actions) {
|
||||
callbackSuccess = QFUNC(treatmentCPR);
|
||||
callbackFailure = "";
|
||||
callbackProgress = QUOTE(!([(_this select 0) select 1] call EFUNC(common,isAwake)));
|
||||
callbackStart = "";
|
||||
animationPatient = "";
|
||||
animationPatientUnconscious = "AinjPpneMstpSnonWrflDnon_rolltoback";
|
||||
animationCaller = "AinvPknlMstpSlayW[wpn]Dnon_medic";
|
||||
|
@ -179,6 +179,19 @@ if (isArray (_config >> "sounds")) then {
|
||||
];
|
||||
};
|
||||
|
||||
private _startCallback = getText (_config >> "callbackStart");
|
||||
if (isNil _startCallback) then {
|
||||
_startCallback = compile _startCallback;
|
||||
} else {
|
||||
_startCallback = missionNamespace getVariable _startCallback;
|
||||
};
|
||||
|
||||
if !(_startCallback isEqualType {}) then {
|
||||
_startCallback = {TRACE_1("startCallback was NOT code",_startCallback)};
|
||||
};
|
||||
|
||||
[_caller, _target, _bodyPart, _className, _items, _usersOfItems] call _startCallback;
|
||||
|
||||
// start treatment
|
||||
[
|
||||
_treatmentTime,
|
||||
|
Loading…
Reference in New Issue
Block a user