Merged in DR v1.2.0.17

This commit is contained in:
codemann8
2023-06-16 12:14:16 -05:00
6 changed files with 16 additions and 15 deletions

View File

@@ -279,6 +279,10 @@ def recovery_placement(item_to_place, locations, world, state, base_state, itemp
if spot_to_fill:
return spot_to_fill
return None
# explicitly fail these cases
elif world.algorithm in ['dungeon_only', 'major_only']:
raise FillError(f'Rare placement for {world.algorithm} detected. {item_to_place} unable to be placed.'
f' Try a different seed')
else:
other_locations = [x for x in locations if x not in attempted]
for location in other_locations:
@@ -425,7 +429,7 @@ def distribute_items_restrictive(world, gftower_trash=False, fill_locations=None
else:
max_trash = gt_count
scaled_trash = math.floor(max_trash * scale_factor)
if world.goal[player] in ['triforcehunt', 'trinity', 'ganonhunt']:
if world.goal[player] in ['triforcehunt', 'trinity', 'ganonhunt'] or world.algorithm == 'dungeon_only':
gftower_trash_count = random.randint(scaled_trash, max_trash)
else:
gftower_trash_count = random.randint(0, scaled_trash)