diff --git a/arknights_mower/__main__.py b/arknights_mower/__main__.py index 591555a5..519f1848 100644 --- a/arknights_mower/__main__.py +++ b/arknights_mower/__main__.py @@ -5,7 +5,8 @@ from evalidate import Expr from arknights_mower import __version__ -from arknights_mower.solvers import ReclamationAlgorithm, SecretFront +from arknights_mower.solvers.reclamation_algorithm import ReclamationAlgorithm +from arknights_mower.solvers.secret_front import SecretFront from arknights_mower.utils import config, path, rapidocr from arknights_mower.utils.csleep import MowerExit from arknights_mower.utils.datetime import format_time @@ -42,7 +43,7 @@ def initialize(tasks, scheduler=None): if scheduler is not None: scheduler.handle_error(True) return scheduler - from arknights_mower.solvers import BaseSchedulerSolver + from arknights_mower.solvers.base_schedule import BaseSchedulerSolver base_scheduler = BaseSchedulerSolver() base_scheduler.operators = {} diff --git a/arknights_mower/solvers/__init__.py b/arknights_mower/solvers/__init__.py index a4a081d3..e69de29b 100644 --- a/arknights_mower/solvers/__init__.py +++ b/arknights_mower/solvers/__init__.py @@ -1,35 +0,0 @@ -from .auto_fight import AutoFight -from .base_schedule import BaseSchedulerSolver -from .credit import CreditSolver -from .credit_fight import CreditFight -from .cultivate_depot import cultivate as cultivateDepotSolver -from .depotREC import depotREC as DepotSolver -from .mail import MailSolver -from .mission import MissionSolver -from .navigation import NavigationSolver -from .operation import OperationSolver -from .reclamation_algorithm import ReclamationAlgorithm -from .recruit import RecruitSolver -from .report import ReportSolver -from .secret_front import SecretFront -from .shop import CreditShop -from .skland import SKLand - -__all__ = [ - "AutoFight", - "BaseSchedulerSolver", - "CreditSolver", - "CreditFight", - "cultivateDepotSolver", - "DepotSolver", - "MailSolver", - "MissionSolver", - "NavigationSolver", - "OperationSolver", - "ReclamationAlgorithm", - "RecruitSolver", - "ReportSolver", - "SecretFront", - "CreditShop", - "SKLand", -] diff --git a/arknights_mower/solvers/base_schedule.py b/arknights_mower/solvers/base_schedule.py index aa079080..08be4c7d 100644 --- a/arknights_mower/solvers/base_schedule.py +++ b/arknights_mower/solvers/base_schedule.py @@ -9,23 +9,21 @@ import cv2 from arknights_mower.data import agent_list, base_room_list -from arknights_mower.solvers import ( - BaseMixin, - CreditFight, - CreditShop, - CreditSolver, - DepotSolver, - MailSolver, - MissionSolver, - NavigationSolver, - OperationSolver, - ReclamationAlgorithm, - RecruitSolver, - ReportSolver, - SecretFront, - SKLand, - cultivateDepotSolver, -) +from arknights_mower.solvers.base_mixin import BaseMixin +from arknights_mower.solvers.credit import CreditSolver +from arknights_mower.solvers.credit_fight import CreditFight +from arknights_mower.solvers.cultivate_depot import cultivate as cultivateDepotSolver +from arknights_mower.solvers.depotREC import depotREC as DepotSolver +from arknights_mower.solvers.mail import MailSolver +from arknights_mower.solvers.mission import MissionSolver +from arknights_mower.solvers.navigation import NavigationSolver +from arknights_mower.solvers.operation import OperationSolver +from arknights_mower.solvers.reclamation_algorithm import ReclamationAlgorithm +from arknights_mower.solvers.recruit import RecruitSolver +from arknights_mower.solvers.report import ReportSolver +from arknights_mower.solvers.secret_front import SecretFront +from arknights_mower.solvers.shop import CreditShop +from arknights_mower.solvers.skland import SKLand from arknights_mower.utils import config, detector, hot_update, rapidocr from arknights_mower.utils import typealias as tp from arknights_mower.utils.csleep import MowerExit, csleep diff --git a/arknights_mower/solvers/credit_fight.py b/arknights_mower/solvers/credit_fight.py index 664bbbd6..dfbf82ae 100644 --- a/arknights_mower/solvers/credit_fight.py +++ b/arknights_mower/solvers/credit_fight.py @@ -1,7 +1,8 @@ import cv2 from scipy.signal import argrelmin -from arknights_mower.solvers import AutoFight, NavigationSolver +from arknights_mower.solvers.auto_fight import AutoFight +from arknights_mower.solvers.navigation import NavigationSolver from arknights_mower.utils import config from arknights_mower.utils.graph import SceneGraphSolver from arknights_mower.utils.image import cropimg, loadres diff --git a/server.py b/server.py index 7406688f..597ecf83 100755 --- a/server.py +++ b/server.py @@ -570,7 +570,7 @@ def test_pushplus_push(): @app.route("/check-skland") @require_token def test_skland(): - from arknights_mower.solvers import SKLand + from arknights_mower.solvers.skland import SKLand return SKLand().test_connect()