public IEnumerator desactive() { CharacterAnimations component = enemyAnimation.GetComponent <CharacterAnimations>(); yield return(new WaitForSeconds(1f)); component.Damage(false); }
void defend() { CharacterAnimations component = enemyAnimation.GetComponent <CharacterAnimations>(); playerAnimation.Defend(true); shield.ActivateShield(true); component.Damage(true); StartCoroutine(desactive()); }