Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get missing groups as reinforcement #341

Merged
merged 4 commits into from
Jul 21, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -98,20 +98,20 @@ if (uiNamespace getVariable ["Achilles_var_nestedList_vehicleFactions", []] isEq
for "_categoryTvId" from 0 to ((_treeCtrl tvCount [0,_factionTvId]) - 1) do
{
private _categoryClass = _treeCtrl tvData [0,_factionTvId,_categoryTvId];
private _first = true;
for "_groupTvId" from 0 to ((_treeCtrl tvCount [0,_factionTvId,_categoryTvId]) - 1) do
{
private _groupName = _treeCtrl tvText [0,_factionTvId,_categoryTvId,_groupTvId];
private _groupClass = _treeCtrl tvData [0,_factionTvId,_categoryTvId,_groupTvId];
private _groupCfg = (configFile >> "CfgGroups" >> _sideClass >> _factionClass >> _categoryClass >> _groupClass);
if (_first and {not (getText (_x >> "vehicle") isKindOf "Man")} count (_groupCfg call Achilles_fnc_returnChildren) > 0) exitWith {};
if (not _factionIncluded) then
if ((_groupCfg call Achilles_fnc_returnChildren) findIf {not (getText (_x >> "vehicle") isKindOf "Man")} isEqualTo -1) then
{
_factionIncluded = true;
(_groupFactions select _sideId) pushBack _factionName;
if (not _factionIncluded) then
{
_factionIncluded = true;
(_groupFactions select _sideId) pushBack _factionName;
};
_groupsInFaction pushBack _groupCfg;
};
_groupsInFaction pushBack _groupCfg;
_first = false;
};
};
if (_factionIncluded) then
Expand Down