Jump to content
Sign in to follow this  
McArcher

Adding crew to vehicles

Recommended Posts

How can add crew to vehicles by scripts?

Can I automatically create vehicle with driver or if it is heavy vehicle with gunner/commander ? Or I should do it manually ?

---------- Post added at 05:24 ---------- Previous post was at 05:01 ----------

oh....

I have found...

moveInDriver, moveInGunner, moveInCommander, moveInCargo...

but.. what is moveInTurret ? Why not gunner?

---------- Post added at 05:24 ---------- Previous post was at 05:24 ----------

ah.. maybe for second turret if it exists...?

Share this post


Link to post
Share on other sites

Yes, moveInTurret can be used for additional weapons on a vehicle, e.g. the additional door guns on some of the helos.

But you should also look at the BIS "functions" module and read the help info for it - just do a search for BIS_fnc_help and you'll find out how to set it up. There's some functions there for spawning vehicles with complete crews.

Share this post


Link to post
Share on other sites

I'm trying to spawn Infantry, Light and Heavy vehicles by this script. But drivers/gunners/commanders don't get in vehicles and error is given after diag_log's output about numbers of different people.

// mca_resistance_init.sqf
// version 1.0s

if (isServer) then
{

ResHQ = createCenter resistance;	
mcti_resistance_infantry = [ "CDF_Soldier_Strela", "CDF_Soldier_RPG", "CDF_Soldier_AR", "CDF_Soldier_Crew", "CDF_Soldier_Engineer", "CDF_Commander", "CDF_Soldier_GL", "CDF_Soldier_MG", "CDF_Soldier_Marksman", "CDF_Soldier_Medic", "CDF_Soldier_Militia", "CDF_Soldier_Officer", "CDF_Soldier_Pilot", "CDF_Soldier", "CDF_Soldier_Sniper", "CDF_Soldier_Light", "CDF_Soldier_Spotter", "CDF_Soldier_TL" ];

mcti_resistance_lightVehicles = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF" ];	
mcti_resistance_heavyVehicles = ["BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF"];

mcti_resistance_DriverNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF" ];	
mcti_resistance_GunnerNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF" ];
mcti_resistance_CommNeeded = [ "T72_CDF" ];

publicVariable "mcti_resistance_infantry"; 
publicVariable "mcti_resistance_lightVehicles"; 
publicVariable "mcti_resistance_heavyVehicles"; 

publicVariable "mcti_resistance_DriverNeeded"; 
publicVariable "mcti_resistance_GunnerNeeded"; 
publicVariable "mcti_resistance_CommNeeded"; 

private ["_i", "_xf", "_yf", "_townSize", "_diff", "_radiusMax", "_radius", "_angle", "_povorot", "_nInfantry", "_nLightVeh", "_nArmored", "_cInf", "_cLV", "_cArm", "_j", "_DriverNeeded", "_vehClass", "_unitCountTown", "_unitCountTotal", "_pos", "_lvCount", "_hvCount", "_driversCount", "_gunnersCount", "_commCount"];
_cInf = count mcti_resistance_infantry - 1;
_cLV = count mcti_resistance_lightVehicles - 1;
_cArm = count mcti_resistance_heavyVehicles - 1;
_diff = mcti_resistance_difficulty; // 1 или 2
_unitCountTotal = 0;
_lvCount = 0;
_hvCount = 0;
_driversCount = 0;
_gunnersCount = 0;
_commCount = 0;

if (mcti_resistance_enabled) then
{
	_i = 0;
	{
		// заÑелÑем каждый i-ый город
		// surfaceIsWater [x, y] 
		tmp_group = createGroup resistance; 
		_unitCountTown = 0;
		_xf = _x select 0;
		_yf = _x select 1; // X,Y координаты флага города
		_townSize = mcti_town_sizes select _i;
		_radiusMax = _townSize * 80; //метров

		// numbers of units in town
		_nInfantry = round (random (_townSize * (_diff * 3 )));
		_nLightVeh = round (random (_townSize * (_diff * 1.0 )));
		_nArmored = round (random (_townSize * (_diff * 0.75 )));
		// placing Infantry
		for [{_j=0},{_j<_nInfantry},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
			tmp_unit setDir (deg _povorot); 
			tmp_unit disableAI "AUTOTARGET"; 
			tmp_unit disableAI "TARGET"; 
			tmp_unit disableAI "MOVE"; 
		};

		// placing Light Vehicles
		for [{_j=0},{_j<_nLightVeh},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_lvCount = _lvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_vehClass = (mcti_resistance_lightVehicles select (round (random _cLV))); 
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			tmp_veh = _vehClass createVehicle _pos;
			tmp_veh setDir (deg _povorot); 

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				while {surfaceIsWater _pos} do 
				{
					_radius = round (random _radiusMax);
					_angle = random (2 * pi);
					_povorot = random (2 * pi);
					_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				};
				tmp_unit2 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit2 setDir (deg _povorot); 
				tmp_unit2 moveInDriver tmp_veh; 
				tmp_unit2 disableAI "AUTOTARGET"; 
				tmp_unit2 disableAI "TARGET"; 
				tmp_unit2 disableAI "MOVE"; 
			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				while {surfaceIsWater _pos} do 
				{
					_radius = round (random _radiusMax);
					_angle = random (2 * pi);
					_povorot = random (2 * pi);
					_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				};
				tmp_unit3 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit3 setDir (deg _povorot); 
				tmp_unit3 setUnitPos "Middle"; 
				tmp_unit3 moveInGunner tmp_veh; 
				tmp_unit3 disableAI "AUTOTARGET"; 
				tmp_unit3 disableAI "TARGET"; 
				tmp_unit3 disableAI "MOVE"; 
			};
		};

		// placing Heavy Vehicles
		for [{_j=0},{_j<_nArmored},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_hvCount = _hvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			_vehClass = (mcti_resistance_heavyVehicles select (round (random _cArm)));
			tmp_veh = _vehClass createVehicle _pos;
			tmp_veh setDir (deg _povorot); 

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				while {surfaceIsWater _pos} do 
				{
					_radius = round (random _radiusMax);
					_angle = random (2 * pi);
					_povorot = random (2 * pi);
					_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				};
				tmp_unit2 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit2 setDir (deg _povorot); 
				tmp_unit2 moveInDriver tmp_veh; 
				tmp_unit2 disableAI "AUTOTARGET"; 
				tmp_unit2 disableAI "TARGET"; 
				tmp_unit2 disableAI "MOVE"; 
			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				while {surfaceIsWater _pos} do 
				{
					_radius = round (random _radiusMax);
					_angle = random (2 * pi);
					_povorot = random (2 * pi);
					_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				};
				tmp_unit3 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit3 setDir (deg _povorot); 
				tmp_unit3 moveInGunner tmp_veh; 
				tmp_unit3 disableAI "AUTOTARGET"; 
				tmp_unit3 disableAI "TARGET"; 
				tmp_unit3 disableAI "MOVE"; 
			};

			//commander
			if (_vehClass in mcti_resistance_CommNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_commCount = _commCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				while {surfaceIsWater _pos} do 
				{
					_radius = round (random _radiusMax);
					_angle = random (2 * pi);
					_povorot = random (2 * pi);
					_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
				};
				tmp_unit4 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit4 setDir (deg _povorot); 
				tmp_unit4 moveInCommander tmp_veh; 
				tmp_unit4 disableAI "AUTOTARGET"; 
				tmp_unit4 disableAI "TARGET"; 
				tmp_unit4 disableAI "MOVE"; 
			};

		};

		// Ñледующий город
		_unitCountTotal = _unitCountTotal + _unitCountTown;
		_i = _i + 1;
	} forEach mcti_town_markerCoords;

};
diag_log format["Total Units: %1, Light Vehicles: %2, Heavy Vehicles: %3, Drivers: %4, Gunners: %5, Commanders: %6", _unitCountTotal, _lvCount, _hvCount, _driversCount, _gunnersCount, _commCount]; //dbg////////

};

