Skip to content

Commit

Permalink
SoE: fix determinism
Browse files Browse the repository at this point in the history
Fixes randomly placed ingredients not being deterministic (depending on settings)
and in turn also fixes logic not being deterministic if they get replaced by fragments.
  • Loading branch information
black-sliver committed Aug 8, 2024
1 parent 575c338 commit d33f2c1
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion worlds/soe/__init__.py
Original file line number Diff line number Diff line change
@@ -188,6 +188,7 @@ class SoEWorld(World):
connect_name: str

_halls_ne_chest_names: typing.List[str] = [loc.name for loc in _locations if 'Halls NE' in loc.name]
_fillers = sorted(item_name_groups["Ingredients"])

def __init__(self, multiworld: "MultiWorld", player: int):
self.connect_name_available_event = threading.Event()
@@ -469,7 +470,7 @@ def modify_multidata(self, multidata: typing.Dict[str, typing.Any]) -> None:
multidata["connect_names"][self.connect_name] = payload

def get_filler_item_name(self) -> str:
return self.random.choice(list(self.item_name_groups["Ingredients"]))
return self.random.choice(self._fillers)


class SoEItem(Item):

0 comments on commit d33f2c1

Please sign in to comment.