I made a thread about this a long time ago for the Hag character, and I've gotten a little better at scripting since then, but I still can't get the Cleopatra MELEE character to follow the PATH of the player, and open doors if the player decides to close them. Normally, Cleopatra just goes in the DIRECTION of the player, completely ignoring walls. So when the player rounds a corner, she just runs into it until she slides past it. This is how most enemies work, but I've always found it pretty annoying. Especially now because I can't get my solution working. I know it's possible to make the enemy follow the path of the player and open doors, because in my old thread, Conjured Entertainment helped me accomplish this with the hag character. So what I tried was taking the part of that script that I thought made the enemy do this, and combined it with the Cleopatra script I have. I've already successfully combined a dialogue script with the original Cleopatra main script, and it works perfectly, which I'm proud of myself for
. Except for the fact that she runs into walls. I've tried everything I can think of, but still no luck. So could someone please help me out here? Maybe tell me what I'm doing wrong? Am I even using the right commands?
;Artificial Intelligence Script
;Header
desc = Linda's first conversation with Amirah
;Triggers
;WALKING WAYPOINTS
:state=0:state=1
:state=50:state=19,rotatetoplr
;DIALOGUE
:state=1,plrdistwithin=100:rotatetoplr
:state=1,plrcannotbeseen:rotatetoplr
:state=1:lookatplr=80,state=2
:state=2,plrdistwithin=100:lookatplr=80
:state=2,plrdistwithin=100:rotatetoplr
:state=2,pickobject=1,plrdistwithin=60,plrusingaction=1:timerstart,plrdisable=100000,state=3
:state=3:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=3:fpgcrawtext=AMIRAH: Hello Linda.
:state=3,timergreater=500,plrusingaction=1:timerstart,state=4
:state=3,scancodekeypressed=211:plrdisable=0,state=0
:state=4:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=4:fpgcrawtext=LINDA: Hey Amirah. I still haven't found the entrance key yet...
:state=4,timergreater=500,plrusingaction=1:timerstart,state=5
:state=4,scancodekeypressed=211:plrdisable=0
:state=5:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=5:fpgcrawtext=AMIRAH: That's because I have it.
:state=5,timergreater=500,plrusingaction=1:timerstart,state=6
:state=5,scancodekeypressed=211:plrdisable=0
:state=6:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=6:fpgcrawtext=LINDA: Oh really? Well what are we waiting for? Let's get out of here!
:state=6,timergreater=500,plrusingaction=1:timerstart,state=7
:state=6,scancodekeypressed=211:plrdisable=0,state=0
:state=7:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=7:fpgcrawtext=AMIRAH: I'm afraid I can't let that happen.
:state=7,timergreater=500,plrusingaction=1:timerstart,state=8
:state=7,scancodekeypressed=211:plrdisable=0,state=0
:state=8:music=audiobank\music\terrorstrike\tension.wav
:state=8:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=8:fpgcrawtext=LINDA: ...What?
:state=8,timergreater=500,plrusingaction=1:timerstart,state=9
:state=8,scancodekeypressed=211:plrdisable=0,state=0
:state=9:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=9:fpgcrawtext=AMIRAH: Linda... Don't you see? You're the next idol to take the throne.
:state=9,timergreater=500,plrusingaction=1:timerstart,state=10
:state=9,scancodekeypressed=211:plrdisable=0,state=0
:state=10:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=10:fpgcrawtext=LINDA: What?! What are you talking about?!
:state=10,timergreater=500,plrusingaction=1:timerstart,state=11
:state=10,scancodekeypressed=211:plrdisable=0,state=0
:state=11:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=11:fpgcrawtext=AMIRAH: It was no coincidence that you came here. It was destiny.
:state=11,timergreater=500,plrusingaction=1:timerstart,state=12
:state=11,scancodekeypressed=211:plrdisable=0,state=0
:state=12:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=12:fpgcrawtext=LINDA: No! What happened to you Amirah?!
:state=12,timergreater=500,plrusingaction=1:timerstart,state=13
:state=12,scancodekeypressed=211:plrdisable=0,state=0
:state=13:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=13:fpgcrawtext=AMIRAH: I am the head mistress. I am the one who conducts the Ceremony of Gutting.
:state=13,timergreater=500,plrusingaction=1:timerstart,state=14
:state=13,scancodekeypressed=211:plrdisable=0,state=0
:state=14:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=14:fpgcrawtext=LINDA: ...I trusted you!!
:state=14,timergreater=500,plrusingaction=1:timerstart,state=15
:state=14,scancodekeypressed=211:plrdisable=0,state=0
:state=15:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=15:fpgcrawtext=AMIRAH: That was the plan. I need you to trust me Linda. Destiny brought you to us!
:state=15,timergreater=500,plrusingaction=1:timerstart,state=16
:state=15,scancodekeypressed=211:plrdisable=0,plrmovewest=4000
:state=16:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=16:fpgcrawtext=LINDA: Get the hell away from me!!
:state=16,timergreater=500,plrusingaction=1:timerstart,state=17
:state=16,scancodekeypressed=211:plrdisable=0
:state=17:fpgcrawtextsize=24,fpgcrawtextfont=verdana,fpgcrawtextr=150,fpgcrawtextg=150,fpgcrawtextb=150,fpgcrawtextx=50,fpgcrawtexty=80
:state=17:fpgcrawtext=AMIRAH: Don't fight me Linda. Don't make this harder than it has to be.
:state=17,timergreater=500,plrusingaction=1:timerstart,state=18
:state=17,scancodekeypressed=211:plrdisable=0
:state=18,timergreater=100:plrdisable=0,music=audiobank\music\terrorstrike\chase2.wav,state=19
;DETECT PLAYER
:nearactivatable=0:settarget,activatetarget=2,
:state=19,plrdistfurther=59,plrcanbeseen:rotatetoplr,animate=3,movefore=1:state=50
:state=19,plrdistfurther=59,plrcannotbeseen:animate=3,followplr=1:state=50
:state=19,plrdistwithin=200:camfov=0,rotatetoplr
:state=19,plrdistwithin=60:waypointstop,state=21
;INTRO ANIMATION
:state=20:waypointstop,incframe=96
:state=20,frameatend=96:state=21
;CHOOSE MELEE ATTACK & RUN OR WALK
:state=21,random=2:state=22
:state=21,random=2:state=25
;MELEE ATTACK 1
:state=22,plrdistfurther=50:waypointstop,rotatetoplr,movefore=2,animate=92
:state=22,plrdistwithin=50:waypointstop,rotatetoplr,setframe=93,state=23
:state=23,framebeyond=93 60,plrdistwithin=60:plraddhealth=-10,sound=audiobank\misc\melee.wav,state=24
:state=23:incframe=93,rotatetoplr
:state=23,frameatend=93:state=21
:state=24:incframe=93
:state=24,frameatend=93:state=21
;MELEE ATTACK 2
:state=25,plrdistfurther=50:waypointstop,rotatetoplr,runfore=2,animate=94
:state=25,plrdistwithin=50:waypointstop,rotatetoplr,setframe=95,state=26
:state=26,framebeyond=95 60,plrdistwithin=60:plraddhealth=-10,sound=audiobank\misc\melee.wav,state=27
:state=26:incframe=95,rotatetoplr
:state=26,frameatend=95:state=21
:state=27:incframe=95
:state=27,frameatend=95:state=21
;End of Script
"Never tell me the sky's the limit when there are footprints on the moon."