Advertisement
Guest User

Untitled

a guest
Jul 21st, 2017
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.23 KB | None | 0 0
  1. [] spawn
  2. {
  3. private ["_units"];
  4.  
  5. sleep 20; //wait for start
  6. if (b_rand1 <= 3) then
  7. {
  8. switch (true) do
  9. {
  10. case (b_rand1 == 0): {haltedgroups = [r_halt5,r_halt6,r_halt7,r_halt8]};
  11. case (b_rand1 == 1): {haltedgroups = [r_halt5,r_halt6,r_halt7,r_halt8]};
  12. case (b_rand1 == 2): {haltedgroups = [r_halt9,r_halt10,r_halt11,r_halt12]};
  13. case (b_rand1 == 3): {haltedgroups = [r_halt13,r_halt14,r_halt15,r_halt16]};
  14. };
  15.  
  16. {{_x setVehicleInit "_x action ["sitdown", _x];"; processInitCommands;} foreach units (group _x);} foreach haltedgroups;
  17. };
  18.  
  19. while {!b_reinforceRED && !b_contactRED} do
  20. {
  21. _units = [];
  22. {
  23. if (([getPos _x, "aom"] call CBA_fnc_inArea) && (side _x == WEST) && (EAST knowsAbout _x > 0)) then
  24. {
  25. _units = _units + [_x];
  26. };
  27. } forEach allUnits;
  28.  
  29. if (count _units > 2) then
  30. {
  31. b_contactRED = true;
  32.  
  33. if (b_rand1 <= 3) then
  34. {
  35. {{_x setVehicleInit "_x doFollow (leader (group _x));"; processInitCommands;"} foreach units (group _x);} foreach haltedgroups;
  36. };
  37. };
  38.  
  39. if (count _units > 8) then
  40. {
  41. sleep (300 + (random (300) + random (300)));
  42. b_reinforceRED = true;
  43. };
  44. sleep 10;
  45. };
  46. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement