Skip to content

Commit

Permalink
let core handle option resolution again, don't know why i thought it …
Browse files Browse the repository at this point in the history
…was necessary anymore
  • Loading branch information
qwint committed Aug 11, 2024
1 parent 91cd8ec commit 7a43aca
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions worlds/tracker/TrackerClient.py
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,7 @@ def run_generator(self, slot_data: Optional[Dict] = None):
for slot, game in g_args.game.items()
}
self.launch_multiworld = self.TMain(g_args, seed)
self.multiworld = self.launch_multiworld

temp_precollect = {}
for player_id, items in self.multiworld.precollected_items.items():
Expand All @@ -344,13 +345,6 @@ def run_generator(self, slot_data: Optional[Dict] = None):
logger.error(tb)

def TMain(self, args, seed=None, baked_server_options: Optional[Dict[str, object]] = None):
def set_options(self):
for player in self.player_ids:
world_type = AutoWorld.AutoWorldRegister.world_types[self.game[player]]
self.worlds[player] = world_type(self, player)
options_dataclass: typing.Type[Options.PerGameCommonOptions] = world_type.options_dataclass
self.worlds[player].options = options_dataclass(**{option_key: getattr(args, option_key)[player]
for option_key in options_dataclass.type_hints})
if not baked_server_options:
baked_server_options = get_settings().server_options.as_dict()
assert isinstance(baked_server_options, dict)
Expand Down Expand Up @@ -381,8 +375,7 @@ def set_options(self):
multiworld.sprite = args.sprite.copy()
multiworld.sprite_pool = args.sprite_pool.copy()

# multiworld.set_options(args)
set_options(multiworld)
multiworld.set_options(args)
multiworld.set_item_links()
multiworld.state = CollectionState(multiworld)
logger.info('Archipelago Version %s - Seed: %s\n', __version__, multiworld.seed)
Expand Down

0 comments on commit 7a43aca

Please sign in to comment.