2010/01/07, 6:58:42 Error in expression <e _area == typename []) then {_position distance _center < _maxdis} else {[_area>

2010/01/07, 6:58:42 Error position: <distance _center < _maxdis} else {[_area>

2010/01/07, 6:58:42 Error distance: Тип ЧиÑло, ожидаетÑÑ ÐœÐ½Ð¾Ð¶ÐµÑтво,Объект,Location

2010/01/07, 6:58:42 File ca\modules\functions\systems\fn_locations.sqf, line 114

Could you help me with this error and drivers, please.

Share this post


Link to post
Share on other sites
2010/01/07, 6:58:42 Error in expression <e _area == typename []) then {_position distance _center < _maxdis} else {[_area>

there is no _area in the code you posted so there is a different script giving you errors

there is also assignasgunner

assignascargo

assignasdriver

using these commands will make the unit walk to the vehicle and get in not just teleport like movein command

Edited by Zonekiller

Share this post


Link to post
Share on other sites
there is no _area in the code you posted so there is a different script giving you errors

there is also assignasgunner

assignascargo

assignasdriver

using these commands will make the unit walk to the vehicle and get in not just teleport like movein command

of course!! it is game core's file ! look at the

ca\modules\functions\systems\fn_locations.sqf
! all my scripts except one or two have "mca_" prefixes. It is game's file!

Share this post


Link to post
Share on other sites

second version of this script, optimized

* added groups, 1 group per town

* changed to assignAs*** commands

* _pos of crew is now same _pos as vehicle's

* waiting for game to start and last for 10 seconds (i thought that was the problem, but not this..... :( )

but drivers/gunners/commanders still stand near vehicles and don't get in them... and error again (at the end of message).

Please help! What is wrong here? I think someone has already been using spawning many AIs via script and had same error before. Share your experience please.

// mca_resistance_init.sqf
// version 1.0s

if (isServer) then
{
waitUntil { time > 10};

mcti_resistance_infantry = [ "CDF_Soldier_Strela", "CDF_Soldier_RPG", "CDF_Soldier_AR", "CDF_Soldier_Crew", "CDF_Soldier_Engineer", "CDF_Commander", "CDF_Soldier_GL", "CDF_Soldier_MG", "CDF_Soldier_Marksman", "CDF_Soldier_Medic", "CDF_Soldier_Militia", "CDF_Soldier_Officer", "CDF_Soldier_Pilot", "CDF_Soldier", "CDF_Soldier_Sniper", "CDF_Soldier_Light", "CDF_Soldier_Spotter" ];
// "CDF_Soldier_TL"

mcti_resistance_lightVehicles = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF" ];	
mcti_resistance_heavyVehicles = ["BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF"];

mcti_resistance_DriverNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF" ];	
mcti_resistance_GunnerNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF" ];
mcti_resistance_CommNeeded = [ "T72_CDF" ];

publicVariable "mcti_resistance_infantry"; 
publicVariable "mcti_resistance_lightVehicles"; 
publicVariable "mcti_resistance_heavyVehicles"; 

publicVariable "mcti_resistance_DriverNeeded"; 
publicVariable "mcti_resistance_GunnerNeeded"; 
publicVariable "mcti_resistance_CommNeeded"; 

private ["_i", "_xf", "_yf", "_townSize", "_diff", "_radiusMax", "_radius", "_angle", "_povorot", "_nInfantry", "_nLightVeh", "_nArmored", "_cInf", "_cLV", "_cArm", "_j", "_DriverNeeded", "_vehClass", "_unitCountTown", "_unitCountTotal", "_pos", "_lvCount", "_hvCount", "_driversCount", "_gunnersCount", "_commCount"];
_cInf = count mcti_resistance_infantry - 1;
_cLV = count mcti_resistance_lightVehicles - 1;
_cArm = count mcti_resistance_heavyVehicles - 1;
_diff = mcti_resistance_difficulty; // 1 или 2
_unitCountTotal = 0;
_lvCount = 0;
_hvCount = 0;
_driversCount = 0;
_gunnersCount = 0;
_commCount = 0;

if (mcti_resistance_enabled) then
{
	_i = 0;
	{
		// заÑелÑем каждый i-ый город
		// new group
		tmp_group = createGroup resistance; 

		_unitCountTown = 0;
		_xf = _x select 0;
		_yf = _x select 1; // X,Y координаты флага города
		_townSize = mcti_town_sizes select _i;
		_radiusMax = _townSize * 80; //метров

		// numbers of units in town
		_nInfantry = round (random (_townSize * (_diff * 3 )));
		_nLightVeh = round (random (_townSize * (_diff * 1.0 )));
		_nArmored = round (random (_townSize * (_diff * 0.75 )));
		// placing Infantry
		for [{_j=0},{_j<_nInfantry},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
			tmp_unit setDir (deg _povorot); 
			[tmp_unit] joinSilent tmp_group; 
			if (_j == 0) then { tmp_group selectLeader tmp_unit  };
			tmp_unit disableAI "AUTOTARGET"; 
			tmp_unit disableAI "TARGET"; 
			tmp_unit disableAI "MOVE"; 
		};

		// placing Light Vehicles
		for [{_j=0},{_j<_nLightVeh},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_lvCount = _lvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_vehClass = (mcti_resistance_lightVehicles select (round (random _cLV))); 
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			tmp_veh = _vehClass createVehicle _pos;
			tmp_veh setDir (deg _povorot); 

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				// _pos from LV
				tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit setDir (deg _povorot); 
				[tmp_unit] joinSilent tmp_group; 
				//tmp_unit moveInDriver tmp_veh; 
				tmp_unit assignAsDriver tmp_veh;
				[tmp_unit] orderGetIn TRUE;
				tmp_unit disableAI "AUTOTARGET"; 
				tmp_unit disableAI "TARGET"; 
				tmp_unit disableAI "MOVE"; 
			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				// _pos from LV
				tmp_unit2 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit2 setDir (deg _povorot); 
				[tmp_unit2] joinSilent tmp_group; 
				//tmp_unit2 moveInGunner tmp_veh; 
				tmp_unit2 assignAsGunner tmp_veh;
				[tmp_unit2] orderGetIn TRUE;
				tmp_unit2 disableAI "AUTOTARGET"; 
				tmp_unit2 disableAI "TARGET"; 
				tmp_unit2 disableAI "MOVE"; 
			};
		};

		// placing Heavy Vehicles
		for [{_j=0},{_j<_nArmored},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_hvCount = _hvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			_vehClass = (mcti_resistance_heavyVehicles select (round (random _cArm)));
			tmp_veh = _vehClass createVehicle _pos;
			tmp_veh setDir (deg _povorot); 

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit setDir (deg _povorot); 
				[tmp_unit] joinSilent tmp_group; 
				//tmp_unit moveInDriver tmp_veh; 
				tmp_unit assignAsDriver tmp_veh;
				[tmp_unit] orderGetIn TRUE;
				tmp_unit disableAI "AUTOTARGET"; 
				tmp_unit disableAI "TARGET"; 
				tmp_unit disableAI "MOVE"; 
			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				tmp_unit2 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit2 setDir (deg _povorot); 
				[tmp_unit2] joinSilent tmp_group; 
				//tmp_unit2 moveInGunner tmp_veh; 
				tmp_unit2 assignAsGunner tmp_veh;
				[tmp_unit2] orderGetIn TRUE;
				tmp_unit2 disableAI "AUTOTARGET"; 
				tmp_unit2 disableAI "TARGET"; 
				tmp_unit2 disableAI "MOVE"; 
			};

			//commander
			if (_vehClass in mcti_resistance_CommNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_commCount = _commCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				tmp_unit3 = "Ins_Soldier_Crew" createUnit [ _pos, tmp_group, "", (0.5 + 0.1 * _diff * _diff)];
				tmp_unit3 setDir (deg _povorot); 
				[tmp_unit3] joinSilent tmp_group; 
				//tmp_unit3 moveInCommander tmp_veh; 
				tmp_unit3 assignAsCommander tmp_veh;
				[tmp_unit3] orderGetIn TRUE;
				tmp_unit3 disableAI "AUTOTARGET"; 
				tmp_unit3 disableAI "TARGET"; 
				tmp_unit3 disableAI "MOVE"; 
			};

		};

		// Ñледующий город
		_unitCountTotal = _unitCountTotal + _unitCountTown;
		_i = _i + 1;
	} forEach mcti_town_markerCoords;

};
diag_log format["Total Units: %1, Light Vehicles: %2, Heavy Vehicles: %3, Drivers: %4, Gunners: %5, Commanders: %6", _unitCountTotal, _lvCount, _hvCount, _driversCount, _gunnersCount, _commCount]; //dbg////////

};

2010/01/07, 22:34:22 Unsupported language Russian in stringtable
2010/01/07, 22:34:56 Error in expression <e _area == typename []) then {_position distance _center < _maxdis} else {[_area>
2010/01/07, 22:34:56   Error position: <distance _center < _maxdis} else {[_area>
2010/01/07, 22:34:56   Error distance: Тип ЧиÑло, ожидаетÑÑ ÐœÐ½Ð¾Ð¶ÐµÑтво,Объект,Location
2010/01/07, 22:34:56 File ca\modules\functions\systems\fn_locations.sqf, line 114
2010/01/07, 22:35:16 Server: Update of object 2:35 arrived from nonowner
2010/01/07, 22:36:26 "Total Units: 629, Light Vehicles: 81, Heavy Vehicles: 61, Drivers: 142, Gunners: 136, Commanders: 15"
2010/01/07, 22:36:42 Server: Object 3:1 not found (message 121)

---------- Post added at 01:05 ---------- Previous post was at 23:46 ----------

another step, I took, was:

i added each unit , vehicle and group into unique variable and put them in speacial public arrays...

but now I don't see infantry in the game, and vehicles are empty.

// mca_resistance_init.sqf
// version 1.0s

if (isServer) then
{
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

waitUntil { time > 10};

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

mcti_resistance_infantry = [ "CDF_Soldier_Strela", "CDF_Soldier_RPG", "CDF_Soldier_AR", "CDF_Soldier_Crew", "CDF_Soldier_Engineer", "CDF_Commander", "CDF_Soldier_GL", "CDF_Soldier_MG", "CDF_Soldier_Marksman", "CDF_Soldier_Medic", "CDF_Soldier_Militia", "CDF_Soldier_Officer", "CDF_Soldier_Pilot", "CDF_Soldier", "CDF_Soldier_Sniper", "CDF_Soldier_Light", "CDF_Soldier_Spotter" ];
// "CDF_Soldier_TL"

mcti_resistance_lightVehicles = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF" ];	
mcti_resistance_heavyVehicles = ["BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF"];

mcti_resistance_DriverNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF" ];	
mcti_resistance_GunnerNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF" ];
mcti_resistance_CommNeeded = [ "T72_CDF" ];

publicVariable "mcti_resistance_infantry"; 
publicVariable "mcti_resistance_lightVehicles"; 
publicVariable "mcti_resistance_heavyVehicles"; 

publicVariable "mcti_resistance_DriverNeeded"; 
publicVariable "mcti_resistance_GunnerNeeded"; 
publicVariable "mcti_resistance_CommNeeded"; 

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

mcti_res_groups = []; publicVariable "mcti_res_groups";
mcti_res_units = []; publicVariable "mcti_res_units";
mcti_res_vehicles = []; publicVariable "mcti_res_vehicles";

mcti_res_group_prefix = "mcti_res_group_";
mcti_res_unit_prefix = "mcti_res_unit_";
mcti_res_vehicle_prefix = "mcti_res_vehicle_";

//global counters
gc_u = 0;
gc_v = 0;

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

private ["_i", "_xf", "_yf", "_townSize", "_diff", "_radiusMax", "_radius", "_angle", "_povorot", "_nInfantry", "_nLightVeh", "_nArmored", "_cInf", "_cLV", "_cArm", "_j", "_DriverNeeded", "_vehClass", "_unitCountTown", "_unitCountTotal", "_pos", "_lvCount", "_hvCount", "_driversCount", "_gunnersCount", "_commCount", "_varName", "_groupName"];

_cInf = count mcti_resistance_infantry - 1;
_cLV = count mcti_resistance_lightVehicles - 1;
_cArm = count mcti_resistance_heavyVehicles - 1;
_diff = mcti_resistance_difficulty; // 1 или 2
_unitCountTotal = 0;
_lvCount = 0;
_hvCount = 0;
_driversCount = 0;
_gunnersCount = 0;
_commCount = 0;

if (mcti_resistance_enabled) then
{
	_i = 0;
	{
		// заÑелÑем каждый i-ый город
		// new group
		tmp_group = createGroup resistance; 
		_varName = mcti_res_group_prefix + (str _i);
		_groupName = _varName;
		Call Compile Format ["%1=tmp_group; PublicVariable ""%1""; mcti_res_groups = mcti_res_groups + [%1];",_varName]; // mcti_res_group_* = tmp_group; (* = _i)

		_unitCountTown = 0;
		_xf = _x select 0;
		_yf = _x select 1; // X,Y координаты флага города
		_townSize = mcti_town_sizes select _i;
		_radiusMax = _townSize * 80; //метров

		// numbers of units in town
		_nInfantry = round (random (_townSize * (_diff * 3 )));
		_nLightVeh = round (random (_townSize * (_diff * 1.0 )));
		_nArmored = round (random (_townSize * (_diff * 0.75 )));
		// placing Infantry
		for [{_j=0},{_j<_nInfantry},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			Call Compile Format ["    tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
			_varName = mcti_res_unit_prefix + (str gc_u);
			gc_u = gc_u + 1;
			tmp_unit SetVehicleVarName _varName;
			tmp_unit Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
			Call Compile Format ["   	 %1 setDir (deg _povorot); [%1] joinSilent %2; if (_j == 0) then { %2 selectLeader %1  }; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE""; 	 ", _varName, mcti_res_group_prefix + (str _i)];				

		};

		// placing Light Vehicles
		for [{_j=0},{_j<_nLightVeh},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_lvCount = _lvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_vehClass = (mcti_resistance_lightVehicles select (round (random _cLV))); 
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			tmp_veh = _vehClass createVehicle _pos;
			_varName = mcti_res_vehicle_prefix + (str gc_v);
			gc_v = gc_v + 1;
			tmp_veh SetVehicleVarName _varName;
			tmp_veh Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_vehicles = mcti_res_vehicles + [%1];",_varName]; // mcti_res_vehicle_* = tmp_veh;
			Call Compile Format [" %1 setDir (deg _povorot);  ", _varName];


			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				// _pos from LV
				Call Compile Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				tmp_unit Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				Call Compile Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				//tmp_unit moveInDriver tmp_veh; 	

			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				// _pos from LV
				Call Compile Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				tmp_unit Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				Call Compile Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				//tmp_unit2 moveInGunner tmp_veh; 

			};
		};

		// placing Heavy Vehicles
		for [{_j=0},{_j<_nArmored},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_hvCount = _hvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			_vehClass = (mcti_resistance_heavyVehicles select (round (random _cArm)));
			tmp_veh = _vehClass createVehicle _pos;
			_varName = mcti_res_vehicle_prefix + (str gc_v);
			gc_v = gc_v + 1;
			tmp_veh SetVehicleVarName _varName;
			tmp_veh Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_vehicles = mcti_res_vehicles + [%1];",_varName]; // mcti_res_vehicle_* = tmp_veh;
			Call Compile Format [" %1 setDir (deg _povorot);  ", _varName];

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				Call Compile Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				tmp_unit Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				Call Compile Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				//tmp_unit moveInDriver tmp_veh; 	

			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				Call Compile Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				tmp_unit Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				Call Compile Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				//tmp_unit2 moveInGunner tmp_veh; 

			};

			//commander
			if (_vehClass in mcti_resistance_CommNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_commCount = _commCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				Call Compile Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				tmp_unit Call Compile Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				Call Compile Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsCommander (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				//tmp_unit2 moveInGunner tmp_veh; 

			};

		};

		// Ñледующий город
		_unitCountTotal = _unitCountTotal + _unitCountTown;
		_i = _i + 1;
	} forEach mcti_town_markerCoords;

	publicVariable "mcti_res_groups";
	publicVariable "mcti_res_units";
	publicVariable "mcti_res_vehicles";

}; //res enabled
diag_log format["Total Units: %1, Light Vehicles: %2, Heavy Vehicles: %3, Drivers: %4, Gunners: %5, Commanders: %6", _unitCountTotal, _lvCount, _hvCount, _driversCount, _gunnersCount, _commCount]; //dbg////////

}; //isServer

.rpt:

2010/01/07, 23:57:49 Unsupported language Russian in stringtable

2010/01/07, 23:58:24 Error in expression <e _area == typename []) then {_position distance _center < _maxdis} else {[_area>

2010/01/07, 23:58:24 Error position: <distance _center < _maxdis} else {[_area>

2010/01/07, 23:58:24 Error distance: Тип ЧиÑло, ожидаетÑÑ ÐœÐ½Ð¾Ð¶ÐµÑтво,Объект,Location

2010/01/07, 23:58:24 File ca\modules\functions\systems\fn_locations.sqf, line 114

2010/01/07, 23:58:45 Server: Update of object 2:35 arrived from nonowner

2010/01/07, 23:59:04 Out of map

2010/01/07, 23:59:04 Error R 1-2-C:4: Invalid path from [5880.47, 141.61, 4698.28] to [5893.91, 143.05, 4735.47].

2010/01/07, 23:59:46 "Total Units: 569, Light Vehicles: 73, Heavy Vehicles: 49, Drivers: 122, Gunners: 115, Commanders: 14"

Can anybody help?

Edited by McArcher

Share this post


Link to post
Share on other sites

I have even checked compile lines with diag_log...

// mca_resistance_init.sqf
// version 1.0s

if (isServer) then
{
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

waitUntil { time > 10};

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

mcti_resistance_infantry = [ "CDF_Soldier_Strela", "CDF_Soldier_RPG", "CDF_Soldier_AR", "CDF_Soldier_Crew", "CDF_Soldier_Engineer", "CDF_Commander", "CDF_Soldier_GL", "CDF_Soldier_MG", "CDF_Soldier_Marksman", "CDF_Soldier_Medic", "CDF_Soldier_Militia", "CDF_Soldier_Officer", "CDF_Soldier_Pilot", "CDF_Soldier", "CDF_Soldier_Sniper", "CDF_Soldier_Light", "CDF_Soldier_Spotter" ];
// "CDF_Soldier_TL"

mcti_resistance_lightVehicles = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF" ];	
mcti_resistance_heavyVehicles = ["BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF"];

mcti_resistance_DriverNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF" ];	
mcti_resistance_GunnerNeeded = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF", "BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF" ];
mcti_resistance_CommNeeded = [ "T72_CDF" ];

publicVariable "mcti_resistance_infantry"; 
publicVariable "mcti_resistance_lightVehicles"; 
publicVariable "mcti_resistance_heavyVehicles"; 

publicVariable "mcti_resistance_DriverNeeded"; 
publicVariable "mcti_resistance_GunnerNeeded"; 
publicVariable "mcti_resistance_CommNeeded"; 

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

mcti_res_groups = []; publicVariable "mcti_res_groups";
mcti_res_units = []; publicVariable "mcti_res_units";
mcti_res_vehicles = []; publicVariable "mcti_res_vehicles";

mcti_res_group_prefix = "mcti_res_group_";
mcti_res_unit_prefix = "mcti_res_unit_";
mcti_res_vehicle_prefix = "mcti_res_vehicle_";

//global counters
gc_u = 0;
gc_v = 0;

//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

private ["_i", "_xf", "_yf", "_townSize", "_diff", "_radiusMax", "_radius", "_angle", "_povorot", "_nInfantry", "_nLightVeh", "_nArmored", "_cInf", "_cLV", "_cArm", "_j", "_DriverNeeded", "_vehClass", "_unitCountTown", "_unitCountTotal", "_pos", "_lvCount", "_hvCount", "_driversCount", "_gunnersCount", "_commCount", "_varName", "_groupName" , "_s"];

_cInf = count mcti_resistance_infantry - 1;
_cLV = count mcti_resistance_lightVehicles - 1;
_cArm = count mcti_resistance_heavyVehicles - 1;
_diff = mcti_resistance_difficulty; // 1 или 2
_unitCountTotal = 0;
_lvCount = 0;
_hvCount = 0;
_driversCount = 0;
_gunnersCount = 0;
_commCount = 0;

if (mcti_resistance_enabled) then
{
	_i = 0;
	{
		// заÑелÑем каждый i-ый город
		// new group
		tmp_group = createGroup resistance; 
		_varName = mcti_res_group_prefix + (str _i);
		_groupName = _varName;
		_s = Format ["%1=tmp_group; PublicVariable ""%1""; mcti_res_groups = mcti_res_groups + [%1];",_varName]; // mcti_res_group_* = tmp_group; (* = _i)
		Call Compile _s;
		diag_log _s;/////////////////////////////////////////

		_unitCountTown = 0;
		_xf = _x select 0;
		_yf = _x select 1; // X,Y координаты флага города
		_townSize = mcti_town_sizes select _i;
		_radiusMax = _townSize * 80; //метров

		// numbers of units in town
		_nInfantry = round (random (_townSize * (_diff * 3 )));
		_nLightVeh = round (random (_townSize * (_diff * 1.0 )));
		_nArmored = round (random (_townSize * (_diff * 0.75 )));
		// placing Infantry
		for [{_j=0},{_j<_nInfantry},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			_s = Format ["    tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
			Call Compile _s;
			diag_log _s;/////////////////////////////////////////
			_varName = mcti_res_unit_prefix + (str gc_u);
			gc_u = gc_u + 1;
			tmp_unit SetVehicleVarName _varName;
			_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
			tmp_unit Call Compile _s;
			diag_log _s;/////////////////////////////////////////
			_s = Format ["   	 %1 setDir (deg _povorot); [%1] joinSilent %2; if (_j == 0) then { %2 selectLeader %1  }; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE""; 	 ", _varName, mcti_res_group_prefix + (str _i)];	
			Call Compile _s;
			diag_log _s;/////////////////////////////////////////

		};

		// placing Light Vehicles
		for [{_j=0},{_j<_nLightVeh},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_lvCount = _lvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_vehClass = (mcti_resistance_lightVehicles select (round (random _cLV))); 
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			tmp_veh = _vehClass createVehicle _pos;
			_varName = mcti_res_vehicle_prefix + (str gc_v);
			gc_v = gc_v + 1;
			tmp_veh SetVehicleVarName _varName;
			_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_vehicles = mcti_res_vehicles + [%1];",_varName]; // mcti_res_vehicle_* = tmp_veh;
			tmp_veh Call Compile _s;
			diag_log _s;/////////////////////////////////////////
			_s = Format [" %1 setDir (deg _povorot);  ", _varName];
			Call Compile _s;
			diag_log _s;/////////////////////////////////////////	

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				// _pos from LV
				_s = Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				tmp_unit Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_s = Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				//tmp_unit moveInDriver tmp_veh; 	

			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				// _pos from LV
				_s = Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				tmp_unit Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_s = Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				//tmp_unit2 moveInGunner tmp_veh; 

			};
		};

		// placing Heavy Vehicles
		for [{_j=0},{_j<_nArmored},{_j=_j+1}] do
		{
			_unitCountTown = _unitCountTown + 1;
			_hvCount = _hvCount + 1;
			_radius = round (random _radiusMax);
			_angle = random (2 * pi);
			_povorot = random (2 * pi);
			_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			while {surfaceIsWater _pos} do 
			{
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				_pos = [(_xf + _radius * cos (deg _angle)), (_yf + _radius * sin (deg _angle))];
			};
			_vehClass = (mcti_resistance_heavyVehicles select (round (random _cArm)));
			tmp_veh = _vehClass createVehicle _pos;
			_varName = mcti_res_vehicle_prefix + (str gc_v);
			gc_v = gc_v + 1;
			tmp_veh SetVehicleVarName _varName;
			_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_vehicles = mcti_res_vehicles + [%1];",_varName]; // mcti_res_vehicle_* = tmp_veh;
			tmp_veh Call Compile _s;
			diag_log _s;/////////////////////////////////////////	
			_s = Format [" %1 setDir (deg _povorot);  ", _varName];
			Call Compile _s;
			diag_log _s;/////////////////////////////////////////	

			//driver
			if (_vehClass in mcti_resistance_DriverNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_driversCount = _driversCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				_s = Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				tmp_unit Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_s = Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				//tmp_unit moveInDriver tmp_veh; 	

			};

			//gunner
			if (_vehClass in mcti_resistance_GunnerNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_gunnersCount = _gunnersCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				_s = Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				tmp_unit Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_s = Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				//tmp_unit2 moveInGunner tmp_veh; 

			};

			//commander
			if (_vehClass in mcti_resistance_CommNeeded) then
			{
				_unitCountTown = _unitCountTown + 1;
				_commCount = _commCount + 1;
				_radius = round (random _radiusMax);
				_angle = random (2 * pi);
				_povorot = random (2 * pi);
				//_pos from HV
				_s = Format ["    tmp_unit =  ""Ins_Soldier_Crew"" createUnit [ _pos, %1, """", (0.5 + 0.1 * _diff * _diff)];        ",   _groupName   ];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_varName = mcti_res_unit_prefix + (str gc_u);
				gc_u = gc_u + 1;
				tmp_unit SetVehicleVarName _varName;
				_s = Format ["%1=_this; PublicVariable ""%1""; mcti_res_units = mcti_res_units + [%1];",_varName]; // mcti_res_unit_* = tmp_unit;
				tmp_unit Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				_s = Format ["    %1 setDir (deg _povorot); [%1] joinSilent %2; %1 assignAsCommander (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [%1] orderGetIn TRUE; %1 disableAI ""AUTOTARGET""; %1 disableAI ""TARGET""; %1 disableAI ""MOVE"";     ", _varName, mcti_res_group_prefix + (str _i)];
				Call Compile _s;
				diag_log _s;/////////////////////////////////////////	
				//tmp_unit2 moveInGunner tmp_veh; 

			};

		};

		// Ñледующий город
		_unitCountTotal = _unitCountTotal + _unitCountTown;
		_i = _i + 1;
	} forEach mcti_town_markerCoords;

	publicVariable "mcti_res_groups";
	publicVariable "mcti_res_units";
	publicVariable "mcti_res_vehicles";

}; //res enabled

diag_log "________________________________________________________";
diag_log format["Total Units: %1, Light Vehicles: %2, Heavy Vehicles: %3, Drivers: %4, Gunners: %5, Commanders: %6", _unitCountTotal, _lvCount, _hvCount, _driversCount, _gunnersCount, _commCount]; //dbg////////

}; //isServer

.RPT:

Mods: CA

Distribution: 0

2010/01/08, 0:17:28 Unsupported language Russian in stringtable

2010/01/08, 0:18:03 Error in expression <e _area == typename []) then {_position distance _center < _maxdis} else {[_area>

2010/01/08, 0:18:03 Error position: <distance _center < _maxdis} else {[_area>

2010/01/08, 0:18:03 Error distance: Тип ЧиÑло, ожидаетÑÑ ÐœÐ½Ð¾Ð¶ÐµÑтво,Объект,Location

2010/01/08, 0:18:03 File ca\modules\functions\systems\fn_locations.sqf, line 114

2010/01/08, 0:18:21 Server: Update of object 2:35 arrived from nonowner

2010/01/08, 0:18:29 "mcti_res_group_0=tmp_group; PublicVariable "mcti_res_group_0"; mcti_res_groups = mcti_res_groups + [mcti_res_group_0];"

2010/01/08, 0:18:29 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_0=_this; PublicVariable "mcti_res_unit_0"; mcti_res_units = mcti_res_units + [mcti_res_unit_0];"

2010/01/08, 0:18:29 " mcti_res_unit_0 setDir (deg _povorot); [mcti_res_unit_0] joinSilent mcti_res_group_0; if (_j == 0) then { mcti_res_group_0 selectLeader mcti_res_unit_0 }; mcti_res_unit_0 disableAI "AUTOTARGET"; mcti_res_unit_0 disableAI "TARGET"; mcti_res_unit_0 disableAI "MOVE"; "

2010/01/08, 0:18:29 "mcti_res_vehicle_0=_this; PublicVariable "mcti_res_vehicle_0"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_0];"

2010/01/08, 0:18:29 " mcti_res_vehicle_0 setDir (deg _povorot); "

2010/01/08, 0:18:29 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_1=_this; PublicVariable "mcti_res_unit_1"; mcti_res_units = mcti_res_units + [mcti_res_unit_1];"

2010/01/08, 0:18:29 " mcti_res_unit_1 setDir (deg _povorot); [mcti_res_unit_1] joinSilent mcti_res_group_0; mcti_res_unit_1 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_1] orderGetIn TRUE; mcti_res_unit_1 disableAI "AUTOTARGET"; mcti_res_unit_1 disableAI "TARGET"; mcti_res_unit_1 disableAI "MOVE"; "

2010/01/08, 0:18:29 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_2=_this; PublicVariable "mcti_res_unit_2"; mcti_res_units = mcti_res_units + [mcti_res_unit_2];"

2010/01/08, 0:18:29 " mcti_res_unit_2 setDir (deg _povorot); [mcti_res_unit_2] joinSilent mcti_res_group_0; mcti_res_unit_2 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_2] orderGetIn TRUE; mcti_res_unit_2 disableAI "AUTOTARGET"; mcti_res_unit_2 disableAI "TARGET"; mcti_res_unit_2 disableAI "MOVE"; "

2010/01/08, 0:18:29 "mcti_res_vehicle_1=_this; PublicVariable "mcti_res_vehicle_1"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_1];"

2010/01/08, 0:18:29 " mcti_res_vehicle_1 setDir (deg _povorot); "

2010/01/08, 0:18:29 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_3=_this; PublicVariable "mcti_res_unit_3"; mcti_res_units = mcti_res_units + [mcti_res_unit_3];"

2010/01/08, 0:18:29 " mcti_res_unit_3 setDir (deg _povorot); [mcti_res_unit_3] joinSilent mcti_res_group_0; mcti_res_unit_3 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_3] orderGetIn TRUE; mcti_res_unit_3 disableAI "AUTOTARGET"; mcti_res_unit_3 disableAI "TARGET"; mcti_res_unit_3 disableAI "MOVE"; "

2010/01/08, 0:18:29 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_4=_this; PublicVariable "mcti_res_unit_4"; mcti_res_units = mcti_res_units + [mcti_res_unit_4];"

2010/01/08, 0:18:29 " mcti_res_unit_4 setDir (deg _povorot); [mcti_res_unit_4] joinSilent mcti_res_group_0; mcti_res_unit_4 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_4] orderGetIn TRUE; mcti_res_unit_4 disableAI "AUTOTARGET"; mcti_res_unit_4 disableAI "TARGET"; mcti_res_unit_4 disableAI "MOVE"; "

2010/01/08, 0:18:29 "mcti_res_vehicle_2=_this; PublicVariable "mcti_res_vehicle_2"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_2];"

2010/01/08, 0:18:29 " mcti_res_vehicle_2 setDir (deg _povorot); "

2010/01/08, 0:18:29 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_5=_this; PublicVariable "mcti_res_unit_5"; mcti_res_units = mcti_res_units + [mcti_res_unit_5];"

2010/01/08, 0:18:29 " mcti_res_unit_5 setDir (deg _povorot); [mcti_res_unit_5] joinSilent mcti_res_group_0; mcti_res_unit_5 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_5] orderGetIn TRUE; mcti_res_unit_5 disableAI "AUTOTARGET"; mcti_res_unit_5 disableAI "TARGET"; mcti_res_unit_5 disableAI "MOVE"; "

2010/01/08, 0:18:29 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_0, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_6=_this; PublicVariable "mcti_res_unit_6"; mcti_res_units = mcti_res_units + [mcti_res_unit_6];"

2010/01/08, 0:18:29 " mcti_res_unit_6 setDir (deg _povorot); [mcti_res_unit_6] joinSilent mcti_res_group_0; mcti_res_unit_6 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_6] orderGetIn TRUE; mcti_res_unit_6 disableAI "AUTOTARGET"; mcti_res_unit_6 disableAI "TARGET"; mcti_res_unit_6 disableAI "MOVE"; "

2010/01/08, 0:18:29 "mcti_res_group_1=tmp_group; PublicVariable "mcti_res_group_1"; mcti_res_groups = mcti_res_groups + [mcti_res_group_1];"

2010/01/08, 0:18:29 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_1, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_7=_this; PublicVariable "mcti_res_unit_7"; mcti_res_units = mcti_res_units + [mcti_res_unit_7];"

2010/01/08, 0:18:29 " mcti_res_unit_7 setDir (deg _povorot); [mcti_res_unit_7] joinSilent mcti_res_group_1; if (_j == 0) then { mcti_res_group_1 selectLeader mcti_res_unit_7 }; mcti_res_unit_7 disableAI "AUTOTARGET"; mcti_res_unit_7 disableAI "TARGET"; mcti_res_unit_7 disableAI "MOVE"; "

2010/01/08, 0:18:29 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_1, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_8=_this; PublicVariable "mcti_res_unit_8"; mcti_res_units = mcti_res_units + [mcti_res_unit_8];"

2010/01/08, 0:18:29 " mcti_res_unit_8 setDir (deg _povorot); [mcti_res_unit_8] joinSilent mcti_res_group_1; if (_j == 0) then { mcti_res_group_1 selectLeader mcti_res_unit_8 }; mcti_res_unit_8 disableAI "AUTOTARGET"; mcti_res_unit_8 disableAI "TARGET"; mcti_res_unit_8 disableAI "MOVE"; "

2010/01/08, 0:18:29 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_1, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:29 "mcti_res_unit_9=_this; PublicVariable "mcti_res_unit_9"; mcti_res_units = mcti_res_units + [mcti_res_unit_9];"

2010/01/08, 0:18:29 " mcti_res_unit_9 setDir (deg _povorot); [mcti_res_unit_9] joinSilent mcti_res_group_1; if (_j == 0) then { mcti_res_group_1 selectLeader mcti_res_unit_9 }; mcti_res_unit_9 disableAI "AUTOTARGET"; mcti_res_unit_9 disableAI "TARGET"; mcti_res_unit_9 disableAI "MOVE"; "

2010/01/08, 0:18:30 "mcti_res_vehicle_3=_this; PublicVariable "mcti_res_vehicle_3"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_3];"

[ several hundreds thousands characters here]

2010/01/08, 0:18:33 "mcti_res_unit_66=_this; PublicVariable "mcti_res_unit_66"; mcti_res_units = mcti_res_units + [mcti_res_unit_66];"

2010/01/08, 0:18:33 " mcti_res_unit_66 setDir (deg _povorot); [mcti_res_unit_66] joinSilent mcti_res_group_5; if (_j == 0) then { mcti_res_group_5 selectLeader mcti_res_unit_66 }; mcti_res_unit_66 disableAI "AUTOTARGET"; mcti_res_unit_66 disableAI "TARGET"; mcti_res_unit_66 disableAI "MOVE"; "

2010/01/08, 0:18:34 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_5, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:34 "mcti_res_unit_67=_this; PublicVariable "mcti_res_unit_67"; mcti_res_units = mcti_res_units + [mcti_res_unit_67];"

2010/01/08, 0:18:34 " mcti_res_unit_67 setDir (deg _povorot); [mcti_res_unit_67] joinSilent mcti_res_group_5; if (_j == 0) then { mcti_res_group_5 selectLeader mcti_res_unit_67 }; mcti_res_unit_67 disableAI "AUTOTARGET"; mcti_res_unit_67 disableAI "TARGET"; mcti_res_unit_67 disableAI "MOVE"; "

2010/01/08, 0:18:34 "mcti_res_vehicle_17=_this; PublicVariable "mcti_res_vehicle_17"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_17];"

2010/01/08, 0:18:34 " mcti_res_vehicle_17 setDir (deg _povorot); "

2010/01/08, 0:18:34 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_5, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:18:34 "mcti_res_unit_68=_this; PublicVariable "mcti_res_unit_68"; mcti_res_units = mcti_res_units + [mcti_res_unit_68];"

2010/01/08, 0:18:34 " mcti_res_unit_68 setDir (deg _povorot); [mcti_res_unit_68] joinSilent mcti_res_group_5; mcti_res_unit_68 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_68] orderGetIn TRUE; mcti_res_unit_68 disableAI "AUTOTARGET"; mcti_res_unit_68 disableAI "TARGET"; mcti_res_unit_68 disableAI "MOVE"; "

[ several hundreds thousands characters here]

2010/01/08, 0:19:22 "mcti_res_vehicle_116=_this; PublicVariable "mcti_res_vehicle_116"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_116];"

2010/01/08, 0:19:22 " mcti_res_vehicle_116 setDir (deg _povorot); "

2010/01/08, 0:19:22 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_52, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:22 "mcti_res_unit_460=_this; PublicVariable "mcti_res_unit_460"; mcti_res_units = mcti_res_units + [mcti_res_unit_460];"

2010/01/08, 0:19:22 " mcti_res_unit_460 setDir (deg _povorot); [mcti_res_unit_460] joinSilent mcti_res_group_52; mcti_res_unit_460 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_460] orderGetIn TRUE; mcti_res_unit_460 disableAI "AUTOTARGET"; mcti_res_unit_460 disableAI "TARGET"; mcti_res_unit_460 disableAI "MOVE"; "

2010/01/08, 0:19:22 "mcti_res_group_53=tmp_group; PublicVariable "mcti_res_group_53"; mcti_res_groups = mcti_res_groups + [mcti_res_group_53];"

2010/01/08, 0:19:22 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:22 "mcti_res_unit_461=_this; PublicVariable "mcti_res_unit_461"; mcti_res_units = mcti_res_units + [mcti_res_unit_461];"

2010/01/08, 0:19:22 " mcti_res_unit_461 setDir (deg _povorot); [mcti_res_unit_461] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_461 }; mcti_res_unit_461 disableAI "AUTOTARGET"; mcti_res_unit_461 disableAI "TARGET"; mcti_res_unit_461 disableAI "MOVE"; "

2010/01/08, 0:19:22 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:22 "mcti_res_unit_462=_this; PublicVariable "mcti_res_unit_462"; mcti_res_units = mcti_res_units + [mcti_res_unit_462];"

2010/01/08, 0:19:22 " mcti_res_unit_462 setDir (deg _povorot); [mcti_res_unit_462] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_462 }; mcti_res_unit_462 disableAI "AUTOTARGET"; mcti_res_unit_462 disableAI "TARGET"; mcti_res_unit_462 disableAI "MOVE"; "

2010/01/08, 0:19:22 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:22 "mcti_res_unit_463=_this; PublicVariable "mcti_res_unit_463"; mcti_res_units = mcti_res_units + [mcti_res_unit_463];"

2010/01/08, 0:19:22 " mcti_res_unit_463 setDir (deg _povorot); [mcti_res_unit_463] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_463 }; mcti_res_unit_463 disableAI "AUTOTARGET"; mcti_res_unit_463 disableAI "TARGET"; mcti_res_unit_463 disableAI "MOVE"; "

2010/01/08, 0:19:22 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:22 "mcti_res_unit_464=_this; PublicVariable "mcti_res_unit_464"; mcti_res_units = mcti_res_units + [mcti_res_unit_464];"

2010/01/08, 0:19:22 " mcti_res_unit_464 setDir (deg _povorot); [mcti_res_unit_464] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_464 }; mcti_res_unit_464 disableAI "AUTOTARGET"; mcti_res_unit_464 disableAI "TARGET"; mcti_res_unit_464 disableAI "MOVE"; "

2010/01/08, 0:19:23 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:23 "mcti_res_unit_465=_this; PublicVariable "mcti_res_unit_465"; mcti_res_units = mcti_res_units + [mcti_res_unit_465];"

2010/01/08, 0:19:23 " mcti_res_unit_465 setDir (deg _povorot); [mcti_res_unit_465] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_465 }; mcti_res_unit_465 disableAI "AUTOTARGET"; mcti_res_unit_465 disableAI "TARGET"; mcti_res_unit_465 disableAI "MOVE"; "

2010/01/08, 0:19:23 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:23 "mcti_res_unit_466=_this; PublicVariable "mcti_res_unit_466"; mcti_res_units = mcti_res_units + [mcti_res_unit_466];"

2010/01/08, 0:19:23 " mcti_res_unit_466 setDir (deg _povorot); [mcti_res_unit_466] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_466 }; mcti_res_unit_466 disableAI "AUTOTARGET"; mcti_res_unit_466 disableAI "TARGET"; mcti_res_unit_466 disableAI "MOVE"; "

2010/01/08, 0:19:23 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:23 "mcti_res_unit_467=_this; PublicVariable "mcti_res_unit_467"; mcti_res_units = mcti_res_units + [mcti_res_unit_467];"

2010/01/08, 0:19:23 " mcti_res_unit_467 setDir (deg _povorot); [mcti_res_unit_467] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_467 }; mcti_res_unit_467 disableAI "AUTOTARGET"; mcti_res_unit_467 disableAI "TARGET"; mcti_res_unit_467 disableAI "MOVE"; "

2010/01/08, 0:19:23 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:23 "mcti_res_unit_468=_this; PublicVariable "mcti_res_unit_468"; mcti_res_units = mcti_res_units + [mcti_res_unit_468];"

2010/01/08, 0:19:23 " mcti_res_unit_468 setDir (deg _povorot); [mcti_res_unit_468] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_468 }; mcti_res_unit_468 disableAI "AUTOTARGET"; mcti_res_unit_468 disableAI "TARGET"; mcti_res_unit_468 disableAI "MOVE"; "

2010/01/08, 0:19:23 " tmp_unit = (mcti_resistance_infantry select (round (random _cInf))) createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:23 "mcti_res_unit_469=_this; PublicVariable "mcti_res_unit_469"; mcti_res_units = mcti_res_units + [mcti_res_unit_469];"

2010/01/08, 0:19:23 " mcti_res_unit_469 setDir (deg _povorot); [mcti_res_unit_469] joinSilent mcti_res_group_53; if (_j == 0) then { mcti_res_group_53 selectLeader mcti_res_unit_469 }; mcti_res_unit_469 disableAI "AUTOTARGET"; mcti_res_unit_469 disableAI "TARGET"; mcti_res_unit_469 disableAI "MOVE"; "

2010/01/08, 0:19:23 "mcti_res_vehicle_117=_this; PublicVariable "mcti_res_vehicle_117"; mcti_res_vehicles = mcti_res_vehicles + [mcti_res_vehicle_117];"

2010/01/08, 0:19:23 " mcti_res_vehicle_117 setDir (deg _povorot); "

2010/01/08, 0:19:23 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:23 "mcti_res_unit_470=_this; PublicVariable "mcti_res_unit_470"; mcti_res_units = mcti_res_units + [mcti_res_unit_470];"

2010/01/08, 0:19:23 " mcti_res_unit_470 setDir (deg _povorot); [mcti_res_unit_470] joinSilent mcti_res_group_53; mcti_res_unit_470 assignAsDriver (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_470] orderGetIn TRUE; mcti_res_unit_470 disableAI "AUTOTARGET"; mcti_res_unit_470 disableAI "TARGET"; mcti_res_unit_470 disableAI "MOVE"; "

2010/01/08, 0:19:24 " tmp_unit = "Ins_Soldier_Crew" createUnit [ _pos, mcti_res_group_53, "", (0.5 + 0.1 * _diff * _diff)]; "

2010/01/08, 0:19:24 "mcti_res_unit_471=_this; PublicVariable "mcti_res_unit_471"; mcti_res_units = mcti_res_units + [mcti_res_unit_471];"

2010/01/08, 0:19:24 " mcti_res_unit_471 setDir (deg _povorot); [mcti_res_unit_471] joinSilent mcti_res_group_53; mcti_res_unit_471 assignAsGunner (mcti_res_vehicles select ((count mcti_res_vehicles) - 1)); [mcti_res_unit_471] orderGetIn TRUE; mcti_res_unit_471 disableAI "AUTOTARGET"; mcti_res_unit_471 disableAI "TARGET"; mcti_res_unit_471 disableAI "MOVE"; "

2010/01/08, 0:19:24 "________________________________________________________"

2010/01/08, 0:19:24 "Total Units: 590, Light Vehicles: 66, Heavy Vehicles: 52, Drivers: 118, Gunners: 112, Commanders: 18"

2010/01/08, 0:21:02 Client: Object 3:3 (type Type_67) not found.

2010/01/08, 0:21:02 Client: Object 3:3 (type Type_66) not found.

2010/01/08, 0:21:18 Server: Object 3:4 not found (message 121)

I can see units, but vehicles are empty, crew is walking around..

Code seems to be ok....

---------- Post added at 01:41 ---------- Previous post was at 01:28 ----------

G'day you could use these scripts instead or have a look

http://forums.bistudio.com/showthread.php?t=92851&highlight=wolffy.au

This is version 0.5 and do'es what you ask whith the crB-spawnCrew.sqf

Version 0.6 is nearly ready for release and will support all sides and factions.

Ok, thanx. I'll read about these BIS functions....

Share this post


Link to post
Share on other sites

using BIS_fnc_spawnGroup, my script became 10x shorter :D

// mca_resistance_init.sqf
// version 1.0s

if (isServer) then
{
mcti_resistance_infantry = [ "CDF_Soldier_Strela", "CDF_Soldier_RPG", "CDF_Soldier_AR", "CDF_Soldier_Engineer", "CDF_Commander", "CDF_Soldier_GL", "CDF_Soldier_MG", "CDF_Soldier_Marksman", "CDF_Soldier_Medic", "CDF_Soldier_Militia", "CDF_Soldier_Officer", "CDF_Soldier", "CDF_Soldier_Sniper", "CDF_Soldier_TL" ];
mcti_resistance_lightVehicles = [ "UAZ_AGS30_CDF", "UAZ_MG_CDF", "Ural_ZU23_CDF", "BRDM2_CDF", "BRDM2_ATGM_CDF" ];	
mcti_resistance_heavyVehicles = ["BMP2_CDF", "BMP2_HQ_CDF", "T72_CDF", "ZSU_CDF", "BMP2_Ambul_CDF"];
publicVariable "mcti_resistance_infantry"; 
publicVariable "mcti_resistance_lightVehicles"; 
publicVariable "mcti_resistance_heavyVehicles"; 
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
private ["_i", "_townSize", "_diff", "_cInf", "_cLV", "_cArm", "_list", "_t", "_nInfantry", "_nLightVeh", "_nArmored" ];
_cInf = count mcti_resistance_infantry - 1;
_cLV = count mcti_resistance_lightVehicles - 1;
_cArm = count mcti_resistance_heavyVehicles - 1;
_diff = mcti_resistance_difficulty; // 1 или 2
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
if (mcti_resistance_enabled) then
{
	_i = 0;
	{
		// заÑелÑем каждый i-ый город
		_townSize = mcti_town_sizes select _i;
		_list = [];

		// numbers of units in town
		_nInfantry = round (random (_townSize * (_diff * 5 )));
		_nLightVeh = round (random (_townSize * (_diff * 0.5 )));
		_nArmored = round (random (_townSize * (_diff * 0.25 )));

		for [{_t=0},{_t<_nInfantry},{_t=_t+1}] do
		{
			_list = _list + [ (mcti_resistance_infantry select (round (random _cInf))) ];
		};
		for [{_t=0},{_t<_nLightVeh},{_t=_t+1}] do
		{
			_list = _list + [ (mcti_resistance_lightVehicles select (round (random _cLV))) ];
		};
		for [{_t=0},{_t<_nArmored},{_t=_t+1}] do
		{
			_list = _list + [ (mcti_resistance_heavyVehicles select (round (random _cArm))) ];
		};

		// spawning
		tmp_grp= [_x, resistance, _list ] call BIS_fnc_spawnGroup;
		[tmp_grp, _x, _townSize * 50] call BIS_fnc_taskPatrol;

		// Ñледующий город
		_i = _i + 1;
		diag_log format["Town #%1 has %2.", _i, _list];/////////////////////
	} forEach mcti_town_markerCoords;

}; //res enabled

}; //isServer

but still an error File ca\modules\functions\systems\fn_locations.sqf, line 114 appears in BIS's function. However, now crew is inside vehicles and I don't mind that BIS's functions give errors in .rpt. At least, it is not my fault.

I have a question about BIS_fnc_spawnGroup.

It is said in the comment in the text of this function's script that third parameter has 3 variants (array , number and....forgot the 3rd), if I choose an array, will it spawn all units, mentioned in array with 100% probability or will it randomly take units from that array?

---------- Post added at 16:21 ---------- Previous post was at 15:24 ----------

and also, the problem of server's FPS arises...

CPU load on server is only 50-60% (old Athlon 64 X2 @2.0GHz) and 12-14 fps with hundresds of AI at towns total. Why CPU load is not 100% I don't understand. I could understand if 1 core was loalded fully and game was not multi-cpu-friendly.... but BIS say that game is multithreaded and I don't see any of cores fully loaded...let alone all cores loaded.... very strange game engine..

Edited by McArcher

Share this post


Link to post
Share on other sites

BIS_fnc_help shows the script as well as the comments at the start, so you can see exactly what it does.

Parameter(s):

  • _this select 0: the group's starting position (Array)
  • _this select 1: the group's side (Side)
  • _this select 2: can be three different types:
    - list of character types (Array)
    - amount of characters (Number)
    - CfgGroups entry (Config)
  • _this select 3: (optional) list of relative positions (Array)
  • _this select 4: (optional) list of ranks (Array)
  • _this select 5: (optional) skill range (Array)
  • _this select 6: (optional) ammunition count range (Array)
  • _this select 7: (optional) randomization controls (Array)
    0: amount of mandatory units (Number)
    1: spawn chance for the remaining units (Number)
  • _this select 8: (optional) azimuth (Number)

Returns:

The group (Group)

Looking through the code, you can supply an empty array to get the default setting for any parameters you don't actually want to pass through.

_this select 7 is the one that's interesting for your question, and the default settings for that are [-1, 1]. If the number of units is set to -1, then no unit in the units type array will be skipped.

So, I believe the answer is yes, if you pass a list of character types then every single one of those will be created. It also looks like if you pass the same character type twice, you'll get two of them.

Share this post


Link to post
Share on other sites

some kind of guy, thank you very much for help.

(I didn't have time to exemine that script :) )

Share this post


Link to post
Share on other sites
CPU load on server is only 50-60% (old Athlon 64 X2 @2.0GHz) and 12-14 fps with hundresds of AI at towns total. Why CPU load is not 100% I don't understand. I could understand if 1 core was loalded fully and game was not multi-cpu-friendly.... but BIS say that game is multithreaded and I don't see any of cores fully loaded...let alone all cores loaded.... very strange game engine..

It's not that strange, it's not as if you can just tell the computer to "use all the cores" and have it magically balance the load perfectly across all processors.

I think the main thing is contention for access to objects in memory, so even though they've probably split the physics, AI, rendering, scripts and maybe input into independent threads, they all need to operate on the same entities and only one part of the game can be accessing each one at a time.

So most likely, each part of the game spends a lot of time waiting for its chance to access each object, which is why nothing ever manages to consume 100% CPU. Not to mention all the low-level details like trying to keep cache-hits high for the local cache on each core... I think if you access something in system memory from two different cores, they'll be constantly flushing and refreshing the local processor cache in order to get the updated data to the CPU.

Gotta remember, the engine is from Operation Flashpoint way back in 2001 or something, so the fact it manages to use more than one core at all is pretty impressive. Hopefully there'll be more optimisations and improvements to come, but parallel execution is difficult to get right even if you're designing it from scratch -- converting a single-threaded app of the complexity of this game into a multi-threaded one isn't my idea of a good time, that's for sure.

Share this post


Link to post
Share on other sites

yes, it is still OFP from 2000's , I remember.. a bit modified... :)

I just don't understand why big AI numbers make game behave such strangely. I have written somewhere in relative thread and read comments... the problem was that more AI we have - less CPU load is :D

to my mind, if we have a list of tasks , we can send each core to do one task and when they complete this task, we can send it another one, and even if one core is doing its task longer than other cores, it won't be much longer than others... even if it is too complicated, it can use free cores for example... it is the work for programmers of course...low level programmers (i hope they exist in BIS).... bug this engine (I have heard in 2001 that it used QIII's modified engine) didn't know multicore CPUs that time :)

i think game engine needs rewriting from scratch :D

there are too many disappointing moments in existing engine...

we will soon have 6,8 and even more cored CPU's (unfortunately we are developing not intesively but extensively) and this engine will make our CPUs just a piece of [si] not a Supermachine... sorry for bad english :D )

Share this post


Link to post
Share on other sites

Well surely there are better, more efficient ways to handle the processing of the tasks it needs to process, and "less CPU load for more AI units" very much sounds like resource contention to me - other parts of the game processing are stalled while the AI/physics/something else is processed for those units. And yes, if they spent years rewriting the core of the game they could probably optimise these tasks better.

But there's a cost to doing that: time and money. It's a niche game and there's nothing else that tries that do what Arma 2 does, and the only reason I can think developers aren't targeting this niche is because they don't think they can get a return on the investment. It's easy to say "BIS should do nothing else but optimise the game engine until it's 90% efficient on N-core systems" but if that's going to take them 5 years to do, it may simply be impossible. i.e. they'd run out of money before it was finished.

Even if it was possible, I don't want to go 5 years without substantial updates to the game. And in 5 years' time, computer hardware will be even more powerful than it is today and there'll be no performance issues, anyway. ;)

Now I don't know for sure BIS' reasons, but presumably if they could make a business case for rewriting the core to scale better, they certainly would. I doubt very much that they want their Real Virtuality engine to fall so far behind modern hardware (i.e. multi-core) that it becomes impossible to make modern games with it.

Rewriting from scratch is much easier to suggest than to do. It would likely kill the series if they tried it, and quite possibly kill BIS as well. Consider Duke Nukem Forever; they rewrote their engine every few years when it became outdated, and the result? Over a decade and millions of dollars in development, and nothing to show for it. I'll take a somewhat buggy, unoptimised game I can actually play over a 100% perfect piece of vapourware any day. :)

Quake 3 engine? I wouldn't think so... id tech 3 is designed for fast-paced indoor arenas, not large open outdoor areas with hundreds of units and vehicles and ballistics and tactics and so on. It seems like a very unlikely match-up, and I've never read anything anywhere to suggest the games ever used anything other than the BIS-developed Real Virtuality engine. Also the 'feel' of BIS' games is very different to feel of pretty much any other FPS, especially id's games.

Share this post


Link to post
Share on other sites

by the way, they could make great money, because their engine is nearly unique - huge territory and freedom of movement is the thing I like in OFP/Arma. Well, of course it has many restrictions, but if they made another unique engine with many tasty features , they could simply sell it to other game dev's , like ID Software did some time ago.

And.. it is my dream...

...companies from different countries could collect their efforts and assets in multinational project with such engine development. This engine could become a base for many PC games in the world. Like Linux in OSes.... it is used everywhere!

-------------------

by the way, I'm having troubles with spawning units....

most infantry units are dead :D Light and heavy vehicles are alive. I spawn them to different locations (to avoid driving over infantry), but they are dead even with that...

Do you know why could it be?

Edited by McArcher

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×