- Home /
Question by
DJGhostViper · Nov 24, 2016 at 01:06 AM ·
quaternionlerplookattime.deltatime
How to use LookAt() to make a gameobject look at another gameobject slowly?
Im trying to get an object to slowly look at another gameobject how could I possibly use this with time.deltatime? I've tried Quaternion.Lerp too and its not working what an I doing wrong?
this.gameObject.transform.LookAt (RM.Priority1Plastic [0].transform.FindChild ("LookAt1"));
//this.gameObject.transform.rotation = Quaternion.Lerp (this.gameObject.transform.rotation, Quaternion.LookRotation (RM.Priority1Plastic [0].transform.FindChild ("LookAt1").position), Time.deltaTime);
yield return new WaitForSeconds (1);
CollectorGun.LookAt (RM.Priority1Plastic [0].transform.FindChild ("LookAt1"));
Comment
Have you looked at the documentation for $$anonymous$$athf.$$anonymous$$oveTowardsAngle ? I think that might help you