Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- private ["_posPl","_xx","_yy","_start","_st","_tank","_tg1","_tg1wp1","_group","_class","_air"];
- sleep (random 20);
- _posPl = _this select 0;
- if (count VehicleGroups < EVEHMAX) then {
- _xx = random (1100);
- _yy = 1100 - _xx;
- if (random 1 < 0.5) then {_xx = _xx*(-1)};
- if (random 1 < 0.5) then {_yy = _yy*(-1)};
- _start = [(getposATL (vehicle player) select 0) + _xx,(getposATL (vehicle player) select 1) + _yy,0];
- _st = [_start, 400,"(1 - forest) * (1 - sea) * (1 - houses)"] CALL FUNKTIO_POS;
- _start = (_st select 0) select 0;
- while {surfaceIsWater [_start select 0, _start select 1] || {_start distance _x < 500} count VarBlackListE > 0} do {
- _xx = random (1100);
- _yy = 1100 - _xx;
- if (random 1 < 0.5) then {_xx = _xx*(-1)};
- if (random 1 < 0.5) then {_yy = _yy*(-1)};
- _start = [(getposATL (vehicle player) select 0) + _xx,(getposATL (vehicle player) select 1) + _yy,0];
- _st = [_start, 400,"(1 - forest) * (1 - sea) * (1 - houses)"] CALL FUNKTIO_POS;
- _start = (_st select 0) select 0;
- };
- if (random 1 < 0.7) then {
- _tank = VarVEH call BIS_fnc_selectRandom;
- _tg1 = [_start, 0, _tank, EAST] call BIS_fnc_spawnVehicle;
- _tg1wp1= (_tg1 select 2) addWaypoint [_posPl, 0];
- [(_tg1 select 2), 1] setWaypointBehaviour "COMBAT";
- VehicleGroups set [count VehicleGroups,(_tg1 select 2)];
- _nul = [(_tg1 select 2),"ColorRed"] SPAWN FUNKTIO_GM;
- _nul = [(_tg1 select 0), _posPl] SPAWN FUNKTIO_VS;
- CARS set [count CARS,(_tg1 select 0)];
- if (random 1 > VarRes) then {(_tg1 select 0) setfuel (random VarRes);};
- } else {
- if (VarAIR && VarRes > 0.3) then {
- _group = [[8152.21,1975.24,0], EAST, ["TK_Soldier_Pilot_EP1"],[],[],[0.4,0.8]] call BIS_fnc_spawnGroup;
- _class = ["L39_TK_EP1","Su25_TK_EP1"];
- if (isClass(configFile >> "cfgVehicles" >> "BMP2_TK_2035")) then {_class = ["Su25_TK_2035","L39_TK_2035"];};
- _class = _class call BIS_fnc_selectRandom;
- _air = createVehicle [_class, [8152.21,1975.24,0], [], 0, "NONE"];
- _air setdir 240;
- CARS set [count CARS,_air];
- leader _group moveindriver _air;
- _tg1wp1= _group addWaypoint [_posPl, 0];
- [_group, 1] setWaypointBehaviour "AWARE";
- [_group, 1] setWaypointType "GUARD";
- _nul = [_group, [8152.21,1975.24,0],300] SPAWN FUNKTIO_MAD;
- AirGroups set [count AirGroups,_group];
- };
- };
- };
- sleep (random 20);
- if (random 1 < 0.3 && count VehicleGroups < EVEHMAX) then {
- _xx = random (1100);
- _yy = 1100 - _xx;
- if (random 1 < 0.5) then {_xx = _xx*(-1)};
- if (random 1 < 0.5) then {_yy = _yy*(-1)};
- _start = [(getposATL (vehicle player) select 0) + _xx,(getposATL (vehicle player) select 1) + _yy,0];
- _st = [_start, 400,"(1 - forest) * (1 - sea) * (1 - houses)"] CALL FUNKTIO_POS;
- _start = (_st select 0) select 0;
- while {surfaceIsWater [_start select 0, _start select 1] || {_start distance _x < 500} count VarBlackListE > 0} do {
- sleep 0.5;
- _xx = random (1100);
- _yy = 1100 - _xx;
- if (random 1 < 0.5) then {_xx = _xx*(-1)};
- if (random 1 < 0.5) then {_yy = _yy*(-1)};
- _start = [(getposATL (vehicle player) select 0) + _xx,(getposATL (vehicle player) select 1) + _yy,0];
- _st = [_start, 400,"(1 - forest) * (1 - sea) * (1 - houses)"] CALL FUNKTIO_POS;
- _start = (_st select 0) select 0;
- };
- _class = ["BMP2_TK_EP1","BRDM2_TK_EP1","BTR60_TK_EP1","M113_TK_EP1","T34_TK_EP1","T55_TK_EP1","LandRover_MG_TK_EP1","LandRover_SPG9_TK_EP1","UAZ_AGS30_TK_EP1","UAZ_MG_TK_EP1"];
- if (isClass(configFile >> "cfgVehicles" >> "BMP2_TK_2035")) then {_class = ["UAZ_SPG9_TK_2035","T90_TK_2035","BTR90_TK_2035","BRDM2_ATGM_TK_2035","BRDM2_TK_2035","BMP3_TK_2035","BMP2_TK_2035"];};
- _class = _class call BIS_fnc_selectRandom;
- _tg1 = [_start, 0, _class, EAST] call BIS_fnc_spawnVehicle;
- _tg1wp1= (_tg1 select 2) addWaypoint [_posPl, 0];
- [(_tg1 select 2), 1] setWaypointBehaviour "COMBAT";
- VehicleGroups set [count VehicleGroups,(_tg1 select 2)];
- _nul = [(_tg1 select 2),"ColorRed"] SPAWN FUNKTIO_GM;
- _nul = [(_tg1 select 0), _posPl] SPAWN FUNKTIO_VS;
- CARS set [count CARS,(_tg1 select 0)];
- if (random 1 > VarRes) then {(_tg1 select 0) setfuel (random VarRes);};
- };
- sleep (random 30);
- if (random 1 < 0.3 && count VehicleGroups < EVEHMAX) then {
- _xx = random (1100);
- _yy = 1100 - _xx;
- if (random 1 < 0.5) then {_xx = _xx*(-1)};
- if (random 1 < 0.5) then {_yy = _yy*(-1)};
- _start = [(getposATL (vehicle player) select 0) + _xx,(getposATL (vehicle player) select 1) + _yy,0];
- _st = [_start, 400,"(1 - forest) * (1 - sea) * (1 - houses)"] CALL FUNKTIO_POS;
- _start = (_st select 0) select 0;
- while {surfaceIsWater [_start select 0, _start select 1] || {_start distance _x < 500} count VarBlackListE > 0} do {
- sleep 0.5;
- _xx = random (1100);
- _yy = 1100 - _xx;
- if (random 1 < 0.5) then {_xx = _xx*(-1)};
- if (random 1 < 0.5) then {_yy = _yy*(-1)};
- _start = [(getposATL (vehicle player) select 0) + _xx,(getposATL (vehicle player) select 1) + _yy,0];
- _st = [_start, 400,"(1 - forest) * (1 - sea) * (1 - houses)"] CALL FUNKTIO_POS;
- _start = (_st select 0) select 0;
- };
- _class = ["BMP2_TK_EP1","BRDM2_TK_EP1","BTR60_TK_EP1","M113_TK_EP1","T34_TK_EP1","T55_TK_EP1","LandRover_MG_TK_EP1","LandRover_SPG9_TK_EP1","UAZ_AGS30_TK_EP1","UAZ_MG_TK_EP1"];
- if (isClass(configFile >> "cfgVehicles" >> "BMP2_TK_2035")) then {_class = ["UAZ_SPG9_TK_2035","T90_TK_2035","BTR90_TK_2035","BRDM2_ATGM_TK_2035","BRDM2_TK_2035","BMP3_TK_2035","BMP2_TK_2035"];};
- _class = _class call BIS_fnc_selectRandom;
- _tg1 = [_start, 0, _class, EAST] call BIS_fnc_spawnVehicle;
- _tg1wp1= (_tg1 select 2) addWaypoint [_posPl, 0];
- [(_tg1 select 2), 1] setWaypointBehaviour "COMBAT";
- VehicleGroups set [count VehicleGroups,(_tg1 select 2)];
- _nul = [(_tg1 select 2),"ColorRed"] SPAWN FUNKTIO_GM;
- _nul = [(_tg1 select 0), _posPl] SPAWN FUNKTIO_VS;
- CARS set [count CARS,(_tg1 select 0)];
- if (random 1 > VarRes) then {(_tg1 select 0) setfuel (random VarRes);};
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement