// Start is called before the first frame update void Awake() { playerAnimation = GetComponent <CharacterAnimations>(); shield = GetComponent <PlayerShield>(); soundFX = GetComponentInChildren <CharacterSoundFX>(); }
// Start is called before the first frame update void Awake() { EnemyAnimations = GetComponent <CharacterAnimations>(); navagent = GetComponent <NavMeshAgent>(); Playertarget = GameObject.FindGameObjectWithTag("Player").transform; soundFX = GetComponentInChildren <CharacterSoundFX>(); }
void Awake() { enemy_Anim = GetComponent <CharacterAnimations>(); navAgent = GetComponent <NavMeshAgent>(); playerTarget = GameObject.FindGameObjectWithTag(Tags.PLAYER_TAG).transform; soundFX = GetComponentInChildren <CharacterSoundFX>(); }
// Start is called before the first frame update void Awake() { soundFX = GetComponentInChildren <CharacterSoundFX>(); }
void Awake() { soundFX = GetComponentInChildren <CharacterSoundFX>(); // because player sound is a child of warior and Enemy }
void Start() { enemyState = EnemyState.CHASE; attackTimer = waitBeforeAttackTime; soundFX = GetComponentInChildren <CharacterSoundFX>(); }
void Awake() { soundFX = GetComponentInChildren <CharacterSoundFX>(); playerAnimation = GetComponent <CharacterAnimations>(); }
// Start is called before the first frame update void Start() { controller = GetComponent <CharacterController>(); anim = GetComponent <Animator>(); soundFX = GetComponentInChildren <CharacterSoundFX>(); }
// Start is called before the first frame update private void Awake() { soundFX = GetComponentInChildren <CharacterSoundFX>(); totalHealth = health; }
private void Awake() { soundFx = GetComponentInChildren <CharacterSoundFX>(); // in children because it's attached to player child }