// Use this for initialization void Start() { b = GetComponent <Boid>(); EagleSpawner es = FindObjectOfType <EagleSpawner>(); leader = es.fleet[0]; }
// Update is called once per frame void Update() { es = FindObjectOfType <EagleSpawner>(); //if there is a leader then look at him if (es.fleet.Count > 0) { position = es.fleet[0].transform.position; this.transform.LookAt(position); } }