public override void Enter(EnemyAgent agent) { agent.GetRigidbody().velocity = Vector3.zero; agent.GetNavMeshAgent().isStopped = true; agent.SetAnimation(true); agent.ResetAttack(); //start attack animation agent.Attack(); }