The Messenger: Make modules and tests PEP8 (#2276)

* The Messenger: PEP8 module and test names

* fix dumb

* whitespace
This commit is contained in:
Aaron Wagener
2023-10-08 07:33:39 -05:00
committed by GitHub
parent cc2247bfa0
commit 6f9484f375
13 changed files with 65 additions and 71 deletions

View File

@@ -1,14 +1,14 @@
import logging
from typing import Dict, Any, List, Optional
from typing import Any, Dict, List, Optional
from BaseClasses import Tutorial, ItemClassification, CollectionState, Item, MultiWorld
from worlds.AutoWorld import World, WebWorld
from .Constants import NOTES, PHOBEKINS, ALL_ITEMS, ALWAYS_LOCATIONS, BOSS_LOCATIONS, FILLER
from .Options import messenger_options, NotesNeeded, Goal, PowerSeals, Logic
from .Regions import REGIONS, REGION_CONNECTIONS, SEALS, MEGA_SHARDS
from .Shop import SHOP_ITEMS, shuffle_shop_prices, FIGURINES
from .SubClasses import MessengerRegion, MessengerItem
from . import Rules
from BaseClasses import CollectionState, Item, ItemClassification, Tutorial
from worlds.AutoWorld import WebWorld, World
from .constants import ALL_ITEMS, ALWAYS_LOCATIONS, BOSS_LOCATIONS, FILLER, NOTES, PHOBEKINS
from .options import Goal, Logic, NotesNeeded, PowerSeals, messenger_options
from .regions import MEGA_SHARDS, REGIONS, REGION_CONNECTIONS, SEALS
from .rules import MessengerHardRules, MessengerOOBRules, MessengerRules
from .shop import FIGURINES, SHOP_ITEMS, shuffle_shop_prices
from .subclasses import MessengerItem, MessengerRegion
class MessengerWeb(WebWorld):
@@ -68,15 +68,11 @@ class MessengerWorld(World):
total_seals: int = 0
required_seals: int = 0
total_shards: int
total_shards: int = 0
shop_prices: Dict[str, int]
figurine_prices: Dict[str, int]
_filler_items: List[str]
def __init__(self, multiworld: MultiWorld, player: int):
super().__init__(multiworld, player)
self.total_shards = 0
def generate_early(self) -> None:
if self.multiworld.goal[self.player] == Goal.option_power_seal_hunt:
self.multiworld.shuffle_seals[self.player].value = PowerSeals.option_true
@@ -144,11 +140,11 @@ class MessengerWorld(World):
def set_rules(self) -> None:
logic = self.multiworld.logic_level[self.player]
if logic == Logic.option_normal:
Rules.MessengerRules(self).set_messenger_rules()
MessengerRules(self).set_messenger_rules()
elif logic == Logic.option_hard:
Rules.MessengerHardRules(self).set_messenger_rules()
MessengerHardRules(self).set_messenger_rules()
else:
Rules.MessengerOOBRules(self).set_messenger_rules()
MessengerOOBRules(self).set_messenger_rules()
def fill_slot_data(self) -> Dict[str, Any]:
shop_prices = {SHOP_ITEMS[item].internal_name: price for item, price in self.shop_prices.items()}