Jump to content

Recommended Posts

Is it possible to create the amount of ammo to be fired in this script.....

_ammo = getArtilleryAmmo [gun1] select 0; 
_rounds = 30; 
while {_rounds>0} do { 
 _dir = round random 360; 
 _dis = round random 180;
 _tgt = target1 getRelPos [_dis, _dir]; 
 gun1 doArtilleryFire[_tgt,_ammo,1]; 
 _rounds = _rounds - 1; 
 _time = round (random 90);
sleep _time;
};

I've tried increasing the _rounds, the _ammo, the - rounds, the round (random 90) but gun1 still only fires 24 rounds. Thanks in advance.

 

Share this post


Link to post
Share on other sites

You need to reload your artillery.

simple way: add a vehicle ammo crate near gun1

scripted way: gun1 setVehicleAmmo 1  inside the while do loop  ( for unlimited ammo)

Share this post


Link to post
Share on other sites

Thanks for reply and solution pierremgi. I'll get on to it. 👍

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

×