What I need is for a character to speak to the player, then when it's finished speaking, a remote door opens.
I've had a go at adapting an existing script for this, but I can't get it to work, can someone tell me what I'm doing wrong and point me in the right direction please.
;Script description
desc = Character will greet player with speech when get close
;Starts level in idle posture, looking around slightly
:state=0:animate=1,state=1
:state=1,random=40:rotateheadrandom=10
;Talk as soon as get within range (or activated)
:state=1,activated=1:talk=$1,state=2
:state=1,plrdistwithin=90:talk=$1,state=2
:state=2,plrcannotbeseen:rotatetoplr
:state=2:lookatplr=80
:state=2,soundfinished=1:state=3
;:state=3,plrdistwithin=90:lookatplr=80
;:state=3,plrdistfurther=90,random=40:rotateheadrandom=10
:state=3:activateifused=1
;End of Script
This is an adaptation of Conjured Entertainment's talk then shoot script, which looks like this;
;Script description
desc = Character will greet player with speech when get close
;Starts level in idle posture, looking around slightly
:state=0:animate=1,state=1
:state=1,random=40:rotateheadrandom=10
;Talk as soon as get within range (or activated)
:state=1,activated=1:talk=$1,state=2
:state=1,plrdistwithin=90:talk=$1,state=2
:state=2,plrcannotbeseen:rotatetoplr
:state=2:lookatplr=80
:state=2,soundfinished=1:state=3
;:state=3,plrdistwithin=90:lookatplr=80
;:state=3,plrdistfurther=90,random=40:rotateheadrandom=10
:state=3:runfpi=people\shootclose10.fpi
;End of Script