mirror of
https://gitee.com/sui-feng-cb/AzurLaneAutoScript1
synced 2026-04-15 14:42:26 +08:00
Fix: Oil limit too low
This commit is contained in:
@@ -81,8 +81,8 @@ class CampaignRun(CampaignEvent):
|
|||||||
self.config.Scheduler_Enable = False
|
self.config.Scheduler_Enable = False
|
||||||
return True
|
return True
|
||||||
# Oil limit
|
# Oil limit
|
||||||
if oil_check and self.config.StopCondition_OilLimit:
|
if oil_check:
|
||||||
if self.get_oil() < self.config.StopCondition_OilLimit:
|
if self.get_oil() < max(500, self.config.StopCondition_OilLimit):
|
||||||
logger.hr('Triggered stop condition: Oil limit')
|
logger.hr('Triggered stop condition: Oil limit')
|
||||||
self.config.task_delay(minute=(120, 240))
|
self.config.task_delay(minute=(120, 240))
|
||||||
return True
|
return True
|
||||||
|
|||||||
@@ -101,7 +101,7 @@ class AutoSearchCombat(MapOperation, Combat, CampaignStatus):
|
|||||||
if oil == 0:
|
if oil == 0:
|
||||||
logger.warning('Oil not found')
|
logger.warning('Oil not found')
|
||||||
else:
|
else:
|
||||||
if oil < self.config.StopCondition_OilLimit:
|
if oil < max(500, self.config.StopCondition_OilLimit):
|
||||||
logger.info('Reach oil limit')
|
logger.info('Reach oil limit')
|
||||||
self.auto_search_oil_limit_triggered = True
|
self.auto_search_oil_limit_triggered = True
|
||||||
else:
|
else:
|
||||||
|
|||||||
@@ -137,8 +137,7 @@ class Raid(MapOperation, Combat, CampaignEvent):
|
|||||||
|
|
||||||
@run_once
|
@run_once
|
||||||
def check_oil():
|
def check_oil():
|
||||||
if self.config.StopCondition_OilLimit:
|
if self.get_oil() < max(500, self.config.StopCondition_OilLimit):
|
||||||
if self.get_oil() < self.config.StopCondition_OilLimit:
|
|
||||||
logger.hr('Triggered oil limit')
|
logger.hr('Triggered oil limit')
|
||||||
raise OilExhausted
|
raise OilExhausted
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user