Make The Angle Of An Enemy 'look At' The Actor?

Discussion in 'How Can I...?' started by Scriv, Jul 14, 2019.

  1. Scriv

    Scriv Boxer

    Joined:
    Oct 28, 2018
    Messages:
    50
    Likes Received:
    22
    I need to make a bad guy turn and face the actor on wakeup.... the trigger is simple but the trigonometry isn't... Should have paid more attention in maths class.

    something to do with vectors?
     
  2. whitedogapp

    whitedogapp Avid Boxer

    Joined:
    Oct 8, 2015
    Messages:
    295
    Likes Received:
    72
    and did u already made AI (chasing enemy to character) ?
     
  3. Scriv

    Scriv Boxer

    Joined:
    Oct 28, 2018
    Messages:
    50
    Likes Received:
    22
    Yeah. Following is easy but I’m talking referencing an object’s position in relation to another and rotating that object towards it.

    Sin? Cosin? Mat4? (I mean really what is a mat4?)

    I’m sure I can google it but in case anyone had already done this would be ace to chat.
     
  4. Scriv

    Scriv Boxer

    Joined:
    Oct 28, 2018
    Messages:
    50
    Likes Received:
    22
    Rotation Quat I think?
     
  5. whitedogapp

    whitedogapp Avid Boxer

    Joined:
    Oct 8, 2015
    Messages:
    295
    Likes Received:
    72
    can u share us how u made folow??
     

Share This Page