BIS_fnc_param
Jump to navigation
Jump to search
Description
- Description:
/* Description: Define script parameter Parameter(s): _this select 0: ARRAY - list of params _this select 1: NUMBER - selected index _this select 2 (Optional): ANY - default param (used when param is missing or of wrong type) - you can overload default value by setting 'BIS_fnc_<functionName>_<index>' _this select 3 (Optional): ARRAY - list of allowed type examples (e.g. ["",[],0,objnull]) _this select 4 (Optional): NUMBER - If value is ARRAY, checks if it has required number of elements Returns: ANY - either value from list of params, or default value */ /////////////////////////////////////////////////////////////////////////////////////////////////////////// #define FNC_DISABLEERRORS \ private ["_disableErrors"]; \ _disableErrors = false; // _disableErrors = if (count _this > 5) then {_this select 4} else {false}; #define FNC_TEXTTYPES \ private ["_textTypes"];\ _textTypes = "";\ {\ _textTypes = _textTypes + typename _x;\ if (_forEachIndex < count _types - 1) then {_textTypes = _textTypes + ", "};\ } foreach _types; ///////////////////////////////////////////////////////////////////////////////////////////////////////////
(Placeholder description extracted from the function header by BIS_fnc_exportFunctionsToWiki)- Execution:
- call
- Groups:
- Uncategorised
Syntax
- Syntax:
- Syntax needed
- Return Value:
- Return value needed
Examples
- Example 1:
Additional Information
- See also:
- See also needed
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note