Ive thought about the AI and their firing in the game, seems its either way too accurate sometimes or rediculously lame.--EG choppers firing at ground troops--even when the chopper does fire sometimes he can empty his entire browning MAG at a spot one foot away from a stationary careless target
and all the bullets went into the same hole
So i made this wee script but need help to make it so the AI doing the firing also sprays a bit above and below the target also.
Its works quite well actually, it only activates when an AI fires and deactivates 0.3 seconds after he has fired.
tried it on infantry and a lot more bullets went flying than normal, less hits--I thought with propper tweaking it could resemble more wot real weapons and average soldiers would be really like.
Perhaps more real if it were applied only to certain types of weapons. I dunno too much about ballistic and such but I wonder sometimes about AK accuracy and how AI fire--looking more for the "pray and spray" effect here by AI that is ;D
We all know that when humans in the game apply suppressing fire I SURE as heck get my butt down to cover.
Funny thing is that in some circumstances this lil script actually makes guns MORE effective in killing--eg Machine gun. An old soldier told me once that u dont wanna MG to be too accurate--u want it to scatter fire and blanket an area.
activated by this in INIT: of unit
unit addeventhandler ["fired", {_this exec "spray.sqs"}]
;spray script
_man = _this select 0
   _count = 0
   _start1 = "start1"
   _start2 = "start2"
   _start1_and_start2_array = [_start1, _start2]
   _random = random (count _start1_and_start2_array)
   _random = _random - _random % 1
   _randomstart = _start1_and_start2_array select _random
   _man removealleventhandlers "fired"
   _mandir = getdir _man
   goto _randomstart
#start1
   _man setdir _mandir
   _mandir = _mandir + 0.06
   _count = _count + 1
   ? _count > 30: goto "end"
   ~0.01
   goto "start1"
#start2
   _man setdir _mandir
   _mandir = _mandir - 0.06
   _count = _count + 1
   ? _count > 30: goto "end"
   ~0.01
   goto "start2"
#end
   _man addeventhandler ["fired", {[_this select 0] exec "spray.sqs"}]
exit
Your thoughts, suggested improvements welcome
Especially for firing above and below target--I dunno if thisll work for a gunner in a chopper cause it uses setdir and when a guy is in a chopper I think his direction is determined the direction of the chopper , not where hes facing. I could be wrong tho. ;D
Zay out