2018-09-17 19:19:29 +00:00
|
|
|
#include "script_component.hpp"
|
2015-07-03 21:14:23 +00:00
|
|
|
/*
|
|
|
|
* Author: Glowbal
|
2015-08-16 18:14:54 +00:00
|
|
|
* Check if vehicle is a engineering vehicle.
|
2015-07-03 21:14:23 +00:00
|
|
|
*
|
|
|
|
* Arguments:
|
2015-08-16 18:14:54 +00:00
|
|
|
* 0: Vehicle <OBJECT>
|
2015-07-03 21:14:23 +00:00
|
|
|
*
|
2017-06-08 13:31:51 +00:00
|
|
|
* Return Value:
|
2015-08-16 18:14:54 +00:00
|
|
|
* Is engineering vehicle <BOOL>
|
|
|
|
*
|
|
|
|
* Example:
|
|
|
|
* [vehicle] call ace_repair_fnc_isRepairVehicle
|
2015-07-03 21:14:23 +00:00
|
|
|
*
|
|
|
|
* Public: Yes
|
|
|
|
*/
|
|
|
|
|
2015-08-09 06:54:44 +00:00
|
|
|
params ["_vehicle"];
|
|
|
|
TRACE_1("params",_vehicle);
|
2015-07-03 21:14:23 +00:00
|
|
|
|
2015-11-10 02:11:48 +00:00
|
|
|
if (_vehicle isKindOf "CAManBase") exitWith {false};
|
2015-07-03 21:14:23 +00:00
|
|
|
|
2018-04-27 15:30:03 +00:00
|
|
|
// Value can be integer or boolean
|
2021-02-18 18:58:08 +00:00
|
|
|
private _value = _vehicle getVariable ["ACE_isRepairVehicle", getNumber (configOf _vehicle >> QGVAR(canRepair))];
|
2018-04-27 15:30:03 +00:00
|
|
|
_value in [1, true] // return
|