OFPEC Forum

Editors Depot - Mission Editing and Scripting => ArmA - Editing/Scripting General => Topic started by: Ding on 05 Aug 2007, 14:13:07

Title: Random Mortar Explosion
Post by: Ding on 05 Aug 2007, 14:13:07
I've created a basic little script which makes shells drop randomly between two Game Logics named Pos1 and Pos2 I was hoping maybe someone could help me take it one step further by making the shells land say randomly within a 100 metre radius of either game logic? Using the script below I can make them drop randomly between the two posistions but I've no idea where to go from there on in order to make them drop randomly all around the two posistions.

Code: [Select]
#Start
_num = Mortar_bang
_rand = random 3
_num = _rand - (_rand mod 1)

?_num == 1 : Mortar_bang = 1
?_num == 2 : Mortar_bang = 2
?_num == 0 : goto "start"
exit
Title: Re: Random Mortar Explosion
Post by: Mandoble on 05 Aug 2007, 14:42:37
Check here (http://www.ofpec.com/forum/index.php?topic=29930.0)
Title: Re: Random Mortar Explosion
Post by: Ding on 05 Aug 2007, 14:49:32
Thankyou Mandoble :)