From df435eb6939f59d2584858277ff4861e7707417b Mon Sep 17 00:00:00 2001 From: Hussein Farran Date: Wed, 1 Sep 2021 17:35:16 -0400 Subject: [PATCH 1/4] Remove `total_items` option. --- WebHostLib/static/assets/tutorial/ror2/setup_en.md | 11 +++++++---- worlds/ror2/Options.py | 8 -------- worlds/ror2/__init__.py | 4 ++-- 3 files changed, 9 insertions(+), 14 deletions(-) diff --git a/WebHostLib/static/assets/tutorial/ror2/setup_en.md b/WebHostLib/static/assets/tutorial/ror2/setup_en.md index a4e317ff..6dfdc5ed 100644 --- a/WebHostLib/static/assets/tutorial/ror2/setup_en.md +++ b/WebHostLib/static/assets/tutorial/ror2/setup_en.md @@ -42,7 +42,6 @@ game: Risk of Rain 2: total_locations: 15 - total_items: 30 total_revivals: 4 start_with_revive: true item_pickup_step: 1 @@ -51,16 +50,20 @@ Risk of Rain 2: | Name | Description | Allowed values | | ---- | ----------- | -------------- | -| total_locations | The total number of location checks that will be attributed to the Risk of Rain player. | 10 - 50 | -| total_items | The total number of items which are added to the multiworld on behalf of the Risk of Rain player. | 10-50 | +| total_locations | The total number of location checks that will be attributed to the Risk of Rain player. This option is ALSO the total number of items in the item pool for the Risk of Rain player. | 10 - 50 | | total_revivals | The total number of items in the Risk of Rain player's item pool (items other players pick up for them) replaced with `Dio's Best Friend`. | 0 - 5 | | start_with_revive | Starts the player off with a `Dio's Best Friend`. Functionally equivalent to putting a `Dio's Best Friend` in your `starting_inventory`. | true/false | | item_pickup_step | The number of item pickups which you are allowed to claim before they become an Archipelago location check. | 0 - 5 | | enable_lunar | Allows for lunar items to be shuffled into the item pool on behalf of the Risk of Rain player. | true/false | Using the example YAML above: the Risk of Rain 2 player will have 15 total items which they can pick up for other players. (total_locations = 15) -They will have 30 items which can be granted to them through the multiworld. (total_items = 30) + +They will have 15 items waiting for them in the item pool which will be distributed out to the multiworld. (total_locations = 15) + They will complete a location check every second item. (item_pickup_step = 1) + They will have 4 of the items which other players can grant them replaced with `Dio's Best Friend`. (total_revivals = 4) + The player will also start with a `Dio's Best Friend`. (start_with_revive = true) + The player will have lunar items shuffled into the item pool on their behalf. (enable_lunar = true) \ No newline at end of file diff --git a/worlds/ror2/Options.py b/worlds/ror2/Options.py index a77d7c3f..a58104e4 100644 --- a/worlds/ror2/Options.py +++ b/worlds/ror2/Options.py @@ -9,13 +9,6 @@ class TotalLocations(Range): range_end = 50 default = 15 -class TotalItems(Range): - """Number of items which are added to the multiworld on behalf of the Risk of Rain player.""" - displayname = "Total Items" - range_start = 10 - range_end = 50 - default = 30 - class TotalRevivals(Range): """Number of `Dio's Best Friend` item put in the item pool.""" @@ -50,6 +43,5 @@ ror2_options: typing.Dict[str, type(Option)] = { "total_revivals": TotalRevivals, "start_with_revive": StartWithRevive, "item_pickup_step": ItemPickupStep, - "total_items": TotalItems, "enable_lunar": AllowLunarItems } diff --git a/worlds/ror2/__init__.py b/worlds/ror2/__init__.py index d651018f..61016877 100644 --- a/worlds/ror2/__init__.py +++ b/worlds/ror2/__init__.py @@ -43,7 +43,7 @@ class RiskOfRainWorld(World): # Fill remaining items with randomly generated junk itempool += self.world.random.choices(list(junk_pool.keys()), weights=list(junk_pool.values()), - k=self.world.total_items[self.player] - + k=self.world.total_locations[self.player] - self.world.total_revivals[self.player]) # Convert itempool into real items @@ -61,7 +61,7 @@ class RiskOfRainWorld(World): return { "itemPickupStep": self.world.item_pickup_step[self.player].value, "seed": "".join(self.world.slot_seeds[self.player].choice(string.digits) for i in range(16)), - "totalLocations": self.world.total_items[self.player].value, + "totalLocations": self.world.total_locations[self.player].value, "totalRevivals": self.world.total_revivals[self.player].value } From abacca34eed64fc6c91dd79fbef113ddbe69c5f6 Mon Sep 17 00:00:00 2001 From: Hussein Farran Date: Mon, 6 Sep 2021 13:15:07 -0400 Subject: [PATCH 2/4] Add `startWithDio` to slot_data. --- worlds/ror2/__init__.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/worlds/ror2/__init__.py b/worlds/ror2/__init__.py index 61016877..d05851db 100644 --- a/worlds/ror2/__init__.py +++ b/worlds/ror2/__init__.py @@ -62,7 +62,8 @@ class RiskOfRainWorld(World): "itemPickupStep": self.world.item_pickup_step[self.player].value, "seed": "".join(self.world.slot_seeds[self.player].choice(string.digits) for i in range(16)), "totalLocations": self.world.total_locations[self.player].value, - "totalRevivals": self.world.total_revivals[self.player].value + "totalRevivals": self.world.total_revivals[self.player].value, + "startWithDio": self.world.start_with_revive[self.player].value } def create_item(self, name: str) -> Item: From 105a2d4e1361a4b52af67347d10231446416a991 Mon Sep 17 00:00:00 2001 From: Fabian Dill Date: Tue, 7 Sep 2021 00:42:02 +0200 Subject: [PATCH 3/4] WebHost: make LttP sprites optional --- WebHost.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/WebHost.py b/WebHost.py index c89e57eb..1962a1cd 100644 --- a/WebHost.py +++ b/WebHost.py @@ -36,7 +36,11 @@ if __name__ == "__main__": multiprocessing.freeze_support() multiprocessing.set_start_method('spawn') logging.basicConfig(format='[%(asctime)s] %(message)s', level=logging.INFO) - update_sprites_lttp() + try: + update_sprites_lttp() + except Exception as e: + logging.exception(e) + logging.warning("Could not update LttP sprites.") app = get_app() create_options_files() if app.config["SELFLAUNCH"]: From 279ab89a61c0b81cec04b5bf016bcc61b91b229f Mon Sep 17 00:00:00 2001 From: Jarno Westhof Date: Tue, 7 Sep 2021 00:07:17 +0200 Subject: [PATCH 4/4] Fixed Typo --- docs/network protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/network protocol.md b/docs/network protocol.md index aa6e2de4..82fe2ebf 100644 --- a/docs/network protocol.md +++ b/docs/network protocol.md @@ -229,7 +229,7 @@ Requests the data package from the server. Does not require client authenticatio #### Arguments | Name | Type | Notes | | ------ | ----- | ------ | -| exlusions | list[str] | Optional. If specified, will not send back the specified data. Such as, ["Factorio"] -> Datapackage without Factorio data.| +| exclusions | list[str] | Optional. If specified, will not send back the specified data. Such as, ["Factorio"] -> Datapackage without Factorio data.| ### Bounce Send this message to the server, tell it which clients should receive the message and