Skip to content

Commit

Permalink
add race mode to multidata and datastore
Browse files Browse the repository at this point in the history
  • Loading branch information
alwaysintreble committed Sep 30, 2024
1 parent 8193fa1 commit 1ef0522
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions Main.py
Original file line number Diff line number Diff line change
Expand Up @@ -338,6 +338,7 @@ def precollect_hint(location):
"seed_name": multiworld.seed_name,
"spheres": spheres,
"datapackage": data_package,
"race_mode": int(multiworld.is_race),
}
AutoWorld.call_all(multiworld, "modify_multidata", multidata)

Expand Down
2 changes: 2 additions & 0 deletions MultiServer.py
Original file line number Diff line number Diff line change
Expand Up @@ -427,6 +427,8 @@ def _load(self, decoded_obj: dict, game_data_packages: typing.Dict[str, typing.A
use_embedded_server_options: bool):

self.read_data = {}
# there might be a better place to put this.
self.stored_data["race_mode"] = decoded_obj.get("race_mode", 0)
mdata_ver = decoded_obj["minimum_versions"]["server"]
if mdata_ver > version_tuple:
raise RuntimeError(f"Supplied Multidata (.archipelago) requires a server of at least version {mdata_ver},"
Expand Down

0 comments on commit 1ef0522

Please sign in to comment.