Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- float x = Input.mousePosition.x;
- float y = Input.mousePosition.y;
- const float ZDepth = 5.0f;
- Vector3 targetPosition = Camera.main.ScreenToWorldPoint(new Vector3(x, y, ZDepth));
- leftEyeTransform.LookAt(targetPosition);
- rightEyeTransform.LookAt(targetPosition);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement