Advertisement
Guest User

Untitled

a guest
Jul 4th, 2015
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.13 KB | None | 0 0
  1. if(isServer) then {
  2.  
  3. private ["_unitGroup","_complete","_vehicle","_rndnum","_crate_type","_crate","_mission","_tanktraps","_mines","_playerPresent","_cleanmission","_currenttime","_starttime","_missiontimeout","_vehname","_veh","_position","_vehclass","_vehdir","_objPosition"];
  4.  
  5. // Get mission number, important we do this early
  6. _mission = count wai_mission_data -1;
  7.  
  8.  
  9. _fn_position = [5] call find_position;
  10. _position = _fn_position select 0;
  11. _missionType = _fn_position select 1;
  12.  
  13. [_mission,_position,"easy","Sniper Team","MainBandit",true] call mission_init;
  14.  
  15. diag_log format["WAI: [Mission: Sniper Team]: Starting... %1",_position];
  16.  
  17. _crate = [0,_position] call wai_spawn_create;
  18.  
  19. // Base
  20. _baserunover = createVehicle ["Land_HelipadEmpty_F",[((_position select 0) + 5), ((_position select 1) + 5), -150],[],10,"CAN_COLLIDE"];
  21. _baserunover setVectorUp surfaceNormal position _baserunover;
  22. // Unit
  23. _unitGroup = [[(_position select 0) + (random(30)+1),(_position select 1) - (random(35)+1),0],4,"easy","random","bandit",_mission] call spawn_group;
  24.  
  25. // PARA
  26. [
  27. [(_position select 0),(_position select 1),0],
  28. [0,0,0],
  29. 200,
  30. "B_Heli_Light_01_F",
  31. 4,
  32. "easy",
  33. "Random",
  34. "bandit",
  35. false,
  36. _mission
  37. ] spawn heli_para;
  38.  
  39. // Condition
  40. _complete = [
  41. [_mission,_crate], // mission number and crate
  42. ["assassinate",_unitGroup], // ["crate"], or ["kill",wai_kill_percent], or ["assassinate", _unitGroup],
  43. [_baserunover], // cleanup objects
  44. $STR_sniper_team_mission_announcement,
  45. // "Our scouts have spotted a sniper team, check the map for their location", // mission announcement
  46. $STR_sniper_team_mission_success,
  47. // "Survivors have killed the snipers!", // mission success
  48. $STR_sniper_team_mission_fail
  49. // "Survivors did not secure the sniper rifles in time" // mission fail
  50. ] call mission_winorfail;
  51.  
  52. if(_complete) then {
  53. [_crate,[6,ai_sniper_wep],[6,(ai_sniper_gear+ai_sniper_skin+ai_sniper_scope)],0,0] call dynamic_crate;
  54. };
  55.  
  56. diag_log format["WAI: [Mission: Sniper Team]: Ended at %1",_position];
  57.  
  58. b_missionsrunning = b_missionsrunning - 1;
  59. };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement