- Home /
chick what direction a cube is moving in then face it
any one know how to do this
Comment
Best Answer
Answer by Berenger · Feb 21, 2012 at 06:23 AM
With rigidbody
transform.rotation = Quaternion.LookRotation( rigidbody.velocity );
Without
transform.rotation = Quaternion.LookRotation( transform.position - lastPos );
lastPos = transform.position;
Your answer
Follow this Question
Related Questions
Can't get platform to move to the other direction 2 Answers
C# How to get a direction of a moving object? 1 Answer
Entity moving along the wrong axis 0 Answers
Cant get moving platform to go the other direction 1 Answer
Moving Randomly 1 Answer