Fixed errors with starting equipment containing bottles

This commit is contained in:
codemann8
2025-03-11 09:07:57 -05:00
parent 7efc23b867
commit acc802dfdf
2 changed files with 4 additions and 1 deletions

View File

@@ -1245,7 +1245,7 @@ def modify_pool_for_start_inventory(start_inventory, world, player):
world.itempool.remove(alt_item)
i = i-1
elif 'Bottle' in item.name:
bottle_item = next((x for x in world.itempool if 'Bottle' in item.name and x.player == player), None)
bottle_item = next((x for x in world.itempool if 'Bottle' in x.name and x.player == player), None)
if bottle_item is not None:
world.itempool.remove(bottle_item)
if item.dungeon:

View File

@@ -429,6 +429,9 @@ def export_yaml(args, fish):
for k,v in {"DR":__version__,"OR":ORVersion}.items():
logger.info((k + ' Version:').ljust(16) + '%s' % v)
for player in range(1, world.players + 1):
world.difficulty_requirements[player] = difficulties[world.difficulty[player]]
set_starting_inventory(world, args)
world.settings = CustomSettings()