blob: 6039ff755905c76f24f26e3fa4141e4a083a56c3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
/* Adapted from BIS turret's function. */
private ['_entry','_turrestcount','_turrets'];
_entry = configFile >> 'CfgVehicles' >> _this >> 'Turrets';
vhasCommander = false;
vhasGunner = false;
_turrets = [_entry] Call Compile preprocessFile "Common\Functions\Common_GetConfigVehicleTurretsReturn.sqf";
tmp_overall = [];
if (count _turrets > 0) then {
[_turrets, []] Call Compile preprocessFile "Common\Functions\Common_GetConfigVehicleTurrets.sqf";
};
_turrestcount = count(tmp_overall);
if (vhasGunner) then {_turrestcount = _turrestcount - 1};
if (vhasCommander) then {_turrestcount = _turrestcount - 1};
// diag_log format ["%1 %2",_entry,tmp_overall];
[[vhasCommander,vhasGunner,count(tmp_overall)+1,_turrestcount], tmp_overall]
|