mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Minor improvements to handleTreatment
This commit is contained in:
parent
7e5806b834
commit
dcd42f55e8
@ -35,9 +35,14 @@ if ([_caller] call FUNC(isSetTreatmentMutex)) exitwith {
|
||||
[_caller, true] call FUNC(treatmentMutex);
|
||||
|
||||
if (!([_caller, _target, _removeItem] call FUNC(hasEquipment)) && _removeItem != "") exitwith {
|
||||
[_caller,"release"] call FUNC(treatmentMutex);
|
||||
[_caller, false] call FUNC(treatmentMutex);
|
||||
};
|
||||
|
||||
if (primaryWeapon _caller == "") then {
|
||||
_caller addWeapon "ACE_FakePrimaryWeapon";
|
||||
};
|
||||
_caller selectWeapon (primaryWeapon _unit);
|
||||
|
||||
// TODO make dynamic
|
||||
switch (toLower _category) do {
|
||||
case "bandage": {
|
||||
@ -53,7 +58,7 @@ switch (toLower _category) do {
|
||||
([_caller, _target, _selectionName, _removeItem] call FUNC(handleTreatment_Category_Airway));
|
||||
};
|
||||
default {
|
||||
// do not handle the request
|
||||
// Do not handle the request
|
||||
false;
|
||||
};
|
||||
};
|
||||
@ -66,4 +71,4 @@ if ([_target] call FUNC(hasMedicalEnabled)) then {
|
||||
[_target] call FUNC(addToInjuredCollection);
|
||||
};
|
||||
|
||||
true;
|
||||
true;
|
||||
|
Loading…
Reference in New Issue
Block a user