From a646fcd25a27ca6bf875a12d52cc6d789cb477fb Mon Sep 17 00:00:00 2001 From: codemann8 Date: Mon, 28 Nov 2022 15:22:42 -0600 Subject: [PATCH] Fixed OWG logic to apply logic in correct world --- OverworldGlitchRules.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/OverworldGlitchRules.py b/OverworldGlitchRules.py index 0c705028..61636737 100644 --- a/OverworldGlitchRules.py +++ b/OverworldGlitchRules.py @@ -255,8 +255,12 @@ def get_region_pairs(world, player, names, parent_regions, target_regions, path_ def get_world_pair(world, player, region_pairs, get_light_world): # this chooses the region pair that is in the right world - if ((region_pairs[0] and world.is_tile_lw_like(OWTileRegions[region_pairs[0][1]], player)) \ - or not world.is_tile_lw_like(OWTileRegions[region_pairs[1][1]], player)) == get_light_world: + if region_pairs[0]: + is_lw = world.is_tile_lw_like(OWTileRegions[region_pairs[0][1]], player) + else: + is_lw = not world.is_tile_lw_like(OWTileRegions[region_pairs[1][1]], player) + + if is_lw == get_light_world: return region_pairs[0] else: return region_pairs[1]