Skip to content

Commit

Permalink
More suggested changes
Browse files Browse the repository at this point in the history
  • Loading branch information
TRPG0 committed Aug 10, 2024
1 parent aff47ca commit 8b648ea
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 10 deletions.
4 changes: 2 additions & 2 deletions worlds/blasphemous/Items.py
Original file line number Diff line number Diff line change
Expand Up @@ -739,7 +739,7 @@ class ItemDict(TypedDict):
"Broken Left Eye of the Traitor"}
}

tears_set: Set[str] = {
tears_list: List[str] = [
"Tears of Atonement (500)",
"Tears of Atonement (625)",
"Tears of Atonement (750)",
Expand All @@ -760,7 +760,7 @@ class ItemDict(TypedDict):
"Tears of Atonement (11250)",
"Tears of Atonement (18000)",
"Tears of Atonement (30000)"
}
]

reliquary_set: Set[str] = {
"Reliquary of the Fervent Heart",
Expand Down
13 changes: 5 additions & 8 deletions worlds/blasphemous/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
from collections import Counter
from BaseClasses import Region, Location, Item, Tutorial, ItemClassification
from worlds.AutoWorld import World, WebWorld
from .Items import base_id, item_table, group_table, tears_set, reliquary_set
from .Items import base_id, item_table, group_table, tears_list, reliquary_set
from .Locations import location_names
from .Rules import BlasRules
from worlds.generic.Rules import set_rule
Expand Down Expand Up @@ -61,7 +61,7 @@ def create_event(self, event: str):


def get_filler_item_name(self) -> str:
return self.random.choice(tears_set)
return self.random.choice(tears_list)


def generate_early(self):
Expand Down Expand Up @@ -211,8 +211,7 @@ def pre_fill(self):
self.place_items_from_set(thorn_set, "Thorn Upgrade")

if self.options.start_wheel:
self.multiworld.get_location("Beginning gift", self.player)\
.place_locked_item(self.create_item("The Young Mason's Wheel"))
self.get_location("Beginning gift").place_locked_item(self.create_item("The Young Mason's Wheel"))

if not self.options.skill_randomizer:
self.place_items_from_dict(skill_dict)
Expand All @@ -223,14 +222,12 @@ def pre_fill(self):

def place_items_from_set(self, location_set: Set[str], name: str):
for loc in location_set:
self.multiworld.get_location(loc, self.player)\
.place_locked_item(self.create_item(name))
self.get_location(loc).place_locked_item(self.create_item(name))


def place_items_from_dict(self, option_dict: Dict[str, str]):
for loc, item in option_dict.items():
self.multiworld.get_location(loc, self.player)\
.place_locked_item(self.create_item(item))
self.get_location(loc).place_locked_item(self.create_item(item))


def create_regions(self) -> None:
Expand Down

0 comments on commit 8b648ea

Please sign in to comment.