// Start is called before the first frame update void Start() { player = GameObject.FindGameObjectWithTag("Player"); detection = GetComponentInChildren <AIDetection>(); gameObject.tag = "Generated"; audioSource = GetComponent <AudioSource>(); playerInRange = false; hitParticles = GetComponent <ParticleSystem>(); targetSet = false; caughtPlayer = false; }
void Start() { animator = GetComponent <Animator>(); detection = GetComponentInChildren <AIDetection>(); }