From cade01b4898b6aeae6742f2059e035ab5b87fa35 Mon Sep 17 00:00:00 2001 From: aerinon Date: Tue, 27 Oct 2020 14:45:22 -0600 Subject: [PATCH] GUI work and revert find_accessible_entrances for main dungeon generation --- DoorShuffle.py | 5 +++-- Main.py | 2 +- README.md | 2 +- resources/app/cli/lang/en.json | 3 ++- resources/app/gui/lang/en.json | 4 ++-- resources/app/gui/randomize/dungeon/keysanity.json | 3 ++- source/classes/constants.py | 1 + 7 files changed, 12 insertions(+), 8 deletions(-) diff --git a/DoorShuffle.py b/DoorShuffle.py index f8f91e9c..fe91731d 100644 --- a/DoorShuffle.py +++ b/DoorShuffle.py @@ -168,7 +168,7 @@ def vanilla_key_logic(world, player): analyze_dungeon(key_layout, world, player) world.key_logic[player][builder.name] = key_layout.key_logic log_key_logic(builder.name, key_layout.key_logic) - if world.shuffle[player] == 'vanilla' and world.accessibility[player] == 'items' and not world.retro[player]: + if world.shuffle[player] == 'vanilla' and world.accessibility[player] == 'items' and not world.retro[player] and not world.keydropshuffle[player]: validate_vanilla_key_logic(world, player) @@ -689,7 +689,8 @@ def main_dungeon_generation(dungeon_builders, recombinant_builders, connections_ combine_layouts(recombinant_builders, dungeon_builders, entrances_map) world.dungeon_layouts[player] = {} for builder in dungeon_builders.values(): - builder.entrance_list = builder.layout_starts = builder.path_entrances = find_accessible_entrances(world, player, builder.all_entrances) + find_enabled_origins([builder.master_sector], enabled_entrances, builder.layout_starts, entrances_map, builder.name) + builder.path_entrances = entrances_map[builder.name] world.dungeon_layouts[player] = dungeon_builders diff --git a/Main.py b/Main.py index 9098ec0a..3ec96c9d 100644 --- a/Main.py +++ b/Main.py @@ -24,7 +24,7 @@ from Fill import distribute_items_cutoff, distribute_items_staleness, distribute from ItemList import generate_itempool, difficulties, fill_prizes from Utils import output_path, parse_player_names -__version__ = '0.2.0.3-u' +__version__ = '0.2.0.4-u' class EnemizerError(RuntimeError): pass diff --git a/README.md b/README.md index 89dd15f8..7ed5b80f 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ Doors are not shuffled. Normal door and spiral staircases are shuffled #### Level 2 Same as Level 1 plus open edges and straight staircases are shuffled. -#### Level 3 (Coming soon) +#### Level 3 Same as Level 2 plus Dungeon Lobbies are shuffled ## KeyDropShuffle diff --git a/resources/app/cli/lang/en.json b/resources/app/cli/lang/en.json index e03fac9b..2c9d2081 100644 --- a/resources/app/cli/lang/en.json +++ b/resources/app/cli/lang/en.json @@ -202,7 +202,7 @@ "Door Shuffle Intensity Level (default: %(default)s)", "1: Shuffles normal doors and spiral staircases", "2: And shuffles open edges and straight staircases", - "3: (Coming soon) And shuffles dungeon lobbies", + "3: And shuffles dungeon lobbies", "random: Picks one of those at random" ], "experimental": [ "Enable experimental features. (default: %(default)s)" ], @@ -244,6 +244,7 @@ "compassshuffle": [ "Compasses are no longer restricted to their dungeons, but can be anywhere. (default: %(default)s)" ], "keyshuffle": [ "Small Keys are no longer restricted to their dungeons, but can be anywhere. (default: %(default)s)" ], "bigkeyshuffle": [ "Big Keys are no longer restricted to their dungeons, but can be anywhere. (default: %(default)s)" ], + "keydropshuffle": [ "Key Drops (Pots and Enemies) are shuffled and other items can take their place (default: %(default)s)" ], "retro": [ "Keys are universal, shooting arrows costs rupees,", "and a few other little things make this more like Zelda-1. (default: %(default)s)" diff --git a/resources/app/gui/lang/en.json b/resources/app/gui/lang/en.json index 81da7110..5417eaf3 100644 --- a/resources/app/gui/lang/en.json +++ b/resources/app/gui/lang/en.json @@ -46,12 +46,12 @@ "adjust.rom.dialog.success": "Success", "adjust.rom.dialog.success.message": "Rom patched successfully.", - "randomizer.dungeon.keysanity": "Shuffle: ", "randomizer.dungeon.mapshuffle": "Maps", "randomizer.dungeon.compassshuffle": "Compasses", "randomizer.dungeon.smallkeyshuffle": "Small Keys", "randomizer.dungeon.bigkeyshuffle": "Big Keys", + "randomizer.dungeon.keydropshuffle": "Key Drops (pots and enemies)", "randomizer.dungeon.dungeondoorshuffle": "Dungeon Door Shuffle", "randomizer.dungeon.dungeondoorshuffle.vanilla": "Vanilla", @@ -61,7 +61,7 @@ "randomizer.dungeon.dungeonintensity": "Intensity Level", "randomizer.dungeon.dungeonintensity.1": "1: Normal Supertile and Spiral Stairs", "randomizer.dungeon.dungeonintensity.2": "2: Open Edges and Straight Stairs", - "randomizer.dungeon.dungeonintensity.3": "3: (Coming soon) Dungeon Lobbies", + "randomizer.dungeon.dungeonintensity.3": "3: Dungeon Lobbies", "randomizer.dungeon.dungeonintensity.random": "Random", "randomizer.dungeon.experimental": "Enable Experimental Features", diff --git a/resources/app/gui/randomize/dungeon/keysanity.json b/resources/app/gui/randomize/dungeon/keysanity.json index 49a17237..b7077f0e 100644 --- a/resources/app/gui/randomize/dungeon/keysanity.json +++ b/resources/app/gui/randomize/dungeon/keysanity.json @@ -3,6 +3,7 @@ "mapshuffle": { "type": "checkbox" }, "compassshuffle": { "type": "checkbox" }, "smallkeyshuffle": { "type": "checkbox" }, - "bigkeyshuffle": { "type": "checkbox" } + "bigkeyshuffle": { "type": "checkbox" }, + "keydropshuffle": { "type": "checkbox" } } } diff --git a/source/classes/constants.py b/source/classes/constants.py index 647ae19f..2d1720b5 100644 --- a/source/classes/constants.py +++ b/source/classes/constants.py @@ -86,6 +86,7 @@ SETTINGSTOPROCESS = { "compassshuffle": "compassshuffle", "smallkeyshuffle": "keyshuffle", "bigkeyshuffle": "bigkeyshuffle", + "keydropshuffle": "keydropshuffle", "dungeondoorshuffle": "door_shuffle", "dungeonintensity": "intensity", "experimental": "experimental",