
All checks were successful
Build / Build (push) Successful in 28s
This commit refactors several client-side functions to improve code consistency and readability. - Standardizes function descriptions by removing redundant "Function: forge_client..." prefixes and "[Description]" sections, focusing on concise descriptions of the function's purpose. - Updates variable handling in arsenal functions to use GVAR and EGVARS for default values, improving consistency and reducing code duplication. - Removes the bank init function as it is no longer needed. - Adds a done variable to the preinit file.
29 lines
518 B
Plaintext
29 lines
518 B
Plaintext
#include "..\script_component.hpp"
|
|
|
|
/*
|
|
* Author: IDSolutions
|
|
* Converts a cargo array to an array of pairs
|
|
*
|
|
* Arguments:
|
|
* 0: Cargo Array <ARRAY>
|
|
* 1: Optional: Second Array <ARRAY>
|
|
*
|
|
* Return Value:
|
|
* Array of Pairs <ARRAY>
|
|
*
|
|
* Example:
|
|
* [[1, 2, 3], [4, 5, 6]] call forge_client_misc_fnc_cargoToPairs;
|
|
*
|
|
* Public: Yes
|
|
*/
|
|
|
|
private _array = [];
|
|
|
|
if (count _this > 1) then {
|
|
{
|
|
_array pushBack [_x, (_this select 1) select _forEachIndex];
|
|
true
|
|
} count (_this select 0);
|
|
};
|
|
|
|
_array |