SHARE
TWEET

Untitled

a guest Apr 16th, 2019 137 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. 0 = [EAST, 5, "MOVE", "2", "1"] spawn {
  2.    private _cacheGroup = true;
  3.  
  4.    private _side = param [0, EAST];
  5.    private _count = param [1, 2 + floor random 4];
  6.    private _GAIA_action = param [2, "MOVE"];
  7.    private _ZONE = param [3, "1"];
  8.    private _TARGETZONE = param [4, _zone];
  9.  
  10.    private _classnames = [];
  11.    private _mygroup = [];
  12.    private _markerpos = getMarkerpos _zone;
  13.    private _markersize = if (((getMarkerSize _zone) select 0) > ((getMarkerSize _zone) select 1)) then {(getMarkerSize _zone) select 0} else {(getMarkerSize _zone) select 1};
  14.    private ["_spawnpos", "_faction"];
  15.    for "_i" from 1 to _count do {
  16.       switch (_side) do {
  17.          case WEST: {_faction = selectrandom ["BLU_F","BLU_G_F","BLU_T_F","BLU_CTRG_F"]};
  18.          case EAST: {_faction = selectrandom ["OPF_F","OPF_G_F","OPF_T_F"]};
  19.          default    {_faction = selectrandom ["IND_F","IND_G_F","IND_C_F"]};
  20.       };
  21.       _spawnpos = [(_markerpos select 0) - random _markersize + random _markersize, (_markerpos select 1) - random _markersize + random _markersize, _markerpos select 2];
  22.       while {!(_spawnpos inArea _zone)} do {
  23.          _spawnpos = [(_markerpos select 0) - random _markersize + random _markersize, (_markerpos select 1) - random _markersize + random _markersize, _markerpos select 2];
  24.       };
  25.       _spawnPos = [_spawnPos, 0, 100, 2, 0, 20, 0] call BIS_fnc_findSafePos;
  26.       { if ((configName _x) isKindoF "CAManBase") then {_classnames pushback (configName _x)};
  27.       } forEach ("getText (_x >> 'faction') == _faction" configClasses (configfile >> "CfgVehicles"));
  28.       _mygroup resize (3 + floor random 5);
  29.       _mygroup = _mygroup apply {selectrandom _classnames};
  30.       _Group = [_spawnPos, _side, _myGroup] call BIS_fnc_spawnGroup;
  31.       _Group setVariable ["GAIA_ZONE_INTEND",[_TARGETZONE, _GAIA_action], false];
  32.       if (_cacheGroup) then {_group setVariable ["mcc_gaia_cache", true, true]};
  33.       sleep 0.3;
  34.    };
  35. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top