Esempio n. 1
0
        // start the swivel
        private void StartSwivel(Vector3 dir)
        {
            LocomotionComponentAPP loco = player.GetComponent <LocomotionComponentAPP>();

            if (null != loco)
            {
                loco.LookAtPosition(player.transform.position + dir, true);
            }
        }
Esempio n. 2
0
 static public void OrientFacing(GameObject orient, GameObject lookAt)
 {
     if (null != orient && null != lookAt)
     {
         LocomotionComponentAPP loco = orient.GetComponent <LocomotionComponentAPP>();
         if (null != loco)
         {
             loco.LookAtPosition(lookAt.transform.position, true);
             Interaction activeInteraction = Dialogue.GetActiveInteraction();
             if (null != activeInteraction)
             {
                 activeInteraction.LockCharacterRotation(loco);
             }
         }
     }
 }