Advertisement
Guest User

Untitled

a guest
Nov 28th, 2014
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. using UnityEngine;
  2. using System.Collections;
  3.  
  4. public class NoCamRotation : MonoBehaviour
  5. {
  6. public Transform target;
  7. public float distance;
  8. //public Transform target;
  9. //public float speed;
  10.  
  11.  
  12. // Use this for initialization
  13. void Start ()
  14. {
  15.  
  16. }
  17.  
  18. // Update is called once per frame
  19. void Update ()
  20. {
  21. // transform.position = new Vector3(target.position.x, target.position.y, target.position.z - distance);
  22. transform.LookAt(target);
  23. }
  24. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement