BIS_fnc_subSelect

From Bohemia Interactive Community
Revision as of 01:37, 17 February 2021 by Lou Montana (talk | contribs) (Text replacement - "\| *((\[\[[a-zA-Z0-9_ :\\\-\/|()]+\]\],? ?)+) * \}\}" to "|seealso= $1 }}")
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
Hover & click on the images for description

Description

Description:
Description needed
Execution:
call
Groups:
Arrays

Syntax

Syntax:
Syntax needed
Parameters:
array: Array array to select sub array from
start: Number index of array to begin sub-array. If negative, index is counted from the end of array
endOrLength: Number - index of array to end the sub-array. If ommitted, remainder of the array will be selected. If negative, it specifies the length of the sub-array (in absolute form)
Return Value:
Return value needed

Examples

Example 1:
_array = ["a","b",true,3,8]; [_array, 2] call BIS_fnc_subSelect; // returns [true,3,8]
Example 2:
[_array, -2] call BIS_fnc_subSelect; // returns [3,8]
Example 3:
[_array, 1, 3] call BIS_fnc_subSelect; // returns ["b",true,3]
Example 4:
[_array, 1, -2] call BIS_fnc_subSelect; // returns ["b",true]

Additional Information

See also:
selectcountselectRandomBIS_fnc_arrayShuffleBIS_fnc_randomIndex

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