mirror of
https://github.com/MarioSpore/Grinch-AP.git
synced 2025-10-21 20:21:32 -06:00
Add VT26 style shuffling of dungeon items
Also adds new VT26 algorithm type that uses this, and makes it the default. the new type also includes the GT junk items randomization.
This commit is contained in:
21
Dungeons.py
21
Dungeons.py
@@ -102,6 +102,27 @@ def fill_dungeons(world):
|
||||
world.state._clear_cache()
|
||||
|
||||
|
||||
def fill_dungeons_restrictive(world):
|
||||
from Main import fill_restrictive
|
||||
all_state_base = world.get_all_state()
|
||||
|
||||
world.push_item(world.get_location('[dungeon-D3-B1] Skull Woods - South of Big Chest'), ItemFactory('Small Key (Skull Woods)'), False)
|
||||
world.get_location('[dungeon-D3-B1] Skull Woods - South of Big Chest').event = True
|
||||
|
||||
shuffled_locations=world.get_unfilled_locations()
|
||||
random.shuffle(shuffled_locations)
|
||||
|
||||
dungeon_items = [item for dungeon in world.dungeons for item in dungeon.all_items]
|
||||
|
||||
#sort in the order Big Key, Small Key, Other before placing dungeon items
|
||||
sort_order={"BigKey":3,"SmallKey":2};
|
||||
dungeon_items.sort(key=lambda item:sort_order.get(item.type, 1) )
|
||||
|
||||
fill_restrictive(world, all_state_base, shuffled_locations, dungeon_items)
|
||||
|
||||
world.state._clear_cache()
|
||||
|
||||
|
||||
dungeon_music_addresses = {'Armos - Pendant': [0x1559A],
|
||||
'Lanmolas - Pendant': [0x1559B, 0x1559C, 0x1559D, 0x1559E],
|
||||
'Moldorm - Pendant': [0x155C5, 0x1107A, 0x10B8C],
|
||||
|
||||
Reference in New Issue
Block a user