diff --git a/Fusion_Graph.py b/Fusion_Graph.py index c281e74..24e3bab 100644 --- a/Fusion_Graph.py +++ b/Fusion_Graph.py @@ -27,6 +27,7 @@ class Game: self.majorItemLocations = list() self.minorItemLocations = list() self.itemLocations = list() + self.itemArea = dict() self.patcher = dict() self.graph.clear() self.areaConnections.clear() @@ -234,7 +235,8 @@ class Game: for area in range(0, 7): if 'S{}'.format(area) in start: if 'S{}'.format(area) not in point: - return None + if self.itemArea.get(point) != area: + return None edge = (start, point) self.queue.append(edge) while self.queue: diff --git a/Randomizer.py b/Randomizer.py index ba5c1ef..76b049b 100644 --- a/Randomizer.py +++ b/Randomizer.py @@ -3127,6 +3127,7 @@ def start_randomizer(rom, settings): BossLocations.append(name) if 'Item' in name or nodeType == 'Boss' or nodeType == 'Data': AreaItemLocations[areaIndex].append(name) + World.itemArea[name] = areaIndex World.ConnectAllNodes() StartLocation = 'S0-00'