mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 12:11:33 -06:00
If due to DR or Plando the world is not fulfilling access rules, default to can_beat_game for Shop Logic
This commit is contained in:
9
Main.py
9
Main.py
@@ -229,6 +229,13 @@ def main(args, seed=None):
|
||||
|
||||
world.random.shuffle(candidates)
|
||||
|
||||
if not world.fulfills_accessibility():
|
||||
logger.warning("World does not fulfill accessibility rules as is, "
|
||||
"only using \"beatable only\" for shop logic.")
|
||||
shuffle_condition = world.can_beat_game
|
||||
else:
|
||||
shuffle_condition = world.fulfills_accessibility
|
||||
|
||||
# currently special care needs to be taken so that Shop.region.locations.item is identical to Shop.inventory
|
||||
# Potentially create Locations as needed and make inventory the only source, to prevent divergence
|
||||
|
||||
@@ -241,7 +248,7 @@ def main(args, seed=None):
|
||||
|
||||
swap_location_item(c, location, check_locked=False)
|
||||
candidates.remove(c)
|
||||
if not world.fulfills_accessibility():
|
||||
if not shuffle_condition():
|
||||
swap_location_item(c, location, check_locked=False)
|
||||
continue
|
||||
|
||||
|
Reference in New Issue
Block a user