Jump to content

[RELEASE] Vehicle Patrols on missions


Recommended Posts

  • 10 months later...
  • 2 weeks later...
On 4/18/2014 at 11:11 PM, Asian Kid said:

Can you post your one of your missions?

This is one of my custom missions I made. My dzms have hero/bandit missions instead of major/minor. Vehicles work fine for me even static weapons and helis.

Spoiler

private ["_missName","_coords","_base","_patrol","_patrol2","_patrol3","_crate","_txt"];

_missName = "[Mission] Gem Bunker";

_coords = call AIMissionFindPos;

_txt = "Bandit's are at the Bunker! Clear the Fuckers Out and get the GEMS!";
fnc_show_colorAdminMsg = [_txt,'#F00000'];
publicVariable 'fnc_show_colorAdminMsg';

[_coords,_missName] ExecVM BanditMarker;

_base = createVehicle ["Land_MBG_HeavyShelter",_coords,[], 0, "CAN_COLLIDE"];
_base setDir 152.66766;
_base setPos _coords;

[_base] call ProtectObj;

_crate = createVehicle ["USVehicleBox",[(_coords select 0) + 0.7408, (_coords select 1) + 1.565, 0.10033049],[], 0, "CAN_COLLIDE"];
[_crate,"GemsBox"] ExecVM BoxSetup;
[_crate] call ProtectObj;
_crate2 setDir -27.93351;

_patrol = [_coords, 50, 3] call BanditAIVehiclePatrol;
_patrol2 = [_coords, 30, 3] call BanditAIVehiclePatrol;
_patrol3 = [_coords, 40, 3] call BanditAIVehiclePatrol;

[[(_coords select 0) - 4.0796, (_coords select 1) - 11.709,0],6,4,"BanditUnits","bandit","bandit"] call AISpawn;
sleep 3;
[[(_coords select 0) + 2.8872, (_coords select 1) + 18.964,0],6,2,"BanditUnits","bandit","bandit"] call AISpawn;
sleep 3;
[[(_coords select 0) - 4.0796, (_coords select 1) - 11.709,0],6,4,"BanditUnits","bandit","bandit"] call AISpawn;
sleep 3;
[[(_coords select 0) + 2.8872, (_coords select 1) + 18.964,0],6,2,"BanditUnits","bandit","bandit"] call AISpawn;
sleep 3;
[[(_coords select 0) - 4.0796, (_coords select 1) - 11.709,0],6,4,"BanditUnits","bandit","bandit"] call AISpawn;
sleep 3;
[[(_coords select 0) - 1.0796, (_coords select 1) - 3.709,0],6,4,"BanditUnits","bandit","bandit"] call AISpawn;
sleep 3;

[_coords,"BanditUnits"] call WaitMissionComp;

[_vehicle] ExecVM SaveVeh;

_txt = "The GEMS are under Hero Control!";
fnc_show_colorAdminMsg = [_txt,'#F00000'];
publicVariable 'fnc_show_colorAdminMsg';

diag_log text format["[AI Missions]: Bandit Gem Bunker Mission has Ended."];
deleteMarker "BanditMarker";
deleteMarker "BanditDot";

BanditDone = true;

Everything works no errors.

Link to comment
Share on other sites

  • 8 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement
×
×
  • Create New...