-2
\$\begingroup\$

I tried this and it's rotating facing to the target but also on the x and i want it to rotate only on the y :

transform.rotation = Quaternion.RotateTowards(transform.rotation,
    Quaternion.LookRotation(camfreelook.transform.position - transform.position),
    rotationSpeed * Time.deltaTime);
\$\endgroup\$
1

0

You must log in to answer this question.

Browse other questions tagged .