mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
071a673f28
copied across treatment framework from medical and adjusted it to suit the repair actions
26 lines
550 B
Plaintext
26 lines
550 B
Plaintext
/*
|
|
* Author: Glowbal
|
|
* Use Equipment if any is available.
|
|
*
|
|
* Arguments:
|
|
* 0: Engineer <OBJECT>
|
|
* 2: Item <STRING>
|
|
*
|
|
* ReturnValue:
|
|
* <NIL>
|
|
*
|
|
* Public: Yes
|
|
*/
|
|
|
|
#include "script_component.hpp"
|
|
|
|
private ["_engineer", "_item", "_return","_crew"];
|
|
_engineer = _this select 0;
|
|
_item = _this select 1;
|
|
|
|
if ([_engineer, _item] call EFUNC(common,hasItem)) exitwith {
|
|
[[_engineer, _item], QUOTE(EFUNC(common,useItem)), _engineer] call EFUNC(common,execRemoteFnc); /* TODO Replace by event system */
|
|
[true, _engineer];
|
|
};
|
|
[false, objNull];
|