diff --git a/alas.py b/alas.py index 72391422a..e58cefe2b 100644 --- a/alas.py +++ b/alas.py @@ -1,3 +1,4 @@ +import json import os import re import threading @@ -17,6 +18,25 @@ from module.gg_handler.gg_handler import GGHandler from module.luahook.crack import disable_all_crack,luahook_crack_all, CrackResource import gl +from module.device.assets import OTHERS_LOGIN_CONFIRM +import gl + +g_current_task: str = "" +TASK_FOR_KEEP_OIL_ = [ + 'ResearchFarm', + 'ResearchFarm2', + 'ResearchFarm3', + 'ResearchFarm4', + 'ResearchFarm5', + 'ResearchFarm6', + 'Main', + 'Main2', + 'Main3', + 'Main4', + 'Main5', + 'Main6', + 'GemsFarming', +] class AzurLaneAutoScript: stop_event: threading.Event = None @@ -80,6 +100,20 @@ class AzurLaneAutoScript: logger.exception(e) exit(1) + def DelayAllTask(self): + Current = datetime.now() + TimeDelta = timedelta(minutes=self.config.OthersLogin_Interval, seconds=-1) + + self.config.task_delay(target=Current + TimeDelta, task=self.config.task.command) + + for i in self.config.pending_task: + self.config.task_delay(target=Current + TimeDelta, task=i.command) + + for i in self.config.waiting_task: + if i.next_run < Current + TimeDelta: + self.config.task_delay(target=Current + TimeDelta, task=i.command) + + def run(self, command, skip_first_screenshot=False): self.AutoRestart_Enabled = deep_get(self.config.data, "Restart.AutoRestart.Enabled") self.AutoRestart_NotifyWhenAutoRestart = deep_get(self.config.data, "Restart.AutoRestart.NotifyWhenAutoRestart") @@ -91,6 +125,22 @@ class AzurLaneAutoScript: if command != "restart" and self.GameRestartBecauseErrorTimes != 0: self.GameRestartBecauseErrorTimes = 0 return True + except OthersLogin: + logger.warning("Detected others' login") + self.DelayAllTask() + Method = deep_get(self.config.data, "OthersLogin.OthersLogin.Method") + self.config.Optimization_WhenTaskQueueEmpty = Method + if Method == "stay_there": + self.device.click(OTHERS_LOGIN_CONFIRM) + if deep_get(self.config.data, "OthersLogin.OthersLogin.Notify", True): + handle_notify( + self.config.Error_OnePushConfig, + title=f"Alas <{self.config_name}>: account's owner logs in", + content=f"Delay some tasks to {datetime.now() + timedelta(minutes=self.config.OthersLogin_Interval, seconds=-1)}", + ) + self.config.save() + self.config.update() + return True except RequireRestartGame: self.config.task_call('Restart') self.device.sleep(10) @@ -204,10 +254,12 @@ class AzurLaneAutoScript: """ Save last 60 screenshots in ./log/error/ Save logs to ./log/error//log.txt + Save current setting to ./log/error//config.json """ from module.base.utils import save_image from module.handler.sensitive_info import (handle_sensitive_image, handle_sensitive_logs) + folder = f'./log/error/{int(time.time() * 1000)}' if self.config.Error_SaveError: if not os.path.exists('./log/error'): os.mkdir('./log/error') @@ -230,6 +282,10 @@ class AzurLaneAutoScript: with open(f'{folder}/log.txt', 'w', encoding='utf-8') as f: f.writelines(lines) + if self.config.Error_SaveConfig: + logger.warning(f'Saving config') + write_file(f'{folder}/config.json', self.config.data) + def restart(self): from module.handler.login import LoginHandler LoginHandler(self.config, device=self.device).app_restart() @@ -463,6 +519,21 @@ class AzurLaneAutoScript: CampaignRun(config=self.config, device=self.device).run( name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + def main4(self): + from module.campaign.run import CampaignRun + CampaignRun(config=self.config, device=self.device).run( + name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + + def main5(self): + from module.campaign.run import CampaignRun + CampaignRun(config=self.config, device=self.device).run( + name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + + def main6(self): + from module.campaign.run import CampaignRun + CampaignRun(config=self.config, device=self.device).run( + name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + def event(self): from module.campaign.run import CampaignRun CampaignRun(config=self.config, device=self.device).run( @@ -478,6 +549,21 @@ class AzurLaneAutoScript: CampaignRun(config=self.config, device=self.device).run( name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + def event4(self): + from module.campaign.run import CampaignRun + CampaignRun(config=self.config, device=self.device).run( + name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + + def event5(self): + from module.campaign.run import CampaignRun + CampaignRun(config=self.config, device=self.device).run( + name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + + def event6(self): + from module.campaign.run import CampaignRun + CampaignRun(config=self.config, device=self.device).run( + name=self.config.Campaign_Name, folder=self.config.Campaign_Event, mode=self.config.Campaign_Mode) + @disable_all_crack def raid(self): from module.raid.run import RaidRun @@ -634,6 +720,28 @@ class AzurLaneAutoScript: logger.critical("友情翻译:你他妈的GG包名填错了,滚去重填!!!") exit(1) + def check_task_for_keep_oil(self): + keep_oil_time = deep_get(self.config.data, "EventGeneral.KeepOil.TimeLimit", datetime(2020, 1, 1, 0, 0)) + if keep_oil_time != datetime(2020, 1, 1, 0, 0) and datetime.now() >= keep_oil_time: + logger.info("Keep oil time limit reached") + for i in TASK_FOR_KEEP_OIL_: + logger.info(f"Disable {i}") + self.config.modified[f"{i}.Scheduler.Enable"] = False + logger.info("Reset keep oil time limit") + self.config.modified["EventGeneral.KeepOil.TimeLimit"] = datetime(2020, 1, 1, 0, 0) + + def check_outdate(self): + time_limit_setting = deep_get(self.config.data, "Remark.OutDate.TimeLimit", datetime(2020, 1, 1, 0, 0)) + if time_limit_setting != datetime(2020, 1, 1, 0, 0) and datetime.now() >= time_limit_setting: + logger.critical(f"This instance is outdated, exit !") + handle_notify( + self.config.Error_OnePushConfig, + title=f"Alas <{self.config_name}>: outdated", + content=f"This instance is outdated !", + ) + self.config.modified[f"Remark.OutDate.TimeLimit"] = datetime(2020, 1, 1, 0, 0) + self.config.save() + exit(0) def loop(self): if self.is_azur: CrackResource(self.config, self.device).ensure() @@ -665,6 +773,11 @@ class AzurLaneAutoScript: del_cached_property(self, 'config') logger.info('Server or network is recovered. Restart game client') self.config.task_call('Restart') + + self.check_task_for_keep_oil() + + self.check_outdate() + # Get task task = self.get_next_task() # Init device and change server diff --git a/assets/cn/device/OTHERS_LOGIN_CONFIRM.png b/assets/cn/device/OTHERS_LOGIN_CONFIRM.png new file mode 100644 index 000000000..2c3c3eff6 Binary files /dev/null and b/assets/cn/device/OTHERS_LOGIN_CONFIRM.png differ diff --git a/assets/cn/device/OTHERS_LOGIN_NOTIFY.png b/assets/cn/device/OTHERS_LOGIN_NOTIFY.png new file mode 100644 index 000000000..2917e859f Binary files /dev/null and b/assets/cn/device/OTHERS_LOGIN_NOTIFY.png differ diff --git a/assets/gui/icon/stop.svg b/assets/gui/icon/stop.svg new file mode 100644 index 000000000..d4cb362e6 --- /dev/null +++ b/assets/gui/icon/stop.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/assets/jp/device/OTHERS_LOGIN_NOTIFY.png b/assets/jp/device/OTHERS_LOGIN_NOTIFY.png new file mode 100644 index 000000000..f8b50995d Binary files /dev/null and b/assets/jp/device/OTHERS_LOGIN_NOTIFY.png differ diff --git a/config/template.json b/config/template.json index 19e9bf2f1..d451e3469 100644 --- a/config/template.json +++ b/config/template.json @@ -17,6 +17,7 @@ "Error": { "HandleError": true, "SaveError": true, + "SaveConfig": true, "OnePushConfig": "provider: null", "ScreenshotLength": 1 }, @@ -89,6 +90,38 @@ "NotifyWhenAutoRestart": false, "HasRestarted": 0 }, + "ExitWhenMaintenance": { + "Enable": false, + "Notify": true + }, + "Storage": { + "Storage": {} + } + }, + "OthersLogin": { + "OthersLogin": { + "Enable": false, + "Method": "stay_there", + "Interval": 60, + "Notify": true + }, + "Storage": { + "Storage": {} + } + }, + "Remark": { + "Boss": { + "Name": null, + "Account": null, + "Password": null, + "SecondPassword": null + }, + "OutDate": { + "TimeLimit": "2020-01-01 00:00:00" + }, + "Comment": { + "Content": null + }, "Storage": { "Storage": {} } @@ -167,6 +200,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -241,6 +275,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -315,6 +350,232 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", + "StageIncrease": false, + "GetNewShip": false, + "ReachLevel": 0 + }, + "Fleet": { + "Fleet1": 1, + "Fleet1Formation": "double_line", + "Fleet1Mode": "combat_auto", + "Fleet1Step": 3, + "Fleet2": 2, + "Fleet2Formation": "double_line", + "Fleet2Mode": "combat_auto", + "Fleet2Step": 2, + "FleetOrder": "fleet1_mob_fleet2_boss" + }, + "Submarine": { + "Fleet": 0, + "Mode": "do_not_use", + "AutoSearchMode": "sub_standby", + "DistanceToBoss": "2_grid_to_boss" + }, + "Emotion": { + "Mode": "calculate", + "Fleet1Value": 119, + "Fleet1Record": "2020-01-01 00:00:00", + "Fleet1Control": "prevent_yellow_face", + "Fleet1Recover": "not_in_dormitory", + "Fleet1Oath": false, + "Fleet2Value": 119, + "Fleet2Record": "2020-01-01 00:00:00", + "Fleet2Control": "prevent_yellow_face", + "Fleet2Recover": "not_in_dormitory", + "Fleet2Oath": false + }, + "HpControl": { + "UseHpBalance": false, + "UseEmergencyRepair": false, + "UseLowHpRetreat": false, + "HpBalanceThreshold": 0.2, + "HpBalanceWeight": "1000, 1000, 1000", + "RepairUseSingleThreshold": 0.3, + "RepairUseMultiThreshold": 0.6, + "LowHpRetreatThreshold": 0.3 + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": "default_mode" + }, + "Storage": { + "Storage": {} + } + }, + "Main4": { + "Scheduler": { + "Enable": false, + "NextRun": "2020-01-01 00:00:00", + "Command": "Main4", + "SuccessInterval": 0, + "FailureInterval": 120, + "ServerUpdate": "00:00" + }, + "Campaign": { + "Name": "12-4", + "Event": "campaign_main", + "Mode": "normal", + "UseClearMode": true, + "UseFleetLock": true, + "UseAutoSearch": true, + "Use2xBook": false, + "AmbushEvade": true + }, + "StopCondition": { + "OilLimit": 1000, + "RunCount": 0, + "MapAchievement": "non_stop", + "StopBarrier": "1-1", + "StageIncrease": false, + "GetNewShip": false, + "ReachLevel": 0 + }, + "Fleet": { + "Fleet1": 1, + "Fleet1Formation": "double_line", + "Fleet1Mode": "combat_auto", + "Fleet1Step": 3, + "Fleet2": 2, + "Fleet2Formation": "double_line", + "Fleet2Mode": "combat_auto", + "Fleet2Step": 2, + "FleetOrder": "fleet1_mob_fleet2_boss" + }, + "Submarine": { + "Fleet": 0, + "Mode": "do_not_use", + "AutoSearchMode": "sub_standby", + "DistanceToBoss": "2_grid_to_boss" + }, + "Emotion": { + "Mode": "calculate", + "Fleet1Value": 119, + "Fleet1Record": "2020-01-01 00:00:00", + "Fleet1Control": "prevent_yellow_face", + "Fleet1Recover": "not_in_dormitory", + "Fleet1Oath": false, + "Fleet2Value": 119, + "Fleet2Record": "2020-01-01 00:00:00", + "Fleet2Control": "prevent_yellow_face", + "Fleet2Recover": "not_in_dormitory", + "Fleet2Oath": false + }, + "HpControl": { + "UseHpBalance": false, + "UseEmergencyRepair": false, + "UseLowHpRetreat": false, + "HpBalanceThreshold": 0.2, + "HpBalanceWeight": "1000, 1000, 1000", + "RepairUseSingleThreshold": 0.3, + "RepairUseMultiThreshold": 0.6, + "LowHpRetreatThreshold": 0.3 + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": "default_mode" + }, + "Storage": { + "Storage": {} + } + }, + "Main5": { + "Scheduler": { + "Enable": false, + "NextRun": "2020-01-01 00:00:00", + "Command": "Main5", + "SuccessInterval": 0, + "FailureInterval": 120, + "ServerUpdate": "00:00" + }, + "Campaign": { + "Name": "12-4", + "Event": "campaign_main", + "Mode": "normal", + "UseClearMode": true, + "UseFleetLock": true, + "UseAutoSearch": true, + "Use2xBook": false, + "AmbushEvade": true + }, + "StopCondition": { + "OilLimit": 1000, + "RunCount": 0, + "MapAchievement": "non_stop", + "StopBarrier": "1-1", + "StageIncrease": false, + "GetNewShip": false, + "ReachLevel": 0 + }, + "Fleet": { + "Fleet1": 1, + "Fleet1Formation": "double_line", + "Fleet1Mode": "combat_auto", + "Fleet1Step": 3, + "Fleet2": 2, + "Fleet2Formation": "double_line", + "Fleet2Mode": "combat_auto", + "Fleet2Step": 2, + "FleetOrder": "fleet1_mob_fleet2_boss" + }, + "Submarine": { + "Fleet": 0, + "Mode": "do_not_use", + "AutoSearchMode": "sub_standby", + "DistanceToBoss": "2_grid_to_boss" + }, + "Emotion": { + "Mode": "calculate", + "Fleet1Value": 119, + "Fleet1Record": "2020-01-01 00:00:00", + "Fleet1Control": "prevent_yellow_face", + "Fleet1Recover": "not_in_dormitory", + "Fleet1Oath": false, + "Fleet2Value": 119, + "Fleet2Record": "2020-01-01 00:00:00", + "Fleet2Control": "prevent_yellow_face", + "Fleet2Recover": "not_in_dormitory", + "Fleet2Oath": false + }, + "HpControl": { + "UseHpBalance": false, + "UseEmergencyRepair": false, + "UseLowHpRetreat": false, + "HpBalanceThreshold": 0.2, + "HpBalanceWeight": "1000, 1000, 1000", + "RepairUseSingleThreshold": 0.3, + "RepairUseMultiThreshold": 0.6, + "LowHpRetreatThreshold": 0.3 + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": "default_mode" + }, + "Storage": { + "Storage": {} + } + }, + "Main6": { + "Scheduler": { + "Enable": false, + "NextRun": "2020-01-01 00:00:00", + "Command": "Main6", + "SuccessInterval": 0, + "FailureInterval": 120, + "ServerUpdate": "00:00" + }, + "Campaign": { + "Name": "12-4", + "Event": "campaign_main", + "Mode": "normal", + "UseClearMode": true, + "UseFleetLock": true, + "UseAutoSearch": true, + "Use2xBook": false, + "AmbushEvade": true + }, + "StopCondition": { + "OilLimit": 1000, + "RunCount": 0, + "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -412,6 +673,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -539,6 +801,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -613,6 +876,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -687,6 +951,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -761,6 +1026,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -835,6 +1101,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -909,6 +1176,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -997,6 +1265,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1071,6 +1340,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1145,6 +1415,232 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", + "StageIncrease": false, + "GetNewShip": false, + "ReachLevel": 0 + }, + "Fleet": { + "Fleet1": 1, + "Fleet1Formation": "double_line", + "Fleet1Mode": "combat_auto", + "Fleet1Step": 3, + "Fleet2": 2, + "Fleet2Formation": "double_line", + "Fleet2Mode": "combat_auto", + "Fleet2Step": 2, + "FleetOrder": "fleet1_mob_fleet2_boss" + }, + "Submarine": { + "Fleet": 0, + "Mode": "do_not_use", + "AutoSearchMode": "sub_standby", + "DistanceToBoss": "2_grid_to_boss" + }, + "Emotion": { + "Mode": "calculate", + "Fleet1Value": 119, + "Fleet1Record": "2020-01-01 00:00:00", + "Fleet1Control": "prevent_yellow_face", + "Fleet1Recover": "not_in_dormitory", + "Fleet1Oath": false, + "Fleet2Value": 119, + "Fleet2Record": "2020-01-01 00:00:00", + "Fleet2Control": "prevent_yellow_face", + "Fleet2Recover": "not_in_dormitory", + "Fleet2Oath": false + }, + "HpControl": { + "UseHpBalance": false, + "UseEmergencyRepair": false, + "UseLowHpRetreat": false, + "HpBalanceThreshold": 0.2, + "HpBalanceWeight": "1000, 1000, 1000", + "RepairUseSingleThreshold": 0.3, + "RepairUseMultiThreshold": 0.6, + "LowHpRetreatThreshold": 0.3 + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": "default_mode" + }, + "Storage": { + "Storage": {} + } + }, + "Event4": { + "Scheduler": { + "Enable": false, + "NextRun": "2020-01-01 00:00:00", + "Command": "Event4", + "SuccessInterval": 0, + "FailureInterval": 120, + "ServerUpdate": "00:00" + }, + "Campaign": { + "Name": "12-4", + "Event": "campaign_main", + "Mode": "normal", + "UseClearMode": true, + "UseFleetLock": true, + "UseAutoSearch": true, + "Use2xBook": false, + "AmbushEvade": true + }, + "StopCondition": { + "OilLimit": 1000, + "RunCount": 0, + "MapAchievement": "non_stop", + "StopBarrier": "1-1", + "StageIncrease": false, + "GetNewShip": false, + "ReachLevel": 0 + }, + "Fleet": { + "Fleet1": 1, + "Fleet1Formation": "double_line", + "Fleet1Mode": "combat_auto", + "Fleet1Step": 3, + "Fleet2": 2, + "Fleet2Formation": "double_line", + "Fleet2Mode": "combat_auto", + "Fleet2Step": 2, + "FleetOrder": "fleet1_mob_fleet2_boss" + }, + "Submarine": { + "Fleet": 0, + "Mode": "do_not_use", + "AutoSearchMode": "sub_standby", + "DistanceToBoss": "2_grid_to_boss" + }, + "Emotion": { + "Mode": "calculate", + "Fleet1Value": 119, + "Fleet1Record": "2020-01-01 00:00:00", + "Fleet1Control": "prevent_yellow_face", + "Fleet1Recover": "not_in_dormitory", + "Fleet1Oath": false, + "Fleet2Value": 119, + "Fleet2Record": "2020-01-01 00:00:00", + "Fleet2Control": "prevent_yellow_face", + "Fleet2Recover": "not_in_dormitory", + "Fleet2Oath": false + }, + "HpControl": { + "UseHpBalance": false, + "UseEmergencyRepair": false, + "UseLowHpRetreat": false, + "HpBalanceThreshold": 0.2, + "HpBalanceWeight": "1000, 1000, 1000", + "RepairUseSingleThreshold": 0.3, + "RepairUseMultiThreshold": 0.6, + "LowHpRetreatThreshold": 0.3 + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": "default_mode" + }, + "Storage": { + "Storage": {} + } + }, + "Event5": { + "Scheduler": { + "Enable": false, + "NextRun": "2020-01-01 00:00:00", + "Command": "Event5", + "SuccessInterval": 0, + "FailureInterval": 120, + "ServerUpdate": "00:00" + }, + "Campaign": { + "Name": "12-4", + "Event": "campaign_main", + "Mode": "normal", + "UseClearMode": true, + "UseFleetLock": true, + "UseAutoSearch": true, + "Use2xBook": false, + "AmbushEvade": true + }, + "StopCondition": { + "OilLimit": 1000, + "RunCount": 0, + "MapAchievement": "non_stop", + "StopBarrier": "1-1", + "StageIncrease": false, + "GetNewShip": false, + "ReachLevel": 0 + }, + "Fleet": { + "Fleet1": 1, + "Fleet1Formation": "double_line", + "Fleet1Mode": "combat_auto", + "Fleet1Step": 3, + "Fleet2": 2, + "Fleet2Formation": "double_line", + "Fleet2Mode": "combat_auto", + "Fleet2Step": 2, + "FleetOrder": "fleet1_mob_fleet2_boss" + }, + "Submarine": { + "Fleet": 0, + "Mode": "do_not_use", + "AutoSearchMode": "sub_standby", + "DistanceToBoss": "2_grid_to_boss" + }, + "Emotion": { + "Mode": "calculate", + "Fleet1Value": 119, + "Fleet1Record": "2020-01-01 00:00:00", + "Fleet1Control": "prevent_yellow_face", + "Fleet1Recover": "not_in_dormitory", + "Fleet1Oath": false, + "Fleet2Value": 119, + "Fleet2Record": "2020-01-01 00:00:00", + "Fleet2Control": "prevent_yellow_face", + "Fleet2Recover": "not_in_dormitory", + "Fleet2Oath": false + }, + "HpControl": { + "UseHpBalance": false, + "UseEmergencyRepair": false, + "UseLowHpRetreat": false, + "HpBalanceThreshold": 0.2, + "HpBalanceWeight": "1000, 1000, 1000", + "RepairUseSingleThreshold": 0.3, + "RepairUseMultiThreshold": 0.6, + "LowHpRetreatThreshold": 0.3 + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": "default_mode" + }, + "Storage": { + "Storage": {} + } + }, + "Event6": { + "Scheduler": { + "Enable": false, + "NextRun": "2020-01-01 00:00:00", + "Command": "Event6", + "SuccessInterval": 0, + "FailureInterval": 120, + "ServerUpdate": "00:00" + }, + "Campaign": { + "Name": "12-4", + "Event": "campaign_main", + "Mode": "normal", + "UseClearMode": true, + "UseFleetLock": true, + "UseAutoSearch": true, + "Use2xBook": false, + "AmbushEvade": true + }, + "StopCondition": { + "OilLimit": 1000, + "RunCount": 0, + "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1223,44 +1719,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", - "StageIncrease": false, - "GetNewShip": false, - "ReachLevel": 0 - }, - "Emotion": { - "Mode": "calculate", - "Fleet1Value": 119, - "Fleet1Record": "2020-01-01 00:00:00", - "Fleet1Control": "prevent_yellow_face", - "Fleet1Recover": "not_in_dormitory", - "Fleet1Oath": false, - "Fleet2Value": 119, - "Fleet2Record": "2020-01-01 00:00:00", - "Fleet2Control": "prevent_yellow_face", - "Fleet2Recover": "not_in_dormitory", - "Fleet2Oath": false - }, - "Storage": { - "Storage": {} - } - }, - "Hospital": { - "Scheduler": { - "Enable": false, - "NextRun": "2020-01-01 00:00:00", - "Command": "Hospital", - "SuccessInterval": 0, - "FailureInterval": 120, - "ServerUpdate": "00:00" - }, - "Hospital": { - "UseRecommendFleet": true, - "mapName": "0-T1" - }, - "StopCondition": { - "OilLimit": 1000, - "RunCount": 0, - "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1309,6 +1768,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1369,6 +1829,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1447,6 +1908,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1525,6 +1987,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1603,6 +2066,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1681,6 +2145,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1755,6 +2220,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1832,6 +2298,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -1880,6 +2347,7 @@ "OilLimit": 1000, "RunCount": 0, "MapAchievement": "non_stop", + "StopBarrier": "1-1", "StageIncrease": false, "GetNewShip": false, "ReachLevel": 0 @@ -2182,6 +2650,7 @@ "ServerUpdate": "00:00" }, "GuildShop": { + "Enable": true, "Refresh": true, "Filter": "PlateT4 > BookT3 > PR > CatT3 > Chip > BookT2 > Retrofit > FoodT6 > FoodT5 > CatT2 > BoxT4", "BOX_T3": "ironblood", @@ -2198,6 +2667,7 @@ "PR3": "cheshire" }, "MedalShop2": { + "Enable": true, "Filter": "DR > PR\n> BookRedT3 > BookYellowT3 > BookBlueT3\n> BookRedT2 > BookYellowT2 > BookBlueT2\n> RetrofitT3\n> FoodT6 > FoodT5\n> PlateGeneralT3 > PlateWildT3", "RETROFIT_T1": "cl", "RETROFIT_T2": "cl", @@ -2207,10 +2677,12 @@ "PLATE_T3": "general" }, "MeritShop": { + "Enable": true, "Refresh": false, "Filter": "Cube" }, "CoreShop": { + "Enable": true, "Filter": "Array" }, "EventShop": { @@ -2696,90 +3168,5 @@ "Storage": { "Storage": {} } - }, - "Dashboard": { - "Oil": { - "Value": 0, - "Limit": 0, - "Color": "^000000", - "Record": "2020-01-01 00:00:00" - }, - "Coin": { - "Value": 0, - "Limit": 0, - "Color": "^FFAA33", - "Record": "2020-01-01 00:00:00" - }, - "Gem": { - "Value": 0, - "Color": "^FF3333", - "Record": "2020-01-01 00:00:00" - }, - "Pt": { - "Value": 0, - "Color": "^00BFFF", - "Record": "2020-01-01 00:00:00" - }, - "Cube": { - "Value": 0, - "Color": "^33FFFF", - "Record": "2020-01-01 00:00:00" - }, - "ActionPoint": { - "Value": 0, - "Total": 0, - "Color": "^0000FF", - "Record": "2020-01-01 00:00:00" - }, - "YellowCoin": { - "Value": 0, - "Color": "^FF8800", - "Record": "2020-01-01 00:00:00" - }, - "PurpleCoin": { - "Value": 0, - "Color": "^7700BB", - "Record": "2020-01-01 00:00:00" - }, - "Core": { - "Value": 0, - "Color": "^AAAAAA", - "Record": "2020-01-01 00:00:00" - }, - "Medal": { - "Value": 0, - "Color": "^FFDD00", - "Record": "2020-01-01 00:00:00" - }, - "Merit": { - "Value": 0, - "Color": "^FFFF00", - "Record": "2020-01-01 00:00:00" - }, - "GuildCoin": { - "Value": 0, - "Color": "^AAAAAA", - "Record": "2020-01-01 00:00:00" - }, - "ResearchPercent": { - "Value": 0, - "Limit": 100, - "Color": "^00AA00", - "Record": "2020-01-01 00:00:00" - }, - "PlayerLevel": { - "Value": 0, - "Color": "^FFAA33", - "Record": "2020-01-01 00:00:00" - }, - "PlayerExp": { - "Value": 0, - "Limit": 0, - "Color": "^FFAA33", - "Record": "2020-01-01 00:00:00" - }, - "Storage": { - "Storage": {} - } } } \ No newline at end of file diff --git a/module/auto_login/main.py b/module/auto_login/main.py new file mode 100644 index 000000000..832a1a2ac --- /dev/null +++ b/module/auto_login/main.py @@ -0,0 +1,6 @@ +from module.handler.login import LoginHandler + + +class AutoLogin(LoginHandler): + def run(self): + self.app_restart(is_switch_account=True) diff --git a/module/campaign/run.py b/module/campaign/run.py index 817882784..2de6e0ea3 100644 --- a/module/campaign/run.py +++ b/module/campaign/run.py @@ -16,6 +16,21 @@ from module.ui.page import page_campaign from module.config.deep import deep_get, deep_set from datetime import datetime, timedelta +TASK_FOR_KEEP_OIL = [ + 'ResearchFarm', + 'ResearchFarm2', + 'ResearchFarm3', + 'ResearchFarm4', + 'ResearchFarm5', + 'ResearchFarm6', + 'Main', + 'Main2', + 'Main3', + 'Main4', + 'Main5', + 'Main6', +] + class CampaignRun(CampaignEvent, ShopStatus): folder: str name: str @@ -336,6 +351,16 @@ class CampaignRun(CampaignEvent, ShopStatus): self.config.task_call('Commission', force_call=True) self.config.task_stop('Commission notice found') + def exit_for_keep_oil(self) -> bool: + if self.config.task.command in TASK_FOR_KEEP_OIL: + keep_oil_time = deep_get(self.config.data, "EventGeneral.KeepOil.TimeLimit") + if keep_oil_time == datetime(2020, 1, 1, 0, 0): + return False + else: + if datetime.now() > keep_oil_time: + return True + return False + def run(self, name, folder='campaign_main', mode='normal', total=0): """ Args: @@ -350,6 +375,12 @@ class CampaignRun(CampaignEvent, ShopStatus): self.run_count = 0 self.run_limit = self.config.StopCondition_RunCount while 1: + if self.exit_for_keep_oil(): + logger.info(f"Keep oil time limit reached, stop and disable this task") + self.campaign.ensure_auto_search_exit() + self.config.modified[f"{self.config.task.command}.Scheduler.Enable"] = False + self.config.task_stop() + # End if total and self.run_count >= total: break diff --git a/module/config/argument/args.json b/module/config/argument/args.json index 062fb8e5e..6dac146d7 100644 --- a/module/config/argument/args.json +++ b/module/config/argument/args.json @@ -181,6 +181,10 @@ "type": "checkbox", "value": true }, + "SaveConfig": { + "type": "checkbox", + "value": true + }, "OnePushConfig": { "type": "textarea", "value": "provider: null", @@ -467,6 +471,89 @@ "display": "hide" } }, + "ExitWhenMaintenance": { + "Enable": { + "type": "checkbox", + "value": false + }, + "Notify": { + "type": "checkbox", + "value": true + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "OthersLogin": { + "OthersLogin": { + "Enable": { + "type": "checkbox", + "value": false + }, + "Method": { + "type": "select", + "value": "stay_there", + "option": [ + "stay_there", + "close_game" + ] + }, + "Interval": { + "type": "input", + "value": 60 + }, + "Notify": { + "type": "checkbox", + "value": true + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Remark": { + "Boss": { + "Name": { + "type": "input", + "value": "" + }, + "Account": { + "type": "input", + "value": "" + }, + "Password": { + "type": "input", + "value": "" + }, + "SecondPassword": { + "type": "input", + "value": "" + } + }, + "OutDate": { + "TimeLimit": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + } + }, + "Comment": { + "Content": { + "type": "textarea", + "value": "" + } + }, "Storage": { "Storage": { "type": "storage", @@ -767,6 +854,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -1144,6 +1235,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -1521,6 +1616,1150 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, + "StageIncrease": { + "type": "checkbox", + "value": false + }, + "GetNewShip": { + "type": "checkbox", + "value": false + }, + "ReachLevel": { + "type": "input", + "value": 0 + } + }, + "Fleet": { + "Fleet1": { + "type": "select", + "value": 1, + "option": [ + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet1Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet1Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet1Step": { + "type": "select", + "value": 3, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "Fleet2": { + "type": "select", + "value": 2, + "option": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet2Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet2Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet2Step": { + "type": "select", + "value": 2, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "FleetOrder": { + "type": "select", + "value": "fleet1_mob_fleet2_boss", + "option": [ + "fleet1_mob_fleet2_boss", + "fleet1_boss_fleet2_mob", + "fleet1_all_fleet2_standby", + "fleet1_standby_fleet2_all" + ] + } + }, + "Submarine": { + "Fleet": { + "type": "select", + "value": 0, + "option": [ + 0, + 1, + 2 + ] + }, + "Mode": { + "type": "select", + "value": "do_not_use", + "option": [ + "do_not_use", + "hunt_only", + "boss_only", + "hunt_and_boss", + "every_combat" + ] + }, + "AutoSearchMode": { + "type": "select", + "value": "sub_standby", + "option": [ + "sub_standby", + "sub_auto_call" + ] + }, + "DistanceToBoss": { + "type": "select", + "value": "2_grid_to_boss", + "option": [ + "to_boss_position", + "1_grid_to_boss", + "2_grid_to_boss", + "use_open_ocean_support" + ] + } + }, + "Emotion": { + "Mode": { + "type": "select", + "value": "calculate", + "option": [ + "calculate", + "ignore", + "calculate_ignore" + ] + }, + "Fleet1Value": { + "type": "input", + "value": 119 + }, + "Fleet1Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet1Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet1Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet1Oath": { + "type": "checkbox", + "value": false + }, + "Fleet2Value": { + "type": "input", + "value": 119 + }, + "Fleet2Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet2Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet2Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet2Oath": { + "type": "checkbox", + "value": false + } + }, + "HpControl": { + "UseHpBalance": { + "type": "checkbox", + "value": false + }, + "UseEmergencyRepair": { + "type": "checkbox", + "value": false + }, + "UseLowHpRetreat": { + "type": "checkbox", + "value": false + }, + "HpBalanceThreshold": { + "type": "input", + "value": 0.2 + }, + "HpBalanceWeight": { + "type": "input", + "value": "1000, 1000, 1000" + }, + "RepairUseSingleThreshold": { + "type": "input", + "value": 0.3 + }, + "RepairUseMultiThreshold": { + "type": "input", + "value": 0.6 + }, + "LowHpRetreatThreshold": { + "type": "input", + "value": 0.3 + } + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": { + "type": "select", + "value": "default_mode", + "option": [ + "default_mode", + "S3_enemy_first", + "S1_enemy_first" + ] + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Main4": { + "Scheduler": { + "Enable": { + "type": "checkbox", + "value": false, + "option": [ + true, + false + ] + }, + "NextRun": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + }, + "Command": { + "type": "input", + "value": "Main4", + "display": "hide" + }, + "SuccessInterval": { + "type": "input", + "value": 0, + "display": "hide" + }, + "FailureInterval": { + "type": "input", + "value": 120, + "display": "hide" + }, + "ServerUpdate": { + "type": "input", + "value": "00:00", + "display": "hide" + } + }, + "Campaign": { + "Name": { + "type": "input", + "value": "12-4" + }, + "Event": { + "type": "select", + "value": "campaign_main", + "option": [ + "campaign_main" + ] + }, + "Mode": { + "type": "select", + "value": "normal", + "option": [ + "normal", + "hard" + ] + }, + "UseClearMode": { + "type": "checkbox", + "value": true + }, + "UseFleetLock": { + "type": "checkbox", + "value": true + }, + "UseAutoSearch": { + "type": "checkbox", + "value": true + }, + "Use2xBook": { + "type": "checkbox", + "value": false + }, + "AmbushEvade": { + "type": "checkbox", + "value": true + } + }, + "StopCondition": { + "OilLimit": { + "type": "input", + "value": 1000 + }, + "RunCount": { + "type": "input", + "value": 0 + }, + "MapAchievement": { + "type": "select", + "value": "non_stop", + "option": [ + "non_stop", + "100_percent_clear", + "map_3_stars", + "threat_safe", + "threat_safe_without_3_stars" + ] + }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, + "StageIncrease": { + "type": "checkbox", + "value": false + }, + "GetNewShip": { + "type": "checkbox", + "value": false + }, + "ReachLevel": { + "type": "input", + "value": 0 + } + }, + "Fleet": { + "Fleet1": { + "type": "select", + "value": 1, + "option": [ + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet1Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet1Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet1Step": { + "type": "select", + "value": 3, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "Fleet2": { + "type": "select", + "value": 2, + "option": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet2Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet2Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet2Step": { + "type": "select", + "value": 2, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "FleetOrder": { + "type": "select", + "value": "fleet1_mob_fleet2_boss", + "option": [ + "fleet1_mob_fleet2_boss", + "fleet1_boss_fleet2_mob", + "fleet1_all_fleet2_standby", + "fleet1_standby_fleet2_all" + ] + } + }, + "Submarine": { + "Fleet": { + "type": "select", + "value": 0, + "option": [ + 0, + 1, + 2 + ] + }, + "Mode": { + "type": "select", + "value": "do_not_use", + "option": [ + "do_not_use", + "hunt_only", + "boss_only", + "hunt_and_boss", + "every_combat" + ] + }, + "AutoSearchMode": { + "type": "select", + "value": "sub_standby", + "option": [ + "sub_standby", + "sub_auto_call" + ] + }, + "DistanceToBoss": { + "type": "select", + "value": "2_grid_to_boss", + "option": [ + "to_boss_position", + "1_grid_to_boss", + "2_grid_to_boss", + "use_open_ocean_support" + ] + } + }, + "Emotion": { + "Mode": { + "type": "select", + "value": "calculate", + "option": [ + "calculate", + "ignore", + "calculate_ignore" + ] + }, + "Fleet1Value": { + "type": "input", + "value": 119 + }, + "Fleet1Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet1Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet1Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet1Oath": { + "type": "checkbox", + "value": false + }, + "Fleet2Value": { + "type": "input", + "value": 119 + }, + "Fleet2Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet2Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet2Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet2Oath": { + "type": "checkbox", + "value": false + } + }, + "HpControl": { + "UseHpBalance": { + "type": "checkbox", + "value": false + }, + "UseEmergencyRepair": { + "type": "checkbox", + "value": false + }, + "UseLowHpRetreat": { + "type": "checkbox", + "value": false + }, + "HpBalanceThreshold": { + "type": "input", + "value": 0.2 + }, + "HpBalanceWeight": { + "type": "input", + "value": "1000, 1000, 1000" + }, + "RepairUseSingleThreshold": { + "type": "input", + "value": 0.3 + }, + "RepairUseMultiThreshold": { + "type": "input", + "value": 0.6 + }, + "LowHpRetreatThreshold": { + "type": "input", + "value": 0.3 + } + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": { + "type": "select", + "value": "default_mode", + "option": [ + "default_mode", + "S3_enemy_first", + "S1_enemy_first" + ] + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Main5": { + "Scheduler": { + "Enable": { + "type": "checkbox", + "value": false, + "option": [ + true, + false + ] + }, + "NextRun": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + }, + "Command": { + "type": "input", + "value": "Main5", + "display": "hide" + }, + "SuccessInterval": { + "type": "input", + "value": 0, + "display": "hide" + }, + "FailureInterval": { + "type": "input", + "value": 120, + "display": "hide" + }, + "ServerUpdate": { + "type": "input", + "value": "00:00", + "display": "hide" + } + }, + "Campaign": { + "Name": { + "type": "input", + "value": "12-4" + }, + "Event": { + "type": "select", + "value": "campaign_main", + "option": [ + "campaign_main" + ] + }, + "Mode": { + "type": "select", + "value": "normal", + "option": [ + "normal", + "hard" + ] + }, + "UseClearMode": { + "type": "checkbox", + "value": true + }, + "UseFleetLock": { + "type": "checkbox", + "value": true + }, + "UseAutoSearch": { + "type": "checkbox", + "value": true + }, + "Use2xBook": { + "type": "checkbox", + "value": false + }, + "AmbushEvade": { + "type": "checkbox", + "value": true + } + }, + "StopCondition": { + "OilLimit": { + "type": "input", + "value": 1000 + }, + "RunCount": { + "type": "input", + "value": 0 + }, + "MapAchievement": { + "type": "select", + "value": "non_stop", + "option": [ + "non_stop", + "100_percent_clear", + "map_3_stars", + "threat_safe", + "threat_safe_without_3_stars" + ] + }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, + "StageIncrease": { + "type": "checkbox", + "value": false + }, + "GetNewShip": { + "type": "checkbox", + "value": false + }, + "ReachLevel": { + "type": "input", + "value": 0 + } + }, + "Fleet": { + "Fleet1": { + "type": "select", + "value": 1, + "option": [ + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet1Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet1Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet1Step": { + "type": "select", + "value": 3, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "Fleet2": { + "type": "select", + "value": 2, + "option": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet2Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet2Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet2Step": { + "type": "select", + "value": 2, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "FleetOrder": { + "type": "select", + "value": "fleet1_mob_fleet2_boss", + "option": [ + "fleet1_mob_fleet2_boss", + "fleet1_boss_fleet2_mob", + "fleet1_all_fleet2_standby", + "fleet1_standby_fleet2_all" + ] + } + }, + "Submarine": { + "Fleet": { + "type": "select", + "value": 0, + "option": [ + 0, + 1, + 2 + ] + }, + "Mode": { + "type": "select", + "value": "do_not_use", + "option": [ + "do_not_use", + "hunt_only", + "boss_only", + "hunt_and_boss", + "every_combat" + ] + }, + "AutoSearchMode": { + "type": "select", + "value": "sub_standby", + "option": [ + "sub_standby", + "sub_auto_call" + ] + }, + "DistanceToBoss": { + "type": "select", + "value": "2_grid_to_boss", + "option": [ + "to_boss_position", + "1_grid_to_boss", + "2_grid_to_boss", + "use_open_ocean_support" + ] + } + }, + "Emotion": { + "Mode": { + "type": "select", + "value": "calculate", + "option": [ + "calculate", + "ignore", + "calculate_ignore" + ] + }, + "Fleet1Value": { + "type": "input", + "value": 119 + }, + "Fleet1Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet1Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet1Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet1Oath": { + "type": "checkbox", + "value": false + }, + "Fleet2Value": { + "type": "input", + "value": 119 + }, + "Fleet2Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet2Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet2Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet2Oath": { + "type": "checkbox", + "value": false + } + }, + "HpControl": { + "UseHpBalance": { + "type": "checkbox", + "value": false + }, + "UseEmergencyRepair": { + "type": "checkbox", + "value": false + }, + "UseLowHpRetreat": { + "type": "checkbox", + "value": false + }, + "HpBalanceThreshold": { + "type": "input", + "value": 0.2 + }, + "HpBalanceWeight": { + "type": "input", + "value": "1000, 1000, 1000" + }, + "RepairUseSingleThreshold": { + "type": "input", + "value": 0.3 + }, + "RepairUseMultiThreshold": { + "type": "input", + "value": 0.6 + }, + "LowHpRetreatThreshold": { + "type": "input", + "value": 0.3 + } + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": { + "type": "select", + "value": "default_mode", + "option": [ + "default_mode", + "S3_enemy_first", + "S1_enemy_first" + ] + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Main6": { + "Scheduler": { + "Enable": { + "type": "checkbox", + "value": false, + "option": [ + true, + false + ] + }, + "NextRun": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + }, + "Command": { + "type": "input", + "value": "Main6", + "display": "hide" + }, + "SuccessInterval": { + "type": "input", + "value": 0, + "display": "hide" + }, + "FailureInterval": { + "type": "input", + "value": 120, + "display": "hide" + }, + "ServerUpdate": { + "type": "input", + "value": "00:00", + "display": "hide" + } + }, + "Campaign": { + "Name": { + "type": "input", + "value": "12-4" + }, + "Event": { + "type": "select", + "value": "campaign_main", + "option": [ + "campaign_main" + ] + }, + "Mode": { + "type": "select", + "value": "normal", + "option": [ + "normal", + "hard" + ] + }, + "UseClearMode": { + "type": "checkbox", + "value": true + }, + "UseFleetLock": { + "type": "checkbox", + "value": true + }, + "UseAutoSearch": { + "type": "checkbox", + "value": true + }, + "Use2xBook": { + "type": "checkbox", + "value": false + }, + "AmbushEvade": { + "type": "checkbox", + "value": true + } + }, + "StopCondition": { + "OilLimit": { + "type": "input", + "value": 1000 + }, + "RunCount": { + "type": "input", + "value": 0 + }, + "MapAchievement": { + "type": "select", + "value": "non_stop", + "option": [ + "non_stop", + "100_percent_clear", + "map_3_stars", + "threat_safe", + "threat_safe_without_3_stars" + ] + }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -2204,6 +3443,11 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1", + "display": "hide" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -2926,6 +4170,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -3303,6 +4551,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -3680,6 +4932,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -4057,6 +5313,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -4434,6 +5694,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -4811,6 +6075,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -5117,7 +6385,10 @@ "option": [ "Main", "Main2", - "Main3" + "Main3", + "Main4", + "Main5", + "Main6" ] } }, @@ -5309,6 +6580,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -5767,6 +7042,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -6225,6 +7504,1156 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, + "StageIncrease": { + "type": "checkbox", + "value": false + }, + "GetNewShip": { + "type": "checkbox", + "value": false + }, + "ReachLevel": { + "type": "input", + "value": 0 + } + }, + "Fleet": { + "Fleet1": { + "type": "select", + "value": 1, + "option": [ + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet1Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet1Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet1Step": { + "type": "select", + "value": 3, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "Fleet2": { + "type": "select", + "value": 2, + "option": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet2Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet2Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet2Step": { + "type": "select", + "value": 2, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "FleetOrder": { + "type": "select", + "value": "fleet1_mob_fleet2_boss", + "option": [ + "fleet1_mob_fleet2_boss", + "fleet1_boss_fleet2_mob", + "fleet1_all_fleet2_standby", + "fleet1_standby_fleet2_all" + ] + } + }, + "Submarine": { + "Fleet": { + "type": "select", + "value": 0, + "option": [ + 0, + 1, + 2 + ] + }, + "Mode": { + "type": "select", + "value": "do_not_use", + "option": [ + "do_not_use", + "hunt_only", + "boss_only", + "hunt_and_boss", + "every_combat" + ] + }, + "AutoSearchMode": { + "type": "select", + "value": "sub_standby", + "option": [ + "sub_standby", + "sub_auto_call" + ] + }, + "DistanceToBoss": { + "type": "select", + "value": "2_grid_to_boss", + "option": [ + "to_boss_position", + "1_grid_to_boss", + "2_grid_to_boss", + "use_open_ocean_support" + ] + } + }, + "Emotion": { + "Mode": { + "type": "select", + "value": "calculate", + "option": [ + "calculate", + "ignore", + "calculate_ignore" + ] + }, + "Fleet1Value": { + "type": "input", + "value": 119 + }, + "Fleet1Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet1Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet1Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet1Oath": { + "type": "checkbox", + "value": false + }, + "Fleet2Value": { + "type": "input", + "value": 119 + }, + "Fleet2Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet2Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet2Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet2Oath": { + "type": "checkbox", + "value": false + } + }, + "HpControl": { + "UseHpBalance": { + "type": "checkbox", + "value": false + }, + "UseEmergencyRepair": { + "type": "checkbox", + "value": false + }, + "UseLowHpRetreat": { + "type": "checkbox", + "value": false + }, + "HpBalanceThreshold": { + "type": "input", + "value": 0.2 + }, + "HpBalanceWeight": { + "type": "input", + "value": "1000, 1000, 1000" + }, + "RepairUseSingleThreshold": { + "type": "input", + "value": 0.3 + }, + "RepairUseMultiThreshold": { + "type": "input", + "value": 0.6 + }, + "LowHpRetreatThreshold": { + "type": "input", + "value": 0.3 + } + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": { + "type": "select", + "value": "default_mode", + "option": [ + "default_mode", + "S3_enemy_first", + "S1_enemy_first" + ] + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Event4": { + "Scheduler": { + "Enable": { + "type": "checkbox", + "value": false, + "option": [ + true, + false + ] + }, + "NextRun": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + }, + "Command": { + "type": "input", + "value": "Event4", + "display": "hide" + }, + "SuccessInterval": { + "type": "input", + "value": 0, + "display": "hide" + }, + "FailureInterval": { + "type": "input", + "value": 120, + "display": "hide" + }, + "ServerUpdate": { + "type": "input", + "value": "00:00", + "display": "hide" + } + }, + "Campaign": { + "Name": { + "type": "input", + "value": "12-4" + }, + "Event": { + "type": "select", + "value": "campaign_main", + "option": [ + "campaign_main" + ] + }, + "Mode": { + "type": "select", + "value": "normal", + "option": [ + "normal", + "hard" + ], + "display": "hide" + }, + "UseClearMode": { + "type": "checkbox", + "value": true + }, + "UseFleetLock": { + "type": "checkbox", + "value": true + }, + "UseAutoSearch": { + "type": "checkbox", + "value": true + }, + "Use2xBook": { + "type": "checkbox", + "value": false + }, + "AmbushEvade": { + "type": "checkbox", + "value": true, + "display": "hide" + } + }, + "StopCondition": { + "OilLimit": { + "type": "input", + "value": 1000 + }, + "RunCount": { + "type": "input", + "value": 0 + }, + "MapAchievement": { + "type": "select", + "value": "non_stop", + "option": [ + "non_stop", + "100_percent_clear", + "map_3_stars", + "threat_safe", + "threat_safe_without_3_stars" + ] + }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, + "StageIncrease": { + "type": "checkbox", + "value": false + }, + "GetNewShip": { + "type": "checkbox", + "value": false + }, + "ReachLevel": { + "type": "input", + "value": 0 + } + }, + "Fleet": { + "Fleet1": { + "type": "select", + "value": 1, + "option": [ + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet1Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet1Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet1Step": { + "type": "select", + "value": 3, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "Fleet2": { + "type": "select", + "value": 2, + "option": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet2Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet2Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet2Step": { + "type": "select", + "value": 2, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "FleetOrder": { + "type": "select", + "value": "fleet1_mob_fleet2_boss", + "option": [ + "fleet1_mob_fleet2_boss", + "fleet1_boss_fleet2_mob", + "fleet1_all_fleet2_standby", + "fleet1_standby_fleet2_all" + ] + } + }, + "Submarine": { + "Fleet": { + "type": "select", + "value": 0, + "option": [ + 0, + 1, + 2 + ] + }, + "Mode": { + "type": "select", + "value": "do_not_use", + "option": [ + "do_not_use", + "hunt_only", + "boss_only", + "hunt_and_boss", + "every_combat" + ] + }, + "AutoSearchMode": { + "type": "select", + "value": "sub_standby", + "option": [ + "sub_standby", + "sub_auto_call" + ] + }, + "DistanceToBoss": { + "type": "select", + "value": "2_grid_to_boss", + "option": [ + "to_boss_position", + "1_grid_to_boss", + "2_grid_to_boss", + "use_open_ocean_support" + ] + } + }, + "Emotion": { + "Mode": { + "type": "select", + "value": "calculate", + "option": [ + "calculate", + "ignore", + "calculate_ignore" + ] + }, + "Fleet1Value": { + "type": "input", + "value": 119 + }, + "Fleet1Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet1Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet1Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet1Oath": { + "type": "checkbox", + "value": false + }, + "Fleet2Value": { + "type": "input", + "value": 119 + }, + "Fleet2Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet2Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet2Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet2Oath": { + "type": "checkbox", + "value": false + } + }, + "HpControl": { + "UseHpBalance": { + "type": "checkbox", + "value": false + }, + "UseEmergencyRepair": { + "type": "checkbox", + "value": false + }, + "UseLowHpRetreat": { + "type": "checkbox", + "value": false + }, + "HpBalanceThreshold": { + "type": "input", + "value": 0.2 + }, + "HpBalanceWeight": { + "type": "input", + "value": "1000, 1000, 1000" + }, + "RepairUseSingleThreshold": { + "type": "input", + "value": 0.3 + }, + "RepairUseMultiThreshold": { + "type": "input", + "value": 0.6 + }, + "LowHpRetreatThreshold": { + "type": "input", + "value": 0.3 + } + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": { + "type": "select", + "value": "default_mode", + "option": [ + "default_mode", + "S3_enemy_first", + "S1_enemy_first" + ] + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Event5": { + "Scheduler": { + "Enable": { + "type": "checkbox", + "value": false, + "option": [ + true, + false + ] + }, + "NextRun": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + }, + "Command": { + "type": "input", + "value": "Event5", + "display": "hide" + }, + "SuccessInterval": { + "type": "input", + "value": 0, + "display": "hide" + }, + "FailureInterval": { + "type": "input", + "value": 120, + "display": "hide" + }, + "ServerUpdate": { + "type": "input", + "value": "00:00", + "display": "hide" + } + }, + "Campaign": { + "Name": { + "type": "input", + "value": "12-4" + }, + "Event": { + "type": "select", + "value": "campaign_main", + "option": [ + "campaign_main" + ] + }, + "Mode": { + "type": "select", + "value": "normal", + "option": [ + "normal", + "hard" + ], + "display": "hide" + }, + "UseClearMode": { + "type": "checkbox", + "value": true + }, + "UseFleetLock": { + "type": "checkbox", + "value": true + }, + "UseAutoSearch": { + "type": "checkbox", + "value": true + }, + "Use2xBook": { + "type": "checkbox", + "value": false + }, + "AmbushEvade": { + "type": "checkbox", + "value": true, + "display": "hide" + } + }, + "StopCondition": { + "OilLimit": { + "type": "input", + "value": 1000 + }, + "RunCount": { + "type": "input", + "value": 0 + }, + "MapAchievement": { + "type": "select", + "value": "non_stop", + "option": [ + "non_stop", + "100_percent_clear", + "map_3_stars", + "threat_safe", + "threat_safe_without_3_stars" + ] + }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, + "StageIncrease": { + "type": "checkbox", + "value": false + }, + "GetNewShip": { + "type": "checkbox", + "value": false + }, + "ReachLevel": { + "type": "input", + "value": 0 + } + }, + "Fleet": { + "Fleet1": { + "type": "select", + "value": 1, + "option": [ + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet1Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet1Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet1Step": { + "type": "select", + "value": 3, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "Fleet2": { + "type": "select", + "value": 2, + "option": [ + 0, + 1, + 2, + 3, + 4, + 5, + 6 + ] + }, + "Fleet2Formation": { + "type": "select", + "value": "double_line", + "option": [ + "line_ahead", + "double_line", + "diamond" + ] + }, + "Fleet2Mode": { + "type": "select", + "value": "combat_auto", + "option": [ + "combat_auto", + "combat_manual", + "stand_still_in_the_middle", + "hide_in_bottom_left" + ] + }, + "Fleet2Step": { + "type": "select", + "value": 2, + "option": [ + 2, + 3, + 4, + 5 + ] + }, + "FleetOrder": { + "type": "select", + "value": "fleet1_mob_fleet2_boss", + "option": [ + "fleet1_mob_fleet2_boss", + "fleet1_boss_fleet2_mob", + "fleet1_all_fleet2_standby", + "fleet1_standby_fleet2_all" + ] + } + }, + "Submarine": { + "Fleet": { + "type": "select", + "value": 0, + "option": [ + 0, + 1, + 2 + ] + }, + "Mode": { + "type": "select", + "value": "do_not_use", + "option": [ + "do_not_use", + "hunt_only", + "boss_only", + "hunt_and_boss", + "every_combat" + ] + }, + "AutoSearchMode": { + "type": "select", + "value": "sub_standby", + "option": [ + "sub_standby", + "sub_auto_call" + ] + }, + "DistanceToBoss": { + "type": "select", + "value": "2_grid_to_boss", + "option": [ + "to_boss_position", + "1_grid_to_boss", + "2_grid_to_boss", + "use_open_ocean_support" + ] + } + }, + "Emotion": { + "Mode": { + "type": "select", + "value": "calculate", + "option": [ + "calculate", + "ignore", + "calculate_ignore" + ] + }, + "Fleet1Value": { + "type": "input", + "value": 119 + }, + "Fleet1Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet1Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet1Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet1Oath": { + "type": "checkbox", + "value": false + }, + "Fleet2Value": { + "type": "input", + "value": 119 + }, + "Fleet2Record": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime", + "display": "disabled" + }, + "Fleet2Control": { + "type": "select", + "value": "prevent_yellow_face", + "option": [ + "keep_exp_bonus", + "prevent_green_face", + "prevent_yellow_face", + "prevent_red_face" + ] + }, + "Fleet2Recover": { + "type": "select", + "value": "not_in_dormitory", + "option": [ + "not_in_dormitory", + "dormitory_floor_1", + "dormitory_floor_2" + ] + }, + "Fleet2Oath": { + "type": "checkbox", + "value": false + } + }, + "HpControl": { + "UseHpBalance": { + "type": "checkbox", + "value": false + }, + "UseEmergencyRepair": { + "type": "checkbox", + "value": false + }, + "UseLowHpRetreat": { + "type": "checkbox", + "value": false + }, + "HpBalanceThreshold": { + "type": "input", + "value": 0.2 + }, + "HpBalanceWeight": { + "type": "input", + "value": "1000, 1000, 1000" + }, + "RepairUseSingleThreshold": { + "type": "input", + "value": 0.3 + }, + "RepairUseMultiThreshold": { + "type": "input", + "value": 0.6 + }, + "LowHpRetreatThreshold": { + "type": "input", + "value": 0.3 + } + }, + "EnemyPriority": { + "EnemyScaleBalanceWeight": { + "type": "select", + "value": "default_mode", + "option": [ + "default_mode", + "S3_enemy_first", + "S1_enemy_first" + ] + } + }, + "Storage": { + "Storage": { + "type": "storage", + "value": {}, + "valuetype": "ignore", + "display": "disabled" + } + } + }, + "Event6": { + "Scheduler": { + "Enable": { + "type": "checkbox", + "value": false, + "option": [ + true, + false + ] + }, + "NextRun": { + "type": "datetime", + "value": "2020-01-01 00:00:00", + "validate": "datetime" + }, + "Command": { + "type": "input", + "value": "Event6", + "display": "hide" + }, + "SuccessInterval": { + "type": "input", + "value": 0, + "display": "hide" + }, + "FailureInterval": { + "type": "input", + "value": 120, + "display": "hide" + }, + "ServerUpdate": { + "type": "input", + "value": "00:00", + "display": "hide" + } + }, + "Campaign": { + "Name": { + "type": "input", + "value": "12-4" + }, + "Event": { + "type": "select", + "value": "campaign_main", + "option": [ + "campaign_main" + ] + }, + "Mode": { + "type": "select", + "value": "normal", + "option": [ + "normal", + "hard" + ], + "display": "hide" + }, + "UseClearMode": { + "type": "checkbox", + "value": true + }, + "UseFleetLock": { + "type": "checkbox", + "value": true + }, + "UseAutoSearch": { + "type": "checkbox", + "value": true + }, + "Use2xBook": { + "type": "checkbox", + "value": false + }, + "AmbushEvade": { + "type": "checkbox", + "value": true, + "display": "hide" + } + }, + "StopCondition": { + "OilLimit": { + "type": "input", + "value": 1000 + }, + "RunCount": { + "type": "input", + "value": 0 + }, + "MapAchievement": { + "type": "select", + "value": "non_stop", + "option": [ + "non_stop", + "100_percent_clear", + "map_3_stars", + "threat_safe", + "threat_safe_without_3_stars" + ] + }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -6641,6 +9070,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -6747,183 +9180,6 @@ } } }, - "Hospital": { - "Scheduler": { - "Enable": { - "type": "checkbox", - "value": false, - "option": [ - true, - false - ] - }, - "NextRun": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - }, - "Command": { - "type": "input", - "value": "Hospital", - "display": "hide" - }, - "SuccessInterval": { - "type": "input", - "value": 0, - "display": "hide" - }, - "FailureInterval": { - "type": "input", - "value": 120, - "display": "hide" - }, - "ServerUpdate": { - "type": "input", - "value": "00:00", - "display": "hide" - } - }, - "Hospital": { - "UseRecommendFleet": { - "type": "checkbox", - "value": true - }, - "mapName": { - "type": "input", - "value": "0-T1" - } - }, - "StopCondition": { - "OilLimit": { - "type": "input", - "value": 1000 - }, - "RunCount": { - "type": "input", - "value": 0, - "display": "hide" - }, - "MapAchievement": { - "type": "select", - "value": "non_stop", - "option": [ - "non_stop", - "100_percent_clear", - "map_3_stars", - "threat_safe", - "threat_safe_without_3_stars" - ], - "display": "hide" - }, - "StageIncrease": { - "type": "checkbox", - "value": false, - "display": "hide" - }, - "GetNewShip": { - "type": "checkbox", - "value": false, - "display": "hide" - }, - "ReachLevel": { - "type": "input", - "value": 0, - "display": "hide" - } - }, - "Emotion": { - "Mode": { - "type": "select", - "value": "calculate", - "option": [ - "calculate", - "ignore", - "calculate_ignore" - ] - }, - "Fleet1Value": { - "type": "input", - "value": 119 - }, - "Fleet1Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime", - "display": "disabled" - }, - "Fleet1Control": { - "type": "select", - "value": "prevent_yellow_face", - "option": [ - "keep_exp_bonus", - "prevent_green_face", - "prevent_yellow_face", - "prevent_red_face" - ], - "display": "hide" - }, - "Fleet1Recover": { - "type": "select", - "value": "not_in_dormitory", - "option": [ - "not_in_dormitory", - "dormitory_floor_1", - "dormitory_floor_2" - ], - "display": "hide" - }, - "Fleet1Oath": { - "type": "checkbox", - "value": false, - "display": "hide" - }, - "Fleet2Value": { - "type": "input", - "value": 119, - "display": "hide" - }, - "Fleet2Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime", - "display": "hide" - }, - "Fleet2Control": { - "type": "select", - "value": "prevent_yellow_face", - "option": [ - "keep_exp_bonus", - "prevent_green_face", - "prevent_yellow_face", - "prevent_red_face" - ], - "display": "hide" - }, - "Fleet2Recover": { - "type": "select", - "value": "not_in_dormitory", - "option": [ - "not_in_dormitory", - "dormitory_floor_1", - "dormitory_floor_2" - ], - "display": "hide" - }, - "Fleet2Oath": { - "type": "checkbox", - "value": false, - "display": "hide" - } - }, - "Storage": { - "Storage": { - "type": "storage", - "value": {}, - "valuetype": "ignore", - "display": "disabled" - } - } - }, "Coalition": { "Scheduler": { "Enable": { @@ -7058,6 +9314,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -7357,6 +9617,10 @@ "threat_safe_without_3_stars" ] }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false @@ -7829,6 +10093,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -8304,6 +10572,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -8779,6 +11051,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -9254,6 +11530,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -9719,6 +11999,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -10130,6 +12414,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -10372,6 +12660,10 @@ ], "display": "hide" }, + "StopBarrier": { + "type": "input", + "value": "1-1" + }, "StageIncrease": { "type": "checkbox", "value": false, @@ -11652,6 +13944,10 @@ } }, "GuildShop": { + "Enable": { + "type": "checkbox", + "value": true + }, "Refresh": { "type": "checkbox", "value": true @@ -11785,6 +14081,10 @@ } }, "MedalShop2": { + "Enable": { + "type": "checkbox", + "value": true + }, "Filter": { "type": "textarea", "value": "DR > PR\n> BookRedT3 > BookYellowT3 > BookBlueT3\n> BookRedT2 > BookYellowT2 > BookBlueT2\n> RetrofitT3\n> FoodT6 > FoodT5\n> PlateGeneralT3 > PlateWildT3" @@ -11854,6 +14154,10 @@ } }, "MeritShop": { + "Enable": { + "type": "checkbox", + "value": true + }, "Refresh": { "type": "checkbox", "value": false @@ -11864,6 +14168,10 @@ } }, "CoreShop": { + "Enable": { + "type": "checkbox", + "value": true + }, "Filter": { "type": "textarea", "value": "Array" @@ -13559,275 +15867,5 @@ "display": "disabled" } } - }, - "Dashboard": { - "Oil": { - "Value": { - "type": "input", - "value": 0 - }, - "Limit": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^000000", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Coin": { - "Value": { - "type": "input", - "value": 0 - }, - "Limit": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FFAA33", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Gem": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FF3333", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Pt": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^00BFFF", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Cube": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^33FFFF", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "ActionPoint": { - "Value": { - "type": "input", - "value": 0 - }, - "Total": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^0000FF", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "YellowCoin": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FF8800", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "PurpleCoin": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^7700BB", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Core": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^AAAAAA", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Medal": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FFDD00", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Merit": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FFFF00", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "GuildCoin": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^AAAAAA", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "ResearchPercent": { - "Value": { - "type": "input", - "value": 0 - }, - "Limit": { - "type": "input", - "value": 100 - }, - "Color": { - "type": "input", - "value": "^00AA00", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "PlayerLevel": { - "Value": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FFAA33", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "PlayerExp": { - "Value": { - "type": "input", - "value": 0 - }, - "Limit": { - "type": "input", - "value": 0 - }, - "Color": { - "type": "input", - "value": "^FFAA33", - "display": "hide" - }, - "Record": { - "type": "datetime", - "value": "2020-01-01 00:00:00", - "validate": "datetime" - } - }, - "Storage": { - "Storage": { - "type": "storage", - "value": {}, - "valuetype": "ignore", - "display": "disabled" - } - } } } \ No newline at end of file diff --git a/module/config/argument/argument.yaml b/module/config/argument/argument.yaml index 3d21a7e0c..c183f4ce0 100644 --- a/module/config/argument/argument.yaml +++ b/module/config/argument/argument.yaml @@ -83,6 +83,7 @@ EmulatorInfo: Error: HandleError: true SaveError: true + SaveConfig: true OnePushConfig: type: textarea mode: yaml @@ -224,6 +225,8 @@ StopCondition: MapAchievement: value: non_stop option: [ non_stop, 100_percent_clear, map_3_stars, threat_safe, threat_safe_without_3_stars ] + StopBarrier: + value: 1-1 StageIncrease: false GetNewShip: false ReachLevel: 0 @@ -512,12 +515,14 @@ VanguardFilter: EventGeneral: PtLimit: 0 TimeLimit: 2020-01-01 00:00:00 +KeepOil: + TimeLimit: 2020-01-01 00:00:00 TaskBalancer: Enable: false CoinLimit: 10000 TaskCall: value: Main - option: [ Main, Main2, Main3 ] + option: [ Main, Main2, Main3, Main4, Main5, Main6 ] EventDaily: StageFilter: |- A1 > A2 > A3 @@ -706,6 +711,7 @@ GeneralShop: > Cube > FoodT6 > FoodT5 GuildShop: + Enable: true Refresh: true Filter: |- PlateT4 > BookT3 > PR > CatT3 > Chip > BookT2 > Retrofit > FoodT6 > FoodT5 > CatT2 > BoxT4 @@ -746,6 +752,7 @@ GuildShop: value: cheshire option: [ cheshire, mainz, odin, champagne ] MedalShop2: + Enable: true Filter: |- DR > PR > BookRedT3 > BookYellowT3 > BookBlueT3 @@ -772,10 +779,12 @@ MedalShop2: value: general option: [ general, gun, torpedo, antiair, plane ] MeritShop: + Enable: true Refresh: false Filter: |- Cube CoreShop: + Enable: true Filter: |- Array EventShop: @@ -1228,4 +1237,32 @@ InstanceRestart: value: false HasRestarted: value: 0 - display: hide \ No newline at end of file + display: hide +ExitWhenMaintenance: + Enable: false + Notify: true + + +# ==================== Remark ====================== +Boss: + Name: '' + Account: '' + Password: '' + SecondPassword: '' + +OutDate: + TimeLimit: 2020-01-01 00:00:00 + +Comment: + Content: + type: textarea + value: '' + +# ==================== OthersLogin ====================== +OthersLogin: + Enable: false + Method: + value: stay_there + option: [ stay_there, close_game ] + Interval: 60 + Notify: true \ No newline at end of file diff --git a/module/config/argument/gui.yaml b/module/config/argument/gui.yaml index 894a3d616..4062b528c 100644 --- a/module/config/argument/gui.yaml +++ b/module/config/argument/gui.yaml @@ -22,6 +22,7 @@ Button: ClickToUpdate: RetryUpdate: CancelUpdate: + OneClickStop: OneClickClear: Confirm: Cancel: diff --git a/module/config/argument/menu.json b/module/config/argument/menu.json index c1178cf97..f9c3d57df 100644 --- a/module/config/argument/menu.json +++ b/module/config/argument/menu.json @@ -6,6 +6,8 @@ "Alas", "General", "Restart", + "OthersLogin", + "Remark", "Hook" ] }, @@ -16,6 +18,9 @@ "Main", "Main2", "Main3", + "Main4", + "Main5", + "Main6", "GemsFarming" ] }, @@ -40,8 +45,10 @@ "Event", "Event2", "Event3", + "Event4", + "Event5", + "Event6", "Raid", - "Hospital", "Coalition", "MaritimeEscort", "WarArchives" diff --git a/module/config/argument/override.yaml b/module/config/argument/override.yaml index ff3cf8229..669020ec4 100644 --- a/module/config/argument/override.yaml +++ b/module/config/argument/override.yaml @@ -62,6 +62,8 @@ GemsFarming: StageIncrease: false GetNewShip: false ReachLevel: 0 + StopBarrier: + display: hide Fleet: FleetOrder: display: display @@ -86,6 +88,24 @@ Event3: Campaign: Mode: normal # Event: +# display: disabled + AmbushEvade: true +Event4: + Campaign: + Mode: normal +# Event: +# display: disabled + AmbushEvade: true +Event5: + Campaign: + Mode: normal +# Event: +# display: disabled + AmbushEvade: true +Event6: + Campaign: + Mode: normal +# Event: # display: disabled AmbushEvade: true EventA: diff --git a/module/config/argument/task.yaml b/module/config/argument/task.yaml index b16c21977..ea0213510 100644 --- a/module/config/argument/task.yaml +++ b/module/config/argument/task.yaml @@ -25,6 +25,13 @@ Alas: - RestartEmulator - AutoRestart - InstanceRestart + - ExitWhenMaintenance + OthersLogin: + - OthersLogin + Remark: + - Boss + - OutDate + - Comment Hook: - HookGeneral - Misc @@ -64,6 +71,33 @@ Farm: - Emotion - HpControl - EnemyPriority + Main4: + - Scheduler + - Campaign + - StopCondition + - Fleet + - Submarine + - Emotion + - HpControl + - EnemyPriority + Main5: + - Scheduler + - Campaign + - StopCondition + - Fleet + - Submarine + - Emotion + - HpControl + - EnemyPriority + Main6: + - Scheduler + - Campaign + - StopCondition + - Fleet + - Submarine + - Emotion + - HpControl + - EnemyPriority GemsFarming: - Scheduler - GemsFarming @@ -181,17 +215,39 @@ Event: - Emotion - HpControl - EnemyPriority + Event4: + - Scheduler + - Campaign + - StopCondition + - Fleet + - Submarine + - Emotion + - HpControl + - EnemyPriority + Event5: + - Scheduler + - Campaign + - StopCondition + - Fleet + - Submarine + - Emotion + - HpControl + - EnemyPriority + Event6: + - Scheduler + - Campaign + - StopCondition + - Fleet + - Submarine + - Emotion + - HpControl + - EnemyPriority Raid: - Scheduler - Raid - Campaign - StopCondition - Emotion - Hospital: - - Scheduler - - Hospital - - StopCondition - - Emotion Coalition: - Scheduler - Campaign diff --git a/module/config/config_generated.py b/module/config/config_generated.py index 48130b105..69814b33b 100644 --- a/module/config/config_generated.py +++ b/module/config/config_generated.py @@ -34,6 +34,7 @@ class GeneratedConfig: # Group `Error` Error_HandleError = True Error_SaveError = True + Error_SaveConfig = True Error_OnePushConfig = 'provider: null' Error_ScreenshotLength = 1 @@ -137,6 +138,7 @@ class GeneratedConfig: StopCondition_OilLimit = 1000 StopCondition_RunCount = 0 StopCondition_MapAchievement = 'non_stop' # non_stop, 100_percent_clear, map_3_stars, threat_safe, threat_safe_without_3_stars + StopCondition_StopBarrier = '1-1' StopCondition_StageIncrease = False StopCondition_GetNewShip = False StopCondition_ReachLevel = 0 @@ -297,10 +299,13 @@ class GeneratedConfig: EventGeneral_PtLimit = 0 EventGeneral_TimeLimit = datetime.datetime(2020, 1, 1, 0, 0) + # Group `KeepOil` + KeepOil_TimeLimit = datetime.datetime(2020, 1, 1, 0, 0) + # Group `TaskBalancer` TaskBalancer_Enable = False TaskBalancer_CoinLimit = 10000 - TaskBalancer_TaskCall = 'Main' # Main, Main2, Main3 + TaskBalancer_TaskCall = 'Main' # Main, Main2, Main3, Main4, Main5, Main6 # Group `EventDaily` EventDaily_StageFilter = 'A1 > A2 > A3' @@ -410,6 +415,7 @@ class GeneratedConfig: GeneralShop_Filter = 'BookRedT3 > BookYellowT3 > BookBlueT3 > BookRedT2\n> Cube\n> FoodT6 > FoodT5' # Group `GuildShop` + GuildShop_Enable = True GuildShop_Refresh = True GuildShop_Filter = 'PlateT4 > BookT3 > PR > CatT3 > Chip > BookT2 > Retrofit > FoodT6 > FoodT5 > CatT2 > BoxT4' GuildShop_BOX_T3 = 'ironblood' # eagle, royal, sakura, ironblood @@ -426,6 +432,7 @@ class GeneratedConfig: GuildShop_PR3 = 'cheshire' # cheshire, mainz, odin, champagne # Group `MedalShop2` + MedalShop2_Enable = True MedalShop2_Filter = 'DR > PR\n> BookRedT3 > BookYellowT3 > BookBlueT3\n> BookRedT2 > BookYellowT2 > BookBlueT2\n> RetrofitT3\n> FoodT6 > FoodT5\n> PlateGeneralT3 > PlateWildT3' MedalShop2_RETROFIT_T1 = 'cl' # dd, cl, bb, cv MedalShop2_RETROFIT_T2 = 'cl' # dd, cl, bb, cv @@ -435,10 +442,12 @@ class GeneratedConfig: MedalShop2_PLATE_T3 = 'general' # general, gun, torpedo, antiair, plane # Group `MeritShop` + MeritShop_Enable = True MeritShop_Refresh = False MeritShop_Filter = 'Cube' # Group `CoreShop` + CoreShop_Enable = True CoreShop_Filter = 'Array' # Group `EventShop` @@ -738,5 +747,27 @@ class GeneratedConfig: InstanceRestart_NotifyWhenAutoRestart = False InstanceRestart_HasRestarted = 0 + # Group `ExitWhenMaintenance` + ExitWhenMaintenance_Enable = False + ExitWhenMaintenance_Notify = True + + # Group `Boss` + Boss_Name = None + Boss_Account = None + Boss_Password = None + Boss_SecondPassword = None + + # Group `OutDate` + OutDate_TimeLimit = datetime.datetime(2020, 1, 1, 0, 0) + + # Group `Comment` + Comment_Content = None + + # Group `OthersLogin` + OthersLogin_Enable = False + OthersLogin_Method = 'stay_there' # stay_there, close_game + OthersLogin_Interval = 60 + OthersLogin_Notify = True + # Group `Storage` Storage_Storage = {} diff --git a/module/config/i18n/en-US.json b/module/config/i18n/en-US.json index 21ceff2a0..57d115434 100644 --- a/module/config/i18n/en-US.json +++ b/module/config/i18n/en-US.json @@ -50,6 +50,14 @@ "name": "Restart", "help": "" }, + "OthersLogin": { + "name": "Task.OthersLogin.name", + "help": "Task.OthersLogin.help" + }, + "Remark": { + "name": "Task.Remark.name", + "help": "Task.Remark.help" + }, "Hook": { "name": "Task.Hook.name", "help": "Task.Hook.help" @@ -66,6 +74,18 @@ "name": "Main-3", "help": "" }, + "Main4": { + "name": "Task.Main4.name", + "help": "Task.Main4.help" + }, + "Main5": { + "name": "Task.Main5.name", + "help": "Task.Main5.help" + }, + "Main6": { + "name": "Task.Main6.name", + "help": "Task.Main6.help" + }, "GemsFarming": { "name": "Commission Farming", "help": "" @@ -114,14 +134,22 @@ "name": "Task.Event3.name", "help": "Task.Event3.help" }, + "Event4": { + "name": "Task.Event4.name", + "help": "Task.Event4.help" + }, + "Event5": { + "name": "Task.Event5.name", + "help": "Task.Event5.help" + }, + "Event6": { + "name": "Task.Event6.name", + "help": "Task.Event6.help" + }, "Raid": { "name": "Raid", "help": "" }, - "Hospital": { - "name": "Valley Hospital", - "help": "" - }, "Coalition": { "name": "Little Academy", "help": "" @@ -533,6 +561,10 @@ "name": "Record Exception", "help": "Records exception and log into directory for review or sharing" }, + "SaveConfig": { + "name": "Error.SaveConfig.name", + "help": "Error.SaveConfig.help" + }, "OnePushConfig": { "name": "Error notify config", "help": "When Alas cannot handle exception, send a message through Onepush. Configuration document: \nhttps://github.com/LmeSzinc/AzurLaneAutoScript/wiki/Onepush-configuration-%5BEN%5D" @@ -1102,6 +1134,10 @@ "threat_safe": "100% Clear + 3 Stars + Threat Safe", "threat_safe_without_3_stars": "100% Clear + Threat Safe" }, + "StopBarrier": { + "name": "StopCondition.StopBarrier.name", + "help": "StopCondition.StopBarrier.help" + }, "StageIncrease": { "name": "Enable Continuous Clear", "help": "Suited for 100% Clear, requires sufficient fleet strength and satisfying level attribute restrictions for every level involved\n1-1 to 15-4, A1 to A3, B1 to B3, C1 to C3, D1 to D3, T1 to T6, SP1 to SP4" @@ -2055,6 +2091,16 @@ "help": "When the local time exceeds the given value, disable all event tasks. '2020-01-01 00:00:00' means no limit and the time will be reset once it's triggered\nThis can prevent the occurrence of forgetting to disable event tasks after the event ends" } }, + "KeepOil": { + "_info": { + "name": "KeepOil._info.name", + "help": "KeepOil._info.help" + }, + "TimeLimit": { + "name": "KeepOil.TimeLimit.name", + "help": "KeepOil.TimeLimit.help" + } + }, "TaskBalancer": { "_info": { "name": "Task Balancer Settings", @@ -2073,7 +2119,10 @@ "help": "Reminder: Players need to check task config before running, or TaskCall may not work.", "Main": "Main", "Main2": "Main-2", - "Main3": "Main-3" + "Main3": "Main-3", + "Main4": "Main4", + "Main5": "Main5", + "Main6": "Main6" } }, "EventDaily": { @@ -2569,6 +2618,10 @@ "name": "Guild Shop Settings", "help": "" }, + "Enable": { + "name": "GuildShop.Enable.name", + "help": "GuildShop.Enable.help" + }, "Refresh": { "name": "Allow Shop Refresh", "help": "Refreshing will consume 50 guild coins, these are not valuable and it is recommended to have this enabled" @@ -2682,6 +2735,10 @@ "name": "Medal Shop Settings", "help": "" }, + "Enable": { + "name": "MedalShop2.Enable.name", + "help": "MedalShop2.Enable.help" + }, "Filter": { "name": "Item Filter", "help": "All options have been defined at \nDifferent from other shops, the below select options assist with filling the unknowns for the vague items 'Retrofit' and 'Plate'\nFurthermore restricted for 'Plate', there are both specific and wild types\nIf you are targeting a specific type then use a string combination such as 'PlateGeneralT3 > PlateWildT3' otherwise 'PlateT3' will purchase every available T3 Plate\nFor research blueprints it is adviseable to use 'DR > PR', players should convert surplus into Prototype Core currency" @@ -2743,6 +2800,10 @@ "name": "Merit Shop Settings", "help": "" }, + "Enable": { + "name": "MeritShop.Enable.name", + "help": "MeritShop.Enable.help" + }, "Refresh": { "name": "Allow Shop Refresh", "help": "Refreshing will consume 50 gems" @@ -2757,6 +2818,10 @@ "name": "Core Shop Settings", "help": "" }, + "Enable": { + "name": "CoreShop.Enable.name", + "help": "CoreShop.Enable.help" + }, "Filter": { "name": "Item Filter", "help": "All options have been defined at \nHowever unlike other shops, only Chip and Array are supported\nALAS does not browse, scroll, or recognize any other items displayed besides those two" @@ -4028,6 +4093,86 @@ "help": "InstanceRestart.HasRestarted.help" } }, + "ExitWhenMaintenance": { + "_info": { + "name": "ExitWhenMaintenance._info.name", + "help": "ExitWhenMaintenance._info.help" + }, + "Enable": { + "name": "ExitWhenMaintenance.Enable.name", + "help": "ExitWhenMaintenance.Enable.help" + }, + "Notify": { + "name": "ExitWhenMaintenance.Notify.name", + "help": "ExitWhenMaintenance.Notify.help" + } + }, + "Boss": { + "_info": { + "name": "Boss._info.name", + "help": "Boss._info.help" + }, + "Name": { + "name": "Boss.Name.name", + "help": "Boss.Name.help" + }, + "Account": { + "name": "Boss.Account.name", + "help": "Boss.Account.help" + }, + "Password": { + "name": "Boss.Password.name", + "help": "Boss.Password.help" + }, + "SecondPassword": { + "name": "Boss.SecondPassword.name", + "help": "Boss.SecondPassword.help" + } + }, + "OutDate": { + "_info": { + "name": "OutDate._info.name", + "help": "OutDate._info.help" + }, + "TimeLimit": { + "name": "OutDate.TimeLimit.name", + "help": "OutDate.TimeLimit.help" + } + }, + "Comment": { + "_info": { + "name": "Comment._info.name", + "help": "Comment._info.help" + }, + "Content": { + "name": "Comment.Content.name", + "help": "Comment.Content.help" + } + }, + "OthersLogin": { + "_info": { + "name": "OthersLogin._info.name", + "help": "OthersLogin._info.help" + }, + "Enable": { + "name": "OthersLogin.Enable.name", + "help": "OthersLogin.Enable.help" + }, + "Method": { + "name": "OthersLogin.Method.name", + "help": "OthersLogin.Method.help", + "stay_there": "stay_there", + "close_game": "close_game" + }, + "Interval": { + "name": "OthersLogin.Interval.name", + "help": "OthersLogin.Interval.help" + }, + "Notify": { + "name": "OthersLogin.Notify.name", + "help": "OthersLogin.Notify.help" + } + }, "Storage": { "_info": { "name": "Task status", @@ -4060,6 +4205,7 @@ "ClickToUpdate": "Click to update", "RetryUpdate": "Retry update", "CancelUpdate": "Cancel update", + "OneClickStop": "Gui.Button.OneClickStop", "OneClickClear": "Gui.Button.OneClickClear", "Confirm": "Gui.Button.Confirm", "Cancel": "Gui.Button.Cancel" diff --git a/module/config/i18n/ja-JP.json b/module/config/i18n/ja-JP.json index 7870a4016..70616d55d 100644 --- a/module/config/i18n/ja-JP.json +++ b/module/config/i18n/ja-JP.json @@ -50,6 +50,14 @@ "name": "再起動設定", "help": "" }, + "OthersLogin": { + "name": "Task.OthersLogin.name", + "help": "Task.OthersLogin.help" + }, + "Remark": { + "name": "Task.Remark.name", + "help": "Task.Remark.help" + }, "Hook": { "name": "Task.Hook.name", "help": "Task.Hook.help" @@ -66,6 +74,18 @@ "name": "メイン海域-3", "help": "" }, + "Main4": { + "name": "Task.Main4.name", + "help": "Task.Main4.help" + }, + "Main5": { + "name": "Task.Main5.name", + "help": "Task.Main5.help" + }, + "Main6": { + "name": "Task.Main6.name", + "help": "Task.Main6.help" + }, "GemsFarming": { "name": "Commission Farming", "help": "" @@ -114,14 +134,22 @@ "name": "Task.Event3.name", "help": "Task.Event3.help" }, + "Event4": { + "name": "Task.Event4.name", + "help": "Task.Event4.help" + }, + "Event5": { + "name": "Task.Event5.name", + "help": "Task.Event5.help" + }, + "Event6": { + "name": "Task.Event6.name", + "help": "Task.Event6.help" + }, "Raid": { "name": "Raid", "help": "" }, - "Hospital": { - "name": "病院探訪", - "help": "" - }, "Coalition": { "name": "リトル学園", "help": "" @@ -533,6 +561,10 @@ "name": "Error.SaveError.name", "help": "Error.SaveError.help" }, + "SaveConfig": { + "name": "Error.SaveConfig.name", + "help": "Error.SaveConfig.help" + }, "OnePushConfig": { "name": "Error.OnePushConfig.name", "help": "Error.OnePushConfig.help" @@ -1102,6 +1134,10 @@ "threat_safe": "threat_safe", "threat_safe_without_3_stars": "threat_safe_without_3_stars" }, + "StopBarrier": { + "name": "StopCondition.StopBarrier.name", + "help": "StopCondition.StopBarrier.help" + }, "StageIncrease": { "name": "StopCondition.StageIncrease.name", "help": "StopCondition.StageIncrease.help" @@ -2055,6 +2091,16 @@ "help": "EventGeneral.TimeLimit.help" } }, + "KeepOil": { + "_info": { + "name": "KeepOil._info.name", + "help": "KeepOil._info.help" + }, + "TimeLimit": { + "name": "KeepOil.TimeLimit.name", + "help": "KeepOil.TimeLimit.help" + } + }, "TaskBalancer": { "_info": { "name": "TaskBalancer._info.name", @@ -2073,7 +2119,10 @@ "help": "TaskBalancer.TaskCall.help", "Main": "Main", "Main2": "Main2", - "Main3": "Main3" + "Main3": "Main3", + "Main4": "Main4", + "Main5": "Main5", + "Main6": "Main6" } }, "EventDaily": { @@ -2569,6 +2618,10 @@ "name": "GuildShop._info.name", "help": "GuildShop._info.help" }, + "Enable": { + "name": "GuildShop.Enable.name", + "help": "GuildShop.Enable.help" + }, "Refresh": { "name": "GuildShop.Refresh.name", "help": "GuildShop.Refresh.help" @@ -2682,6 +2735,10 @@ "name": "MedalShop._info.name", "help": "MedalShop._info.help" }, + "Enable": { + "name": "MedalShop2.Enable.name", + "help": "MedalShop2.Enable.help" + }, "Filter": { "name": "MedalShop.Filter.name", "help": "MedalShop.Filter.help" @@ -2743,6 +2800,10 @@ "name": "MeritShop._info.name", "help": "MeritShop._info.help" }, + "Enable": { + "name": "MeritShop.Enable.name", + "help": "MeritShop.Enable.help" + }, "Refresh": { "name": "MeritShop.Refresh.name", "help": "MeritShop.Refresh.help" @@ -2757,6 +2818,10 @@ "name": "CoreShop._info.name", "help": "CoreShop._info.help" }, + "Enable": { + "name": "CoreShop.Enable.name", + "help": "CoreShop.Enable.help" + }, "Filter": { "name": "CoreShop.Filter.name", "help": "CoreShop.Filter.help" @@ -4028,6 +4093,86 @@ "help": "InstanceRestart.HasRestarted.help" } }, + "ExitWhenMaintenance": { + "_info": { + "name": "ExitWhenMaintenance._info.name", + "help": "ExitWhenMaintenance._info.help" + }, + "Enable": { + "name": "ExitWhenMaintenance.Enable.name", + "help": "ExitWhenMaintenance.Enable.help" + }, + "Notify": { + "name": "ExitWhenMaintenance.Notify.name", + "help": "ExitWhenMaintenance.Notify.help" + } + }, + "Boss": { + "_info": { + "name": "Boss._info.name", + "help": "Boss._info.help" + }, + "Name": { + "name": "Boss.Name.name", + "help": "Boss.Name.help" + }, + "Account": { + "name": "Boss.Account.name", + "help": "Boss.Account.help" + }, + "Password": { + "name": "Boss.Password.name", + "help": "Boss.Password.help" + }, + "SecondPassword": { + "name": "Boss.SecondPassword.name", + "help": "Boss.SecondPassword.help" + } + }, + "OutDate": { + "_info": { + "name": "OutDate._info.name", + "help": "OutDate._info.help" + }, + "TimeLimit": { + "name": "OutDate.TimeLimit.name", + "help": "OutDate.TimeLimit.help" + } + }, + "Comment": { + "_info": { + "name": "Comment._info.name", + "help": "Comment._info.help" + }, + "Content": { + "name": "Comment.Content.name", + "help": "Comment.Content.help" + } + }, + "OthersLogin": { + "_info": { + "name": "OthersLogin._info.name", + "help": "OthersLogin._info.help" + }, + "Enable": { + "name": "OthersLogin.Enable.name", + "help": "OthersLogin.Enable.help" + }, + "Method": { + "name": "OthersLogin.Method.name", + "help": "OthersLogin.Method.help", + "stay_there": "stay_there", + "close_game": "close_game" + }, + "Interval": { + "name": "OthersLogin.Interval.name", + "help": "OthersLogin.Interval.help" + }, + "Notify": { + "name": "OthersLogin.Notify.name", + "help": "OthersLogin.Notify.help" + } + }, "Storage": { "_info": { "name": "Storage._info.name", @@ -4060,6 +4205,7 @@ "ClickToUpdate": "アップデータ実行", "RetryUpdate": "アップデータ再試行", "CancelUpdate": "アップデータ中止", + "OneClickStop": "Gui.Button.OneClickStop", "OneClickClear": "Gui.Button.OneClickClear", "Confirm": "Gui.Button.Confirm", "Cancel": "Gui.Button.Cancel" diff --git a/module/config/i18n/zh-CN.json b/module/config/i18n/zh-CN.json index ee83dd334..5bf4e0359 100644 --- a/module/config/i18n/zh-CN.json +++ b/module/config/i18n/zh-CN.json @@ -50,12 +50,20 @@ "name": "重启设置", "help": "" }, + "OthersLogin": { + "name": "顶号检测", + "help": "" + }, + "Remark": { + "name": "备注", + "help": "" + }, "Hook": { "name": "Hook", "help": "" }, "Main": { - "name": "主线图", + "name": "主线图-1", "help": "" }, "Main2": { @@ -66,6 +74,18 @@ "name": "主线图-3", "help": "" }, + "Main4": { + "name": "主线图-4", + "help": "" + }, + "Main5": { + "name": "主线图-5", + "help": "" + }, + "Main6": { + "name": "主线图-6", + "help": "" + }, "GemsFarming": { "name": "刷紧急委托", "help": "" @@ -103,7 +123,7 @@ "help": "" }, "Event": { - "name": "活动图", + "name": "活动图-1", "help": "" }, "Event2": { @@ -114,12 +134,20 @@ "name": "活动图-3", "help": "" }, - "Raid": { - "name": "共斗活动", + "Event4": { + "name": "活动图-4", "help": "" }, - "Hospital": { - "name": "深谷来信", + "Event5": { + "name": "活动图-5", + "help": "" + }, + "Event6": { + "name": "活动图-6", + "help": "" + }, + "Raid": { + "name": "共斗活动", "help": "" }, "Coalition": { @@ -533,6 +561,10 @@ "name": "出错时,保存 Log 和截图", "help": "" }, + "SaveConfig": { + "name": "出错时,保存当前配置", + "help": "" + }, "OnePushConfig": { "name": "错误推送设置", "help": "发生无法处理的异常后,使用 Onepush 推送一条错误信息。配置方法见文档:https://github.com/LmeSzinc/AzurLaneAutoScript/wiki/Onepush-configuration-%5BCN%5D" @@ -1102,6 +1134,10 @@ "threat_safe": "100%通关 + 三星 + 安全海域", "threat_safe_without_3_stars": "100%通关 + 安全海域" }, + "StopBarrier": { + "name": "开荒完 X 关停止", + "help": "设置为1-1则为不启用,清空后重置为1-1" + }, "StageIncrease": { "name": "达成关卡成就后向前开荒", "help": "自动开荒,需要保证队伍有足够的强度,需要保证队伍满足关卡属性限制,并设置\"达成关卡成就后停止\"\n例如,打开本选项,并选择\"地图通关\",将在关卡100%通关后前往下一关卡\n支持自动开荒的地图:1-1至15-4,A1至A3,B1至B3,C1至C3,D1至D3,T1至T6,SP1至SP4" @@ -2055,6 +2091,16 @@ "help": "当本地时间超过给定数值后,禁用所有活动任务,'2020-01-01 00:00:00' 表示不限制,触发一次后时间将被重置\n设置后能防止活动结束后忘记关闭任务的事情发生" } }, + "KeepOil": { + "_info": { + "name": "活动攒油", + "help": "" + }, + "TimeLimit": { + "name": "时间限制", + "help": "当本地时间超过给定数值后,禁用除耗油日常之外的耗油项目,'2020-01-01 00:00:00' 表示不限制,触发一次后时间将被重置\n设置后能自动取消耗油项目来实现给活动攒油" + } + }, "TaskBalancer": { "_info": { "name": "任务平衡设置", @@ -2071,9 +2117,12 @@ "TaskCall": { "name": "物资过低时呼叫任务X", "help": "提醒: 玩家需提前设置好被调用的任务,否则将不会作用", - "Main": "主线图", + "Main": "主线图-1", "Main2": "主线图-2", - "Main3": "主线图-3" + "Main3": "主线图-3", + "Main4": "主线图-4", + "Main5": "主线图-5", + "Main6": "主线图-6" } }, "EventDaily": { @@ -2569,6 +2618,10 @@ "name": "舰队商店", "help": "" }, + "Enable": { + "name": "购买该商店", + "help": "" + }, "Refresh": { "name": "刷新商店", "help": "刷新需要消耗50舰队币,舰队币不值钱,建议打开" @@ -2682,6 +2735,10 @@ "name": "功勋商店(退役兑换)", "help": "" }, + "Enable": { + "name": "购买该商店", + "help": "" + }, "Filter": { "name": "商店过滤器", "help": "" @@ -2743,6 +2800,10 @@ "name": "军需商店(演习商店)", "help": "" }, + "Enable": { + "name": "购买该商店", + "help": "" + }, "Refresh": { "name": "刷新商店", "help": "刷新需要消耗20钻石" @@ -2757,6 +2818,10 @@ "name": "核心兑换", "help": "" }, + "Enable": { + "name": "购买该商店", + "help": "" + }, "Filter": { "name": "商店过滤器", "help": "" @@ -4028,6 +4093,86 @@ "help": "InstanceRestart.HasRestarted.help" } }, + "ExitWhenMaintenance": { + "_info": { + "name": "游戏维护时退出", + "help": "" + }, + "Enable": { + "name": "启用", + "help": "" + }, + "Notify": { + "name": "Onepush通知", + "help": "" + } + }, + "Boss": { + "_info": { + "name": "账号信息", + "help": "" + }, + "Name": { + "name": "名称", + "help": "" + }, + "Account": { + "name": "账号", + "help": "" + }, + "Password": { + "name": "密码", + "help": "" + }, + "SecondPassword": { + "name": "二级密码", + "help": "" + } + }, + "OutDate": { + "_info": { + "name": "单子", + "help": "" + }, + "TimeLimit": { + "name": "过期时限", + "help": "当时间超过设定时间后就会停止并且邮件通知,清空后重置为2020-01-01 00:00:00" + } + }, + "Comment": { + "_info": { + "name": "其他信息", + "help": "" + }, + "Content": { + "name": "", + "help": "" + } + }, + "OthersLogin": { + "_info": { + "name": "设置", + "help": "" + }, + "Enable": { + "name": "启用", + "help": "该功能启用之后会将'Alas设置-优化设置-当任务队列清空后'自动强制设置为'关闭游戏'" + }, + "Method": { + "name": "顶号后操作", + "help": "", + "stay_there": "停留在原处", + "close_game": "关闭游戏" + }, + "Interval": { + "name": "任务间隔(分)", + "help": "顶号之后将任务推迟多久" + }, + "Notify": { + "name": "OnePush通知", + "help": "顶号之后通知,强烈建议开启" + } + }, "Storage": { "_info": { "name": "任务状态", @@ -4060,6 +4205,7 @@ "ClickToUpdate": "进行更新", "RetryUpdate": "重试更新", "CancelUpdate": "取消更新", + "OneClickStop": "一键停止所有", "OneClickClear": "清空任务", "Confirm": "确认", "Cancel": "取消" diff --git a/module/config/i18n/zh-TW.json b/module/config/i18n/zh-TW.json index ac73941f4..c2ee749f3 100644 --- a/module/config/i18n/zh-TW.json +++ b/module/config/i18n/zh-TW.json @@ -50,6 +50,14 @@ "name": "重啟設定", "help": "" }, + "OthersLogin": { + "name": "Task.OthersLogin.name", + "help": "Task.OthersLogin.help" + }, + "Remark": { + "name": "Task.Remark.name", + "help": "Task.Remark.help" + }, "Hook": { "name": "Task.Hook.name", "help": "Task.Hook.help" @@ -66,6 +74,18 @@ "name": "主線圖-3", "help": "" }, + "Main4": { + "name": "Task.Main4.name", + "help": "Task.Main4.help" + }, + "Main5": { + "name": "Task.Main5.name", + "help": "Task.Main5.help" + }, + "Main6": { + "name": "Task.Main6.name", + "help": "Task.Main6.help" + }, "GemsFarming": { "name": "刷緊急委託", "help": "" @@ -114,14 +134,22 @@ "name": "活動圖-3", "help": "" }, + "Event4": { + "name": "Task.Event4.name", + "help": "Task.Event4.help" + }, + "Event5": { + "name": "Task.Event5.name", + "help": "Task.Event5.help" + }, + "Event6": { + "name": "Task.Event6.name", + "help": "Task.Event6.help" + }, "Raid": { "name": "共鬥活動", "help": "" }, - "Hospital": { - "name": "深谷来信", - "help": "" - }, "Coalition": { "name": "極地風暴", "help": "" @@ -533,6 +561,10 @@ "name": "出錯時,保存 Log 和截圖", "help": "" }, + "SaveConfig": { + "name": "Error.SaveConfig.name", + "help": "Error.SaveConfig.help" + }, "OnePushConfig": { "name": "錯誤推送設定", "help": "發生無法處理的異常後,使用 Onepush 推送错误消息。設定參考文檔:https://github.com/LmeSzinc/AzurLaneAutoScript/wiki/Onepush-configuration-%5BCN%5D" @@ -1102,6 +1134,10 @@ "threat_safe": "100%通關 + 三星 + 安全海域", "threat_safe_without_3_stars": "100%通關 + 安全海域" }, + "StopBarrier": { + "name": "StopCondition.StopBarrier.name", + "help": "StopCondition.StopBarrier.help" + }, "StageIncrease": { "name": "達成地圖成就後前往下一關卡,不停止", "help": "自動開荒,需要保證隊伍有足夠的強度,及地圖屬性限制,並設定\"達成地圖成就後停止\"\n例如,打開本功能,並選擇\"地圖 100% 通關\",將在地圖100%通關後前往下一關卡\n支援自動開荒的地圖:1-1至14-4、A1至A3、B1至B3、C1至C3、D1至D3、T1至T6、SP1至SP4" @@ -2055,6 +2091,16 @@ "help": "當本地時間超過給定數值後,禁用所有活動任務,'2020-01-01 00:00:00' 表示不限制,觸發一次後時間將被重置\n設定後能防止活動結束後忘記關閉任務的事情發生" } }, + "KeepOil": { + "_info": { + "name": "KeepOil._info.name", + "help": "KeepOil._info.help" + }, + "TimeLimit": { + "name": "KeepOil.TimeLimit.name", + "help": "KeepOil.TimeLimit.help" + } + }, "TaskBalancer": { "_info": { "name": "任務平衡設定", @@ -2073,7 +2119,10 @@ "help": "提醒: 玩家需提前設定好被調用的任務,否則將不會作用", "Main": "主線圖", "Main2": "主線圖-2", - "Main3": "主線圖-3" + "Main3": "主線圖-3", + "Main4": "Main4", + "Main5": "Main5", + "Main6": "Main6" } }, "EventDaily": { @@ -2569,6 +2618,10 @@ "name": "艦隊商店", "help": "" }, + "Enable": { + "name": "GuildShop.Enable.name", + "help": "GuildShop.Enable.help" + }, "Refresh": { "name": "刷新艦隊商店", "help": "需要消耗50艦隊幣,艦隊幣不值錢,建議打開" @@ -2682,6 +2735,10 @@ "name": "功勳商店(退役兌換)", "help": "" }, + "Enable": { + "name": "MedalShop2.Enable.name", + "help": "MedalShop2.Enable.help" + }, "Filter": { "name": "商店過濾器", "help": "" @@ -2743,6 +2800,10 @@ "name": "軍需商店 (演習商店)", "help": "" }, + "Enable": { + "name": "MeritShop.Enable.name", + "help": "MeritShop.Enable.help" + }, "Refresh": { "name": "刷新軍需商店", "help": "需要消耗20鑽石" @@ -2757,6 +2818,10 @@ "name": "核心兌換", "help": "" }, + "Enable": { + "name": "CoreShop.Enable.name", + "help": "CoreShop.Enable.help" + }, "Filter": { "name": "商店過濾器", "help": "" @@ -4028,6 +4093,86 @@ "help": "InstanceRestart.HasRestarted.help" } }, + "ExitWhenMaintenance": { + "_info": { + "name": "ExitWhenMaintenance._info.name", + "help": "ExitWhenMaintenance._info.help" + }, + "Enable": { + "name": "ExitWhenMaintenance.Enable.name", + "help": "ExitWhenMaintenance.Enable.help" + }, + "Notify": { + "name": "ExitWhenMaintenance.Notify.name", + "help": "ExitWhenMaintenance.Notify.help" + } + }, + "Boss": { + "_info": { + "name": "Boss._info.name", + "help": "Boss._info.help" + }, + "Name": { + "name": "Boss.Name.name", + "help": "Boss.Name.help" + }, + "Account": { + "name": "Boss.Account.name", + "help": "Boss.Account.help" + }, + "Password": { + "name": "Boss.Password.name", + "help": "Boss.Password.help" + }, + "SecondPassword": { + "name": "Boss.SecondPassword.name", + "help": "Boss.SecondPassword.help" + } + }, + "OutDate": { + "_info": { + "name": "OutDate._info.name", + "help": "OutDate._info.help" + }, + "TimeLimit": { + "name": "OutDate.TimeLimit.name", + "help": "OutDate.TimeLimit.help" + } + }, + "Comment": { + "_info": { + "name": "Comment._info.name", + "help": "Comment._info.help" + }, + "Content": { + "name": "Comment.Content.name", + "help": "Comment.Content.help" + } + }, + "OthersLogin": { + "_info": { + "name": "OthersLogin._info.name", + "help": "OthersLogin._info.help" + }, + "Enable": { + "name": "OthersLogin.Enable.name", + "help": "OthersLogin.Enable.help" + }, + "Method": { + "name": "OthersLogin.Method.name", + "help": "OthersLogin.Method.help", + "stay_there": "stay_there", + "close_game": "close_game" + }, + "Interval": { + "name": "OthersLogin.Interval.name", + "help": "OthersLogin.Interval.help" + }, + "Notify": { + "name": "OthersLogin.Notify.name", + "help": "OthersLogin.Notify.help" + } + }, "Storage": { "_info": { "name": "任務狀態", @@ -4060,6 +4205,7 @@ "ClickToUpdate": "進行更新", "RetryUpdate": "重試更新", "CancelUpdate": "取消更新", + "OneClickStop": "Gui.Button.OneClickStop", "OneClickClear": "Gui.Button.OneClickClear", "Confirm": "Gui.Button.Confirm", "Cancel": "Gui.Button.Cancel" diff --git a/module/device/assets.py b/module/device/assets.py new file mode 100644 index 000000000..bb82f38fd --- /dev/null +++ b/module/device/assets.py @@ -0,0 +1,8 @@ +from module.base.button import Button +from module.base.template import Template + +# This file was automatically generated by dev_tools/button_extract.py. +# Don't modify it manually. + +OTHERS_LOGIN_CONFIRM = Button(area={'cn': (561, 488, 721, 534), 'en': (561, 488, 721, 534), 'jp': (561, 488, 721, 534), 'tw': (561, 488, 721, 534)}, color={'cn': (100, 147, 205), 'en': (100, 147, 205), 'jp': (100, 147, 205), 'tw': (100, 147, 205)}, button={'cn': (561, 488, 721, 534), 'en': (561, 488, 721, 534), 'jp': (561, 488, 721, 534), 'tw': (561, 488, 721, 534)}, file={'cn': './assets/cn/device/OTHERS_LOGIN_CONFIRM.png', 'en': './assets/cn/device/OTHERS_LOGIN_CONFIRM.png', 'jp': './assets/cn/device/OTHERS_LOGIN_CONFIRM.png', 'tw': './assets/cn/device/OTHERS_LOGIN_CONFIRM.png'}) +OTHERS_LOGIN_NOTIFY = Button(area={'cn': (664, 330, 712, 360), 'en': (664, 330, 712, 360), 'jp': (519, 332, 570, 361), 'tw': (664, 330, 712, 360)}, color={'cn': (144, 149, 160), 'en': (144, 149, 160), 'jp': (141, 146, 156), 'tw': (144, 149, 160)}, button={'cn': (664, 330, 712, 360), 'en': (664, 330, 712, 360), 'jp': (519, 332, 570, 361), 'tw': (664, 330, 712, 360)}, file={'cn': './assets/cn/device/OTHERS_LOGIN_NOTIFY.png', 'en': './assets/cn/device/OTHERS_LOGIN_NOTIFY.png', 'jp': './assets/jp/device/OTHERS_LOGIN_NOTIFY.png', 'tw': './assets/cn/device/OTHERS_LOGIN_NOTIFY.png'}) diff --git a/module/device/device.py b/module/device/device.py index 8efbacde1..27d82d4cd 100644 --- a/module/device/device.py +++ b/module/device/device.py @@ -6,13 +6,16 @@ from lxml import etree from module.device.env import IS_WINDOWS # Patch pkg_resources before importing adbutils and uiautomator2 from module.device.pkg_resources import get_distribution +from module.ocr.ocr import Ocr # Just avoid being removed by import optimization _ = get_distribution from module.base.timer import Timer from module.config.utils import get_server_next_update +from module.config.deep import deep_get from module.device.app_control import AppControl +from module.device.assets import OTHERS_LOGIN_CONFIRM, OTHERS_LOGIN_NOTIFY from module.device.control import Control from module.device.screenshot import Screenshot from module.exception import ( @@ -20,10 +23,17 @@ from module.exception import ( GameNotRunningError, GameStuckError, GameTooManyClickError, - RequestHumanTakeover + RequestHumanTakeover, OthersLogin ) from module.handler.assets import GET_MISSION from module.logger import logger +from module.ocr.ocr import Ocr + +OthersLoginNotifyOcr = Ocr(buttons=OTHERS_LOGIN_NOTIFY, lang="cnocr") +OTHERS_LOGIN_NOTIFY_SERVER = { + "cn": "登录", + "jp": "蜴所" +} def show_function_call(): @@ -205,6 +215,12 @@ class Device(Screenshot, Control, AppControl): if self.handle_night_commission(): super().screenshot() + if deep_get(self.config.data, "OthersLogin.OthersLogin.Enable"): + if OTHERS_LOGIN_CONFIRM.appear_on(self.image): + if self.config.SERVER in OTHERS_LOGIN_NOTIFY_SERVER.keys(): + if OthersLoginNotifyOcr.ocr(self.image) == OTHERS_LOGIN_NOTIFY_SERVER[self.config.SERVER]: + raise OthersLogin + return self.image def dump_hierarchy(self) -> etree._Element: diff --git a/module/exception.py b/module/exception.py index 668ba7c2f..982f011ae 100644 --- a/module/exception.py +++ b/module/exception.py @@ -66,9 +66,11 @@ class RequestHumanTakeover(Exception): class AutoSearchSetError(Exception): pass - class RequireRestartGame(Exception): pass class CrackerError(Exception): - pass \ No newline at end of file + pass + +class OthersLogin(Exception): + pass diff --git a/module/raid/raid.py b/module/raid/raid.py index 11520221f..b870c759f 100644 --- a/module/raid/raid.py +++ b/module/raid/raid.py @@ -16,6 +16,10 @@ from module.ui.assets import RAID_CHECK from module.ui.page import page_rpg_stage +class OilExhausted(Exception): + pass + + class RaidCounter(DigitCounter): def pre_process(self, image): image = super().pre_process(image) diff --git a/module/shop/shop_reward.py b/module/shop/shop_reward.py index e92c4f7a4..d6c8414be 100644 --- a/module/shop/shop_reward.py +++ b/module/shop/shop_reward.py @@ -6,7 +6,7 @@ from module.shop.shop_merit import MeritShop from module.shop.ui import ShopUI from module.shop_event.shop_event import EventShop from module.shop_event.ui import OCR_EVENT_SHOP_SECOND_ENSURE - +from module.config.deep import deep_get, deep_set class RewardShop(ShopUI): def run_frequent(self): @@ -21,32 +21,26 @@ class RewardShop(ShopUI): def run_once(self): # Munitions shops - if self.config.EventShop_Enable: - self.ui_goto_event_shop() - if self.shop_tab.get_active(main=self) == 2: - EventShop(self.config, self.device).run() - text = OCR_EVENT_SHOP_SECOND_ENSURE.ocr(self.device.image) - if text != "": - self.shop_nav.set(main=self, upper=2) - EventShop(self.config, self.device).run() - else: - self.ui_goto_shop() + self.ui_goto_shop() - self.shop_tab.set(main=self, left=2) - self.shop_nav.set(main=self, upper=2) - MeritShop(self.config, self.device).run() + if deep_get(self.config.data, "ShopOnce.MeritShop.Enable"): + self.shop_tab.set(main=self, left=2) + self.shop_nav.set(main=self, upper=2) + MeritShop(self.config, self.device).run() - self.shop_tab.set(main=self, left=2) - self.shop_nav.set(main=self, upper=3) - GuildShop(self.config, self.device).run() + if deep_get(self.config.data, "ShopOnce.GuildShop.Enable"): + self.shop_tab.set(main=self, left=2) + self.shop_nav.set(main=self, upper=3) + GuildShop(self.config, self.device).run() - # core limited, core monthly, medal, prototype - self.shop_tab.set(main=self, left=1) - self.shop_nav.set(main=self, upper=2) - CoreShop(self.config, self.device).run() + if deep_get(self.config.data, "ShopOnce.CoreShop.Enable"): + self.shop_tab.set(main=self, left=1) + self.shop_nav.set(main=self, upper=2) + CoreShop(self.config, self.device).run() - self.shop_tab.set(main=self, left=1) - self.shop_nav.set(main=self, upper=3) - MedalShop2(self.config, self.device).run() + if deep_get(self.config.data, "ShopOnce.MedalShop2.Enable"): + self.shop_tab.set(main=self, left=1) + self.shop_nav.set(main=self, upper=3) + MedalShop2(self.config, self.device).run() self.config.task_delay(server_update=True)