void Start()
 {
     player      = FindObjectOfType <FirstPersonControls>().gameObject;
     pat         = gameObject.GetComponent <EnemyPatrolScript>();
     ani         = gameObject.GetComponent <Animator>();
     destination = pat.getFirst();
 }
Esempio n. 2
0
 // Use this for initialization
 void Start()
 {
     currentHealth = maxHealth;
     anim          = GetComponent <Animator> ();
     rb2d          = GetComponent <Rigidbody2D> ();
     enemy         = GetComponent <EnemyPatrolScript> ();
 }