mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
OOT: Fix incorrect region accessibility after update_reachable_regions() (#3712)
`CollectionState.update_reachable_regions()` un-stales the state for all players, but when checking `OOTRegion.can_reach()`, it would only update OOT's age region accessibility when the state was stale, so if the state was always un-staled by `update_reachable_regions()` immediately before `OOTRegion.can_reach()`, OOT's age region accessibility would never update. This patch fixes the issue by replacing use of CollectionState.stale with a separate stale state dictionary specific to OOT that is only un-staled by `_oot_update_age_reachable_regions()`. OOT's collect() and remove() implementations have been updated to stale the new OOT-specific state.
This commit is contained in:
@@ -64,7 +64,7 @@ class OOTRegion(Region):
|
||||
return None
|
||||
|
||||
def can_reach(self, state):
|
||||
if state.stale[self.player]:
|
||||
if state._oot_stale[self.player]:
|
||||
stored_age = state.age[self.player]
|
||||
state._oot_update_age_reachable_regions(self.player)
|
||||
state.age[self.player] = stored_age
|
||||
|
||||
Reference in New Issue
Block a user