Second post was meant to take out the random reload line, but the edit button doesn't seem to work right, for me anyways. Won't affect anything since there's not yet an animation attached to it (forgot), but I have a feeling the occurrence rate is too high, and it doesn't really need to be there anyways. Don't have time for a few days to add the reload animation. And thanks for the feedback Mag.
So, very slightly updated:
;Artificial Intelligence Script
;Header
desc = Test AI
;Triggers
:state=0,animationover=2,random=36:animate=2,rotatey=90,state=1
:state=0,animationover=2,random=35:animate=2,rotatey=-90,state=1
:state=0:animate=2,state=1
:state=1,raycastback=0 30:pivotrandom=180
:state=1,raycastback=0 -30:pivotrandom=180
:state=1:movefore=8
:state=1,plrdistwithin=350,plrcanbeseen:rotatetoplr,state=2
:state=1,plrdistwithin=100,noiseheard=1:rotatetoplr,state=2
:state=1,shotdamage=1:rotatetoplr,state=2
:state=1:state=0
:state=2,ifweapon=1:state=3
:state=2,ifweapon=0:reloadweapon,sound=audiobank\guns\reload.wav,state=3
:state=3,random=14:state=6
:state=3,random=17:state=7
:state=3,raycastback=0 30:pivotrandom=180
:state=3,raycastback=0 -30:pivotrandom=180
:state=3,healthless=25,shotdamage=1:pivotrandom=360,state=4
:state=3,plrdistwithin=300,plrcanbeseen,random=1:rotatetoplr,settarget,useweapon,rundecal=6,state=2
:state=3,plrdistfurther=300:state=5
:state=4:animate=5,runfore=10
:state=4,animationover=5,plrdistwithin=300,plrcanbeseen:rotatetoplr,settarget,useweapon,rundecal=6,state=2
:state=4,animationover=5:state=5
:state=5:rotatetoplr
:state=5:animate=5,runfore=3
:state=5,animationover=5:state=2
:state=6:animate=4,strafe=90,rotatetoplr
:state=6,animationover=4:state=3
:state=7:animate=3,strafe=-90,rotatetoplr
:state=7,animationover=3:state=3
;End of script