For the artillery, you could use the following script (I used it myself in one of my missions; I only edited it in 3 lines or so to make it work in multiplayer):
It's originally from Fishion and modified by General Barron as you can see.
The parameters are well explained so there is not much more to say about it.
It's originally from Fishion and modified by General Barron as you can see.
The parameters are well explained so there is not much more to say about it.
Code:
;// Generic Artilly Script
;//
;// by Fishion
;// Modified by General Barron to make a circular impact area instead of a square one.
;//
;// I made this because of the enourmous number of Artillery Scripts
;// which use Men to place bombs, Vehicles to create the illusion of
;// an explosion, or simple in a different from to shoot smoke shells
;//
;// to replace all those Artillery Simulating Scripts this should be sufficient
;// to the needs of most people (evan has sound)
;//
;// big advantage is you can actually choose the ordanace (if you wish you
;// shoot Boats or Car by the Artillery, eventhough this is simply stupid)
;//
;// (c)Aug 2001
;//
;//********************
;//**** Parameters ****
;//********************
;// Target Coordinates:
;// This should be an array containing min 2 numbers (X and Y Coord) but a normal
;// GetPos should do (no select 0 etc.)
_coords = _this select 0
;// Type of Ordanance (String Value), look at Weapons and Ammo or Objects Tree for types
_ord = _this select 1
;// Height (numeric) at which Ordanance should be Spawned (150 or so works fine)
_height = _this select 2
;// Number of volley fired by the Artillery
_VolleyNr = _this select 3
;// Number of Shots in each Volley
_ShotNr = _this select 4
;// Time between Volleys
_vTime = _this select 5
;// Time Variation between Volley (the Max deviation from _vtime)
_vTimeVar = _this select 6
;// Time Variation within each Volley
;// (Note: For Time on Target Barrages (ToT) put a 0 here)
_vTimeVol = _this select 7
;// Maximum Distance for shots off the Aimed Point
_radius = _this select 8
;//************************
;//**** Parameters END ****
;//************************
;//Put in Radiochatter here!
;//**************************
;//**** Main Arty Script ****
;//**************************
_nr = 0
#loop
?(_nr >= _Volleynr):goto "ende"
_volnr = 0
;//inner loop (within volley)
#volley
;// Increment Counter
_volnr = _volnr + 1
;// create ordonance
_tmp = _ord createVehicle [(_coords select 0) + (random _radius) - (_radius / 2), (_coords select 1)
+ (random _radius) - (_radius / 2), _height]
_tmp setDammage 1
~1
_tmp setDammage 0.3
deleteVehicle _tmp
;// wait a random time for the next Shot
;// (note _vTimeVol is the total time a Barrage needs to land, thus devided by the number
;// of shots)
;// wait and avaoid errormessage
?(_shotnr == 0):goto "avoid"
~(Random(_vTimeVol / _Shotnr))
goto "endrnd"
#avoid
~0.1
#endrnd
?(_volnr <= _Shotnr):goto "volley"
;//innerloop end
;// Increase Counter
_nr = _nr + 1
~(_vtime + (Random _vTimeVar ))
goto "loop"
#ende
;//Put in Radiochatter here!