optimize sweep_for_events, some has_ functions and some minor things

This commit is contained in:
Fabian Dill
2020-08-22 19:19:29 +02:00
parent cac5795e01
commit b5048d99b9
5 changed files with 36 additions and 34 deletions

View File

@@ -209,7 +209,7 @@ def fill_restrictive(world, base_state: CollectionState, locations, itempool, si
if location.item and not location.event:
placements.append(location)
raise FillError(f'No more spots to place {item_to_place}, locations {locations} are invalid. '
f'\nAlready placed {len(placements)}: {", ".join(placements)}')
f'Already placed {len(placements)}: {", ".join(placements)}')
world.push_item(spot_to_fill, item_to_place, False)
locations.remove(spot_to_fill)