Page 1 of 1

Should A_FaceTarget affect A_Chase with flags?

PostPosted: Sat Dec 30, 2017 11:50 am
by ibm5155
By that I mean something like this

TNT1 A 0 A_FaceTarget
MONS A 1 A_Chase("Melee","",CHF_NORANDOMTURN)

the monster should Always walk into the target direction right? but I tested it and the monster just walks in a straight line (with angle = 0 I belive)

Re: Should A_FaceTarget affect A_Chase with flags?

PostPosted: Sat Dec 30, 2017 11:56 am
by AFADoomer
I assume that you meant "A_FaceTarget", not "FaceTarget"?

Re: Should A_FaceTarget affect A_Chase with flags?

PostPosted: Sat Dec 30, 2017 12:05 pm
by ibm5155
AFADoomer wrote:I assume that you meant "A_FaceTarget", not "FaceTarget"?

Correct

Re: Should A_FaceTarget affect A_Chase with flags?

PostPosted: Sat Dec 30, 2017 5:45 pm
by Arctangent
A_Chase does not move the actor forward, but instead uses its own method of determining what direction the actor will move in.

Re: Should A_FaceTarget affect A_Chase with flags?

PostPosted: Sun Dec 31, 2017 10:53 am
by AFADoomer
Can you post your actor's entire code? There's not enough here to tell what's going on.

Re: Should A_FaceTarget affect A_Chase with flags?

PostPosted: Tue Jan 02, 2018 7:26 pm
by ibm5155
Here's an example code:
Code: Select allExpand view
actor Specimen10_Tracer

  Monster
  Damage 0
  +LOOKALLAROUND
  -SOLID
  +DROPOFF
  +FLOORHUGGER
  +NOCLIP
  Speed 57
  Scale 0.2
  States
  {
  Spawn:
   TNT1 A 0 NoDelay Thing_ChangeTID(0,3341)
        SP10 M 1 Bright A_Look   
    Loop
    See:
   TNT1 A 0 A_FaceTarget
   SP10 M 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 M 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 N 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 N 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 O 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 O 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 P 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 P 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 Q 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 Q 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 R 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 R 1 A_A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 S 1 A_Chase("Melee","",CHF_NORANDOMTURN)
   TNT1 A 0 A_FaceTarget
   SP10 S 1 A_Chase("Melee","",CHF_NORANDOMTURN)
    Loop
  Melee:
    SP10 M 0 A_FaceTarget
    SP10 M 2 A_CustomMeleeAttack(14,"SNDHIT","","Melee",false)
   Goto Death
  Death:
    TNT1 A 1
    Stop
  }
}



...
I fixed that by replacing
Code: Select allExpand view
SP10 R A_Chase("Melee","",CHF_NORANDOMTURN)

by
Code: Select allExpand view
   SP10 R 1 A_SkullAttack
   TNT1 A 0 A_Stop
   TNT1 A 0 A_JumpIfTracerCloser(64.0,"Melee")



But still I feel like A_FaceTarge should actually affect the direction that the monster is going to walk in case the "CHF_NORANDOMTURN" flag is used