// Use this for initialization void Start() { health = GetComponent <Health>(); ai = GetComponent <AttackPlayerAI>(); roamAi = GetComponent <RoamAI>(); takeDmg = GetComponent <TakeDamage>(); anim = GetComponent <Animator>(); }
// Use this for initialization void Start() { spawner = GetComponentInParent <SpawnerIdle>(); behaviorIdle = StartCoroutine(move()); nodes = GameObject.FindGameObjectsWithTag("Node"); if (GetComponent <AttackPlayerAI>() != null) { aiAttack = GetComponent <AttackPlayerAI>(); aiAttack.enabled = false; } StartCoroutine(move()); }