mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
Pokémon R/B: Allow generating with all items linked (#4330)
* Pokémon R/B: Allow generating with all items linked * check priority/excluded locations for pc_item * Update regions.py * Un-remove regions.py code
This commit is contained in:
@@ -1579,6 +1579,18 @@ def create_regions(world):
|
||||
world.item_pool.append(item)
|
||||
|
||||
world.random.shuffle(world.item_pool)
|
||||
if not world.options.key_items_only:
|
||||
if "Player's House 2F - Player's PC" in world.options.exclude_locations:
|
||||
acceptable_item = lambda item: item.excludable
|
||||
elif "Player's House 2F - Player's PC" in world.options.priority_locations:
|
||||
acceptable_item = lambda item: item.advancement
|
||||
else:
|
||||
acceptable_item = lambda item: True
|
||||
for i, item in enumerate(world.item_pool):
|
||||
if acceptable_item(item):
|
||||
world.pc_item = world.item_pool.pop(i)
|
||||
break
|
||||
|
||||
advancement_items = [item.name for item in world.item_pool if item.advancement] \
|
||||
+ [item.name for item in world.multiworld.precollected_items[world.player] if
|
||||
item.advancement]
|
||||
|
||||
Reference in New Issue
Block a user