defines battalion info, integrates FBCB2 freqs and callsigns

This commit is contained in:
2024-02-01 01:23:21 -08:00
parent 8c40b107a5
commit 2d6fbcfcef
8 changed files with 404 additions and 33 deletions

View File

@@ -0,0 +1 @@
(missionConfigFile >> "BattalionInfo")

View File

@@ -0,0 +1,20 @@
params [
["_text", "", [""]],
["_padSide", "left", ["left", "right"]],
["_padChar", " ", [" "]],
["_padLength", 4, [4]]
];
// pad a string with a character to a certain length
if (_padSide == "left") then {
for "_i" from 1 to _padLength - count _text do {
_text = _padChar + _text;
};
};
if (_padSide == "right") then {
for "_i" from 1 to _padLength - count _text do {
_text = _text + _padChar;
};
};
_text

View File

@@ -0,0 +1,14 @@
params [
["_cfg", configNull, [configNull]],
["_code", {}, [{}]]
];
if (isNull _cfg) exitWith {["Provided config is null!"] call BIS_fnc_error};
[_cfg] call _code;
// get children and recurse
private _childCfgs = _cfg call BIS_fnc_returnChildren;
{
[_x, _code] call milsim_fnc_recurseSubclasses;
} forEach _childCfgs;