From 292b123a3dc795b4340cf6a51e5df4f912755cf9 Mon Sep 17 00:00:00 2001 From: LmeSzinc <37934724+LmeSzinc@users.noreply.github.com> Date: Wed, 11 Sep 2024 00:19:11 +0800 Subject: [PATCH] Fix: Early access dungeon exited at COMBAT_PREPARE --- tasks/combat/combat.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tasks/combat/combat.py b/tasks/combat/combat.py index 55728654f..ad8e9d611 100644 --- a/tasks/combat/combat.py +++ b/tasks/combat/combat.py @@ -324,6 +324,9 @@ class Combat(CombatInteract, CombatPrepare, CombatState, CombatTeam, CombatSuppo if self.is_in_main(): logger.info('Combat finishes at page_main') return True + if self.appear(COMBAT_PREPARE): + logger.info('Combat finishes at COMBAT_PREPARE') + return True if self.is_combat_executing(): logger.info('Combat finishes at another combat') return False @@ -427,6 +430,7 @@ class Combat(CombatInteract, CombatPrepare, CombatState, CombatTeam, CombatSuppo if self._combat_should_reenter(): continue if finish: + self.combat_exit() break # Reset combat_wave_cost, so handle_combat_interact() won't activate before handle_combat_prepare() self.combat_wave_cost = 10