mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-05-13 22:42:35 +08:00
Merge pull request #300 from nEEtdo0d/guild_reward
Fix: Guild reward and handle error case in ocr check
This commit is contained in:
@@ -166,6 +166,10 @@ class CampaignOcr(ModuleBase):
|
|||||||
result = [self._campaign_ocr_result_process(res) for res in result]
|
result = [self._campaign_ocr_result_process(res) for res in result]
|
||||||
|
|
||||||
chapter = [self._campaign_separate_name(res)[0] for res in result]
|
chapter = [self._campaign_separate_name(res)[0] for res in result]
|
||||||
|
chapter = list(filter(('').__ne__, chapter))
|
||||||
|
if not chapter:
|
||||||
|
raise CampaignNameError
|
||||||
|
|
||||||
counter = collections.Counter(chapter)
|
counter = collections.Counter(chapter)
|
||||||
self.campaign_chapter = counter.most_common()[0][0]
|
self.campaign_chapter = counter.most_common()[0][0]
|
||||||
|
|
||||||
|
|||||||
@@ -9,7 +9,7 @@ from module.logger import logger
|
|||||||
from module.template.assets import TEMPLATE_OPERATIONS_RED_DOT, TEMPLATE_OPERATIONS_ADD
|
from module.template.assets import TEMPLATE_OPERATIONS_RED_DOT, TEMPLATE_OPERATIONS_ADD
|
||||||
|
|
||||||
RECORD_OPTION_DISPATCH = ('RewardRecord', 'operations_dispatch')
|
RECORD_OPTION_DISPATCH = ('RewardRecord', 'operations_dispatch')
|
||||||
RECORD_SINCE_DISPATCH = (0, 6, 12, 18,)
|
RECORD_SINCE_DISPATCH = (6, 12, 18, 21,)
|
||||||
RECORD_OPTION_BOSS = ('RewardRecord', 'operations_boss')
|
RECORD_OPTION_BOSS = ('RewardRecord', 'operations_boss')
|
||||||
RECORD_SINCE_BOSS = (0,)
|
RECORD_SINCE_BOSS = (0,)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user