void Start()
    {
        target = GameObject.FindGameObjectWithTag("Player").transform;
        player = target.GetComponent <PoliceStarSystem>();
        agent  = GetComponent <NavMeshAgent>();

        if (player.isChasable)
        {
            isChasing = true;
        }
    }
Ejemplo n.º 2
0
 // Start is called before the first frame update
 void Start()
 {
     player = FindObjectOfType <PoliceStarSystem>();
     StartCoroutine(SpawnPolice());
 }