mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-03-12 03:58:22 +08:00
Fix: 修复一些稀有bug
This commit is contained in:
@@ -5,14 +5,11 @@ from module.handler.assets import *
|
|||||||
|
|
||||||
class InfoBarHandler(ModuleBase):
|
class InfoBarHandler(ModuleBase):
|
||||||
def info_bar_count(self):
|
def info_bar_count(self):
|
||||||
if self.appear(INFO_BAR_1):
|
if self.appear(INFO_BAR_3):
|
||||||
# if self.appear(INFO_BAR_2):
|
return 3
|
||||||
# if self.appear(INFO_BAR_3):
|
elif self.appear(INFO_BAR_2):
|
||||||
# return 3
|
return 2
|
||||||
# else:
|
elif self.appear(INFO_BAR_1):
|
||||||
# return 2
|
|
||||||
# else:
|
|
||||||
# return 1
|
|
||||||
return 1
|
return 1
|
||||||
else:
|
else:
|
||||||
return 0
|
return 0
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
from module.logger import logger
|
from module.logger import logger
|
||||||
from module.map.exception import CampaignEnd
|
|
||||||
from module.map.fleet import Fleet
|
from module.map.fleet import Fleet
|
||||||
from module.map.grid_info import GridInfo
|
from module.map.grid_info import GridInfo
|
||||||
from module.map.map_grids import SelectedGrids, RoadGrids
|
from module.map.map_grids import SelectedGrids, RoadGrids
|
||||||
@@ -240,7 +239,6 @@ class Map(Fleet):
|
|||||||
grids = grids.sort(cost=True, weight=True)
|
grids = grids.sort(cost=True, weight=True)
|
||||||
logger.info('Grids: %s' % str(grids))
|
logger.info('Grids: %s' % str(grids))
|
||||||
self.clear_chosen_enemy(grids[0], expected='boss')
|
self.clear_chosen_enemy(grids[0], expected='boss')
|
||||||
raise CampaignEnd('BOSS Clear.')
|
|
||||||
|
|
||||||
logger.warning('BOSS not detected, trying all boss spawn point.')
|
logger.warning('BOSS not detected, trying all boss spawn point.')
|
||||||
self.clear_potential_boss()
|
self.clear_potential_boss()
|
||||||
@@ -253,17 +251,13 @@ class Map(Fleet):
|
|||||||
"""
|
"""
|
||||||
grids = self.map.select(may_boss=True, is_accessible=True)
|
grids = self.map.select(may_boss=True, is_accessible=True)
|
||||||
logger.info('May boss: %s' % self.map.select(may_boss=True))
|
logger.info('May boss: %s' % self.map.select(may_boss=True))
|
||||||
battle_count = self.battle_count
|
|
||||||
|
|
||||||
for grid in grids:
|
for grid in grids:
|
||||||
logger.hr('Clear BOSS')
|
logger.hr('Clear BOSS')
|
||||||
grids = grids.sort(cost=True, weight=True)
|
grids = grids.sort(cost=True, weight=True)
|
||||||
logger.info('Grid: %s' % str(grid))
|
logger.info('Grid: %s' % str(grid))
|
||||||
self.clear_chosen_enemy(grid, expected='boss')
|
self.clear_chosen_enemy(grid, expected='boss')
|
||||||
if self.battle_count - battle_count > 0:
|
logger.info('Boss guessing incorrect.')
|
||||||
raise CampaignEnd('BOSS Clear.')
|
|
||||||
else:
|
|
||||||
logger.info('Boss guessing incorrect.')
|
|
||||||
|
|
||||||
def clear_siren(self, **kwargs):
|
def clear_siren(self, **kwargs):
|
||||||
"""
|
"""
|
||||||
|
|||||||
Reference in New Issue
Block a user