29-12-2010, 03:32 PM
salve ecco un bel script di intelligenza artificiale
dovrebbe attaccare in modo casuale e cambiare atteggiamento
dovrebbe attaccare in modo casuale e cambiare atteggiamento
Codice:
;Artificial Intelegence script
;Header
desc = attacco plus 3
;Triggers
:state=0,shotdamage=1:state=1,settarget
:state=0,plrdistwithin=450,rateoffire:rotatetoplr,animate=92
:state=0,plrcanbeseen:state=1,settarget
:state=0:runfpidefault=1
:state=0:settarget,rotatetotarget,resethead
:state=0,plrdistfurther=410,random=20:state=10
:state=0,plrdistwithin=320,random=20:state=20
:state=0,plrdistwithin=120,random=20:state=1
:state=0,plrdistwithin=220,random=20:state=31
:state=0,plrdistfurther=50,random=20:state=7
:state=0,plrdistwithin=500,random=20:state=11
:state=0,plrdistwithin=20,random=20:state=37
:state=0,plrdistwithin=600,random=20:state=42
:state=0,plrdistfurther=1000,random=20:state=43
:state=1,losetarget=100:state=5
:state=1:rotatetoplr
:state=1,plrcanbeseen:settarget
:state=1,ifweapon=1,plrdistfurther=100:movetotarget=1,animate=4
:state=1,plrdistwithin=101:rotatetoplr
:state=1,ifweapon=1,plrdistwithin=400,plrcanbeseen=46,rateoffire:animate=4,rotatetoplr,useweapon,rundecal=6
:state=1,ifweapon=0:animate=3,state=2,setframe=6
:state=1,plrdistwithin=200,random=20:state=5
:state=1,plrdistwithin=50:state=10
:state=2:incframe=6
:state=2,frameatend=6:reloadweapon,sound=audiobank\guns\reload.wav
:state=2,framebeyond=6 60,plrelevfurther=10:useweapon=1
:state=2,framebeyond=6 60,plrdistwithin=100:useweapon=1
:state=2,framebeyond=6 60,plrdistwithin=200:useweapon=30
:state=2,framebeyond=6 60,plrdistwithin=400:useweapon=60
:state=2,frameatend=6:state=1
:state=5,random=1:state=6,setframe=4
:state=5:state=7,setframe=3
:state=6:incframe=4,strafe=90,rotatetoplr
:state=6,frameatend=4:state=1,animate=35
:state=7:incframe=3,strafe=-90,rotatetoplr
:state=7,frameatend=3:state=1,animate=33
:state=10,random=1:rotatetoplr,strafe=135
:state=10,random=1:rotatetoplr,strafe=-135
:state=10,random=1:rotatetoplr,strafe=-65
:state=10,random=1:rotatetoplr,strafe=65
:state=10:state=11,setframe=5
:state=11:incframe=5,strafe=180,rotatetoplr
:state=11,frameatend=5:state=20,animate=53
:state=20,plrcanbeseen:state=21,settarget
:losetarget=10:runfpidefault=1
:state=20:runfpidefault=1
:state=21:rotatetoplr
:state=21,ifweapon=1,plrcanbeseen=46,plringunsight,rateoffire:useweapon,rundecal=6
:state=21,ifweapon=0:state=22,setframe=6
:state=22:incframe=6
:state=22,frameatend=6:state=30,reloadweapon,sound=audiobank\guns\reload.wav
:state=30,plrcanbeseen:state=31,settarget
:state=30:runfpidefault=1
:state=31,losetarget=100:state=35
:state=31:rotatetoplr
:state=31,plrcanbeseen:settarget
:state=31,ifweapon=1,plrdistfurther=100:movetotarget=1,animate=5
:state=31,plrdistwithin=101:rotatetoplr
:state=31,ifweapon=1,plrdistwithin=101,plrcanbeseen=46,rateoffire:animate=54,rotatetoplr,useweapon,rundecal=6
:state=31,ifweapon=0:animate=53,state=32,setframe=6
:state=31,plrdistwithin=200,random=50:state=35
:state=31,plrdistwithin=50:state=40
:state=32:incframe=6
:state=32,frameatend=6:state=31,reloadweapon,sound=audiobank\guns\reload.wav
:state=35,random=1:state=6,setframe=4
:state=35:state=37,setframe=3
:state=36:incframe=4,strafe=90,rotatetoplr
:state=36,frameatend=4:state=31,animate=84
:state=37:incframe=3,strafe=-90,rotatetoplr
:state=37,frameatend=3:state=31,animate=34
:state=40:state=41,setframe=5
:state=41:incframe=5,strafe=180,rotatetoplr
:state=41,frameatend=5:state=0,animate=5
:state=42:incframe=5,strafe=180,rotatetoplr
:state=42,frameatend=5:state=0,animate=3
:state=43:incframe=5,strafe=180,rotatetoplr
:state=43,frameatend=5:state=0,animate=4
;End of script