From 0fcca25870be3ec343d13a3ab7b4e0d63c13b84b Mon Sep 17 00:00:00 2001 From: Silvris <58583688+Silvris@users.noreply.github.com> Date: Fri, 23 Aug 2024 22:41:00 -0500 Subject: [PATCH 1/4] Core: deepcopy plando items #3841 --- Generate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Generate.py b/Generate.py index d7dd6523e7..6220c0eb81 100644 --- a/Generate.py +++ b/Generate.py @@ -511,7 +511,7 @@ def roll_settings(weights: dict, plando_options: PlandoOptions = PlandoOptions.b continue logging.warning(f"{option_key} is not a valid option name for {ret.game} and is not present in triggers.") if PlandoOptions.items in plando_options: - ret.plando_items = game_weights.get("plando_items", []) + ret.plando_items = copy.deepcopy(game_weights.get("plando_items", [])) if ret.game == "A Link to the Past": roll_alttp_settings(ret, game_weights) From 83367c694602beff5fd84e1160909cc85ce771fb Mon Sep 17 00:00:00 2001 From: Exempt-Medic <60412657+Exempt-Medic@users.noreply.github.com> Date: Sat, 24 Aug 2024 04:53:56 -0400 Subject: [PATCH 2/4] ALttP: Fix accessibility (locations -> full) (#3801) --- worlds/alttp/Rules.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/worlds/alttp/Rules.py b/worlds/alttp/Rules.py index f596749ae6..a664f8ac9b 100644 --- a/worlds/alttp/Rules.py +++ b/worlds/alttp/Rules.py @@ -412,7 +412,7 @@ def global_rules(multiworld: MultiWorld, player: int): lambda state: ((state._lttp_has_key('Small Key (Thieves Town)', player, 3)) or (location_item_name(state, 'Thieves\' Town - Big Chest', player) == ("Small Key (Thieves Town)", player)) and state._lttp_has_key('Small Key (Thieves Town)', player, 2)) and state.has('Hammer', player)) set_rule(multiworld.get_location('Thieves\' Town - Blind\'s Cell', player), lambda state: state._lttp_has_key('Small Key (Thieves Town)', player)) - if multiworld.accessibility[player] != 'locations' and not multiworld.key_drop_shuffle[player]: + if multiworld.accessibility[player] != 'full' and not multiworld.key_drop_shuffle[player]: set_always_allow(multiworld.get_location('Thieves\' Town - Big Chest', player), lambda state, item: item.name == 'Small Key (Thieves Town)' and item.player == player) set_rule(multiworld.get_location('Thieves\' Town - Attic', player), lambda state: state._lttp_has_key('Small Key (Thieves Town)', player, 3)) set_rule(multiworld.get_location('Thieves\' Town - Spike Switch Pot Key', player), @@ -547,7 +547,7 @@ def global_rules(multiworld: MultiWorld, player: int): location_item_name(state, 'Ganons Tower - Map Chest', player) in [('Big Key (Ganons Tower)', player)] and state._lttp_has_key('Small Key (Ganons Tower)', player, 6))) # this seemed to be causing generation failure, disable for now - # if world.accessibility[player] != 'locations': + # if world.accessibility[player] != 'full': # set_always_allow(world.get_location('Ganons Tower - Map Chest', player), lambda state, item: item.name == 'Small Key (Ganons Tower)' and item.player == player and state._lttp_has_key('Small Key (Ganons Tower)', player, 7) and state.can_reach('Ganons Tower (Hookshot Room)', 'region', player)) # It is possible to need more than 6 keys to get through this entrance if you spend keys elsewhere. We reflect this in the chest requirements. From dddffa1660423a379faf3a4808b962679084dc68 Mon Sep 17 00:00:00 2001 From: Aaron Wagener Date: Sat, 24 Aug 2024 03:54:33 -0500 Subject: [PATCH 3/4] LTTP: fix own_dungeon setting from not being placed in the player's own world (#3816) --- worlds/alttp/__init__.py | 2 + .../alttp/test/options/test_dungeon_fill.py | 60 +++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 worlds/alttp/test/options/test_dungeon_fill.py diff --git a/worlds/alttp/__init__.py b/worlds/alttp/__init__.py index 3176f7a7fc..3cdbb1cb45 100644 --- a/worlds/alttp/__init__.py +++ b/worlds/alttp/__init__.py @@ -356,6 +356,8 @@ class ALTTPWorld(World): self.dungeon_local_item_names |= self.item_name_groups[option.item_name_group] if option == "original_dungeon": self.dungeon_specific_item_names |= self.item_name_groups[option.item_name_group] + else: + self.options.local_items.value |= self.dungeon_local_item_names self.difficulty_requirements = difficulties[multiworld.item_pool[player].current_key] diff --git a/worlds/alttp/test/options/test_dungeon_fill.py b/worlds/alttp/test/options/test_dungeon_fill.py new file mode 100644 index 0000000000..17501b65d8 --- /dev/null +++ b/worlds/alttp/test/options/test_dungeon_fill.py @@ -0,0 +1,60 @@ +from unittest import TestCase + +from BaseClasses import MultiWorld +from test.general import gen_steps, setup_multiworld +from worlds.AutoWorld import call_all +from worlds.generic.Rules import locality_rules +from ... import ALTTPWorld +from ...Options import DungeonItem + + +class DungeonFillTestBase(TestCase): + multiworld: MultiWorld + world_1: ALTTPWorld + world_2: ALTTPWorld + options = ( + "big_key_shuffle", + "small_key_shuffle", + "key_drop_shuffle", + "compass_shuffle", + "map_shuffle", + ) + + def setUp(self): + self.multiworld = setup_multiworld([ALTTPWorld, ALTTPWorld], ()) + self.world_1 = self.multiworld.worlds[1] + self.world_2 = self.multiworld.worlds[2] + + def generate_with_options(self, option_value: int): + for option in self.options: + getattr(self.world_1.options, option).value = getattr(self.world_2.options, option).value = option_value + + for step in gen_steps: + call_all(self.multiworld, step) + # this is where locality rules are set in normal generation which we need to verify this test + if step == "set_rules": + locality_rules(self.multiworld) + + def test_original_dungeons(self): + self.generate_with_options(DungeonItem.option_original_dungeon) + for location in self.multiworld.get_filled_locations(): + with (self.subTest(location=location)): + if location.parent_region.dungeon is None: + self.assertIs(location.item.dungeon, None) + else: + self.assertEqual(location.player, location.item.player, + f"{location.item} does not belong to {location}'s player") + if location.item.dungeon is None: + continue + self.assertIs(location.item.dungeon, location.parent_region.dungeon, + f"{location.item} was not placed in its original dungeon.") + + def test_own_dungeons(self): + self.generate_with_options(DungeonItem.option_own_dungeons) + for location in self.multiworld.get_filled_locations(): + with self.subTest(location=location): + if location.parent_region.dungeon is None: + self.assertIs(location.item.dungeon, None) + else: + self.assertEqual(location.player, location.item.player, + f"{location.item} does not belong to {location}'s player") From e99f027b424eb37949ece2c768d75ddf3b96ae38 Mon Sep 17 00:00:00 2001 From: Justus Lind Date: Sun, 25 Aug 2024 02:19:42 +1000 Subject: [PATCH 4/4] Muse Dash: Update to 4.7.0 - Let's Rhythm Jam! (#3837) * Update to Muse Dash 4.7.0 Muse Dash - Let's Rhythm Jam! * Add the replaced song to the removed list. * Oops add the other secret song to this list. * Add trailing comma Co-authored-by: Doug Hoskisson --------- Co-authored-by: Doug Hoskisson --- worlds/musedash/MuseDashCollection.py | 2 ++ worlds/musedash/MuseDashData.txt | 15 ++++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/worlds/musedash/MuseDashCollection.py b/worlds/musedash/MuseDashCollection.py index 576a106df7..9e8c9214a1 100644 --- a/worlds/musedash/MuseDashCollection.py +++ b/worlds/musedash/MuseDashCollection.py @@ -46,6 +46,8 @@ class MuseDashCollections: "CHAOS Glitch", "FM 17314 SUGAR RADIO", "Yume Ou Mono Yo Secret", + "Echo over you... Secret", + "Tsukuyomi Ni Naru Replaced", ] album_items: Dict[str, AlbumData] = {} diff --git a/worlds/musedash/MuseDashData.txt b/worlds/musedash/MuseDashData.txt index 6f48d6af9f..1f1a2a011c 100644 --- a/worlds/musedash/MuseDashData.txt +++ b/worlds/musedash/MuseDashData.txt @@ -553,7 +553,7 @@ NOVA|73-4|Happy Otaku Pack Vol.19|True|6|8|10| Heaven's Gradius|73-5|Happy Otaku Pack Vol.19|True|6|8|10| Ray Tuning|74-0|CHUNITHM COURSE MUSE|True|6|8|10| World Vanquisher|74-1|CHUNITHM COURSE MUSE|True|6|8|10|11 -Tsukuyomi Ni Naru|74-2|CHUNITHM COURSE MUSE|False|5|7|9| +Tsukuyomi Ni Naru Replaced|74-2|CHUNITHM COURSE MUSE|True|5|7|9| The wheel to the right|74-3|CHUNITHM COURSE MUSE|True|5|7|9|11 Climax|74-4|CHUNITHM COURSE MUSE|True|4|8|11|11 Spider's Thread|74-5|CHUNITHM COURSE MUSE|True|5|8|10|12 @@ -567,3 +567,16 @@ SUPERHERO|75-0|Novice Rider Pack|False|2|4|7| Highway_Summer|75-1|Novice Rider Pack|True|2|4|6| Mx. Black Box|75-2|Novice Rider Pack|True|5|7|9| Sweet Encounter|75-3|Novice Rider Pack|True|2|4|7| +Echo over you... Secret|0-55|Default Music|False|6|8|10| +Echo over you...|0-56|Default Music|False|1|4|0| +Tsukuyomi Ni Naru|74-6|CHUNITHM COURSE MUSE|True|5|8|10| +disco light|76-0|MUSE RADIO FM105|True|5|7|9| +room light feat.chancylemon|76-1|MUSE RADIO FM105|True|3|5|7| +Invisible|76-2|MUSE RADIO FM105|True|3|5|8| +Christmas Season-LLABB|76-3|MUSE RADIO FM105|True|1|4|7| +Hyouryu|77-0|Let's Rhythm Jam!|False|6|8|10| +The Whole Rest|77-1|Let's Rhythm Jam!|False|5|8|10|11 +Hydra|77-2|Let's Rhythm Jam!|False|4|7|11| +Pastel Lines|77-3|Let's Rhythm Jam!|False|3|6|9| +LINK x LIN#S|77-4|Let's Rhythm Jam!|False|3|6|9| +Arcade ViruZ|77-5|Let's Rhythm Jam!|False|6|8|10|