fn_isRadio
This commit is contained in:
parent
73de07c32c
commit
bb38079cec
|
@ -2,29 +2,31 @@
|
|||
File: fn_isRadio.sqf
|
||||
Author: Zharf - https://github.com/zharf
|
||||
Date: 2019-07-07
|
||||
Last Update: 2019-12-03
|
||||
Last Update: 2019-12-07
|
||||
License: MIT License - http://www.opensource.org/licenses/MIT
|
||||
|
||||
Description:
|
||||
Returns whether the provided item is a radio or not.
|
||||
Returns whether the classname is a TFAR/ACRE radio or not.
|
||||
|
||||
Parameter(s):
|
||||
_item - Description [STRING, defaults to ""]
|
||||
_class - Description [STRING, defaults to ""]
|
||||
|
||||
Returns:
|
||||
Item is a radio [BOOL]
|
||||
*/
|
||||
// TODO
|
||||
|
||||
params [
|
||||
["_item", "", [""]]
|
||||
["_class", "", [""]]
|
||||
];
|
||||
|
||||
if (_class isEqualTo "") exitWith {["Empty string given"] call BIS_fnc_error; false};
|
||||
|
||||
if ((isClass (configFile >> "CfgPatches" >> "tfar_core")) || (isClass (configFile >> "CfgPatches" >> "task_force_radio"))) exitWith {
|
||||
_item call TFAR_fnc_isRadio
|
||||
[_class] call TFAR_fnc_isRadio
|
||||
};
|
||||
|
||||
if (isClass (configFile >> "CfgPatches" >> "acre_api")) exitWith {
|
||||
[_item] call acre_api_fnc_isRadio
|
||||
[_class] call acre_api_fnc_isRadio
|
||||
};
|
||||
|
||||
false
|
||||
|
|
Loading…
Reference in New Issue