Announcement

Collapse
No announcement yet.

AI rotating too far when focusing on player?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    AI rotating too far when focusing on player?

    My AI is rotating too far when the player gets too close to it. Its using set focal point in behavior trees and I think its necessary to keep it constantly rotating while casting a spell. Any ideas?

    https://imgur.com/GkTe3jn

    #2
    It looks like it's focusing on the feet? Try getting the coordinate of the player character pelvis, or get the position of the feet, and add the monster's height as an up vector to that, to make the focus point.

    Comment


      #3
      Thanks that sound like a good idea. I've been trying to figure out how to make that work properly but once again I'm stumped I've split the actors location into a vector and made a new one with an increase in the Z to account for monsters height but it isn't constantly set while the spell is casting. It just focuses on the point, cast the spell, then rotates to the new location and repeats. Ive tried setting it as a blackboard key and making it a service (in hopes that it'll constantly rotate). I suppose it's not the biggest problem but it just looks a lot better if it rotates with the player while it casts the spell.
      Attached Files

      Comment

      Working...
      X