Fix documentation and example

Fix msu_resume issue
Fix empty locations
Throw error on unknown items
This commit is contained in:
aerinon
2022-03-25 08:43:11 -06:00
parent 27b836f16d
commit 5e07e49798
9 changed files with 139 additions and 8 deletions

View File

@@ -451,6 +451,8 @@ def distribute_items_restrictive(world, gftower_trash=False, fill_locations=None
def ensure_good_pots(world, write_skips=False):
for loc in world.get_locations():
if loc.item is None:
loc.item = ItemFactory('Nothing', loc.player)
# convert Arrows 5 and Nothing when necessary
if (loc.item.name in {'Arrows (5)', 'Nothing'}
and (loc.type != LocationType.Pot or loc.item.player != loc.player)):