Stardew Valley: Fix unresolved reference warning and unused imports (#4360)
* fix unresolved reference warning and unused imports * revert stuff * just a commit to rerun the tests cuz messenger fail
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import typing
|
||||
from typing import Union
|
||||
|
||||
from .base_logic import BaseLogicMixin, BaseLogic
|
||||
from .cooking_logic import CookingLogicMixin
|
||||
from .mine_logic import MineLogicMixin
|
||||
from .received_logic import ReceivedLogicMixin
|
||||
from .region_logic import RegionLogicMixin
|
||||
@@ -13,6 +13,11 @@ from ..strings.region_names import Region
|
||||
from ..strings.skill_names import Skill, ModSkill
|
||||
from ..strings.tool_names import ToolMaterial, Tool
|
||||
|
||||
if typing.TYPE_CHECKING:
|
||||
from ..mods.logic.mod_logic import ModLogicMixin
|
||||
else:
|
||||
ModLogicMixin = object
|
||||
|
||||
|
||||
class AbilityLogicMixin(BaseLogicMixin):
|
||||
def __init__(self, *args, **kwargs):
|
||||
@@ -20,7 +25,8 @@ class AbilityLogicMixin(BaseLogicMixin):
|
||||
self.ability = AbilityLogic(*args, **kwargs)
|
||||
|
||||
|
||||
class AbilityLogic(BaseLogic[Union[AbilityLogicMixin, RegionLogicMixin, ReceivedLogicMixin, ToolLogicMixin, SkillLogicMixin, MineLogicMixin, MagicLogicMixin]]):
|
||||
class AbilityLogic(BaseLogic[Union[AbilityLogicMixin, RegionLogicMixin, ReceivedLogicMixin, ToolLogicMixin, SkillLogicMixin, MineLogicMixin, MagicLogicMixin,
|
||||
ModLogicMixin]]):
|
||||
def can_mine_perfectly(self) -> StardewRule:
|
||||
return self.logic.mine.can_progress_in_the_mines_from_floor(160)
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@ from .has_logic import HasLogicMixin
|
||||
from .received_logic import ReceivedLogicMixin
|
||||
from .region_logic import RegionLogicMixin
|
||||
from .tool_logic import ToolLogicMixin
|
||||
from ..options import ToolProgression
|
||||
from ..stardew_rule import StardewRule, True_
|
||||
from ..strings.generic_names import Generic
|
||||
from ..strings.geode_names import Geode
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import typing
|
||||
from functools import cached_property
|
||||
from typing import Union, Tuple
|
||||
|
||||
@@ -24,6 +25,11 @@ from ..strings.skill_names import Skill, all_mod_skills, all_vanilla_skills
|
||||
from ..strings.tool_names import ToolMaterial, Tool
|
||||
from ..strings.wallet_item_names import Wallet
|
||||
|
||||
if typing.TYPE_CHECKING:
|
||||
from ..mods.logic.mod_logic import ModLogicMixin
|
||||
else:
|
||||
ModLogicMixin = object
|
||||
|
||||
fishing_regions = (Region.beach, Region.town, Region.forest, Region.mountain, Region.island_south, Region.island_west)
|
||||
vanilla_skill_items = ("Farming Level", "Mining Level", "Foraging Level", "Fishing Level", "Combat Level")
|
||||
|
||||
@@ -35,7 +41,7 @@ class SkillLogicMixin(BaseLogicMixin):
|
||||
|
||||
|
||||
class SkillLogic(BaseLogic[Union[HasLogicMixin, ReceivedLogicMixin, RegionLogicMixin, SeasonLogicMixin, TimeLogicMixin, ToolLogicMixin, SkillLogicMixin,
|
||||
CombatLogicMixin, MagicLogicMixin, HarvestingLogicMixin]]):
|
||||
CombatLogicMixin, MagicLogicMixin, HarvestingLogicMixin, ModLogicMixin]]):
|
||||
|
||||
# Should be cached
|
||||
def can_earn_level(self, skill: str, level: int) -> StardewRule:
|
||||
|
||||
Reference in New Issue
Block a user