void Start() { status = Status.STAY; audioSource = GetComponent <AudioSource>(); animator = GetComponent <Animator>(); selectionScript = transform .parent .gameObject .GetComponent <selectionScript>(); attackTimer = attackRate; }
void Start() { life = maxLife; selectionScript = FindObjectOfType <selectionScript>(); audioSource = GetComponent <AudioSource>(); }