Jump to content
Sign in to follow this  
GodsFist

Artillery barrage

Recommended Posts

Hello. i'm making a mp mission of the Khe Sanh attack in the Vietnam war and i'm putting in a Artillery barrage.

At the beginning everythin works fine and the Barrage is working great,

but when i put in more than 20 enemies AI the barrage dissapears.

 

Here's my Artillery script that i found on the internet.

 

if (isnil "DZ_fnc_MortarFire") then {
    DZ_fnc_MortarFire = {
        private ["_ammo", "_marker", "_xcoord", "_ycoord", "_timer", "_fire"];
        _ammo = _this select 0;
        _marker = _this select 1;
        _xcoord = _this select 2;
        _ycoord = _this select 3;
        _timer = _this select 4;
        _fire = true;
        while {_fire} do {
            _firerun = _ammo createvehicle [(getmarkerpos _marker select 0) + random _xcoord, (getmarkerpos _marker select 1) + random _ycoord, getmarkerpos _marker select 2];
            sleep (random _timer);
        };
    };
};

I've placed a trigger with mf1 = ["Bo_GBU12_LGB", "mort1", 100, 150, 17] spawn DZ_fnc_MortarFire in the  in the on activation.

and a marker called mort1

 

Can someone please help me what I'm doing wrong.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×