Skip to content

Commit d1bb6c2

Browse files
committed
Merge 'Logic for repeatable blue warp ToD changes' (#2304)
2 parents 2e5d681 + 4f2c975 commit d1bb6c2

5 files changed

Lines changed: 101 additions & 36 deletions

File tree

EntranceShuffle.py

Lines changed: 25 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -388,14 +388,14 @@ def build_one_way_targets(world: World, types_to_include: Iterable[str], exclude
388388
('WarpSong', ('Nocturne of Shadow Warp -> Graveyard Warp Pad Region', { 'index': 0x0568, 'addresses': [0xBF0244] })),
389389
('WarpSong', ('Prelude of Light Warp -> Temple of Time', { 'index': 0x05F4, 'addresses': [0xBF0246] })),
390390

391-
('BlueWarp', ('Queen Gohma Boss Room -> KF Outside Deku Tree', { 'index': 0x0457, 'addresses': [0xAC93A2, 0xCA3142, 0xCA316A] })),
392-
('BlueWarp', ('King Dodongo Boss Room -> Death Mountain', { 'index': 0x047A, 'addresses': [0xAC9336, 0xCA30CA, 0xCA30EA] })),
393-
('BlueWarp', ('Barinade Boss Room -> Zoras Fountain', { 'index': 0x010E, 'addresses': [0xAC936A, 0xCA31B2, 0xCA3702] })),
394-
('BlueWarp', ('Phantom Ganon Boss Room -> Sacred Forest Meadow', { 'index': 0x0608, 'addresses': [0xAC9F96, 0xCA3D66, 0xCA3D5A, 0xCA3D32], 'child_index': 0x0600 })),
395-
('BlueWarp', ('Volvagia Boss Room -> DMC Central Local', { 'index': 0x0564, 'addresses': [0xACA516, 0xCA3DF2, 0xCA3DE6, 0xCA3DBE], 'child_index': 0x04F6 })),
396-
('BlueWarp', ('Morpha Boss Room -> Lake Hylia', { 'index': 0x060C, 'addresses': [0xAC995A, 0xCA3E82, 0xCA3E76, 0xCA3E4A], 'child_index': 0x0604 })),
397-
('BlueWarp', ('Bongo Bongo Boss Room -> Graveyard Warp Pad Region', { 'index': 0x0580, 'addresses': [0xACA496, 0xCA3FA2, 0xCA3F96, 0xCA3F6A], 'child_index': 0x0568 })),
398-
('BlueWarp', ('Twinrova Boss Room -> Desert Colossus', { 'index': 0x0610, 'addresses': [0xACA402, 0xCA3F12, 0xCA3F06, 0xCA3EDA], 'child_index': 0x01F1 })),
391+
('BlueWarp', ('Queen Gohma Blue Warp -> KF Outside Deku Tree', { 'index': 0x0457, 'addresses': [0xAC93A2, 0xCA3142, 0xCA316A] })),
392+
('BlueWarp', ('King Dodongo Blue Warp -> Death Mountain', { 'index': 0x047A, 'addresses': [0xAC9336, 0xCA30CA, 0xCA30EA] })),
393+
('BlueWarp', ('Barinade Blue Warp -> Zoras Fountain', { 'index': 0x010E, 'addresses': [0xAC936A, 0xCA31B2, 0xCA3702] })),
394+
('BlueWarp', ('Phantom Ganon Blue Warp -> Sacred Forest Meadow', { 'index': 0x0608, 'addresses': [0xAC9F96, 0xCA3D66, 0xCA3D5A, 0xCA3D32], 'child_index': 0x0600 })),
395+
('BlueWarp', ('Volvagia Blue Warp -> DMC Central Local', { 'index': 0x0564, 'addresses': [0xACA516, 0xCA3DF2, 0xCA3DE6, 0xCA3DBE], 'child_index': 0x04F6 })),
396+
('BlueWarp', ('Morpha Blue Warp -> Lake Hylia', { 'index': 0x060C, 'addresses': [0xAC995A, 0xCA3E82, 0xCA3E76, 0xCA3E4A], 'child_index': 0x0604 })),
397+
('BlueWarp', ('Bongo Bongo Blue Warp -> Graveyard Warp Pad Region', { 'index': 0x0580, 'addresses': [0xACA496, 0xCA3FA2, 0xCA3F96, 0xCA3F6A], 'child_index': 0x0568 })),
398+
('BlueWarp', ('Twinrova Blue Warp -> Desert Colossus', { 'index': 0x0610, 'addresses': [0xACA402, 0xCA3F12, 0xCA3F06, 0xCA3EDA], 'child_index': 0x01F1 })),
399399

400400
('Extra', ('ZD Eyeball Frog Timeout -> Zoras Domain', { 'index': 0x0153 })),
401401
('Extra', ('ZR Top of Waterfall -> Zora River', { 'index': 0x0199 })),
@@ -572,7 +572,7 @@ def shuffle_random_entrances(worlds: list[World]) -> None:
572572
elif pool_type == 'Spawn':
573573
valid_target_types = ('Spawn', 'WarpSong', 'BlueWarp', 'OwlDrop', 'OverworldOneWay', 'Overworld', 'Interior', 'SpecialInterior', 'Extra')
574574
# Restrict spawn entrances from linking to regions with no or extremely specific glitchless itemless escapes.
575-
one_way_target_entrance_pools[pool_type] = build_one_way_targets(world, valid_target_types, exclude=['Volvagia Boss Room -> DMC Central Local', 'Bolero of Fire Warp -> DMC Central Local', 'Queen Gohma Boss Room -> KF Outside Deku Tree'])
575+
one_way_target_entrance_pools[pool_type] = build_one_way_targets(world, valid_target_types, exclude=['Volvagia Blue Warp -> DMC Central Local', 'Bolero of Fire Warp -> DMC Central Local', 'Queen Gohma Blue Warp -> KF Outside Deku Tree'])
576576
elif pool_type == 'WarpSong':
577577
valid_target_types = ('Spawn', 'WarpSong', 'BlueWarp', 'OwlDrop', 'OverworldOneWay', 'Overworld', 'Interior', 'SpecialInterior', 'Extra')
578578
one_way_target_entrance_pools[pool_type] = build_one_way_targets(world, valid_target_types)
@@ -646,25 +646,25 @@ def shuffle_random_entrances(worlds: list[World]) -> None:
646646
}
647647
# if a boss room is inside a dungeon entrance (or inside a dungeon which is inside a dungeon entrance), make the blue warp go to that dungeon's blue warp target
648648
dungeon_exits = {
649-
'Deku Tree Lobby -> KF Outside Deku Tree': world.get_entrance('Queen Gohma Boss Room -> KF Outside Deku Tree'),
650-
'Dodongos Cavern Beginning -> Death Mountain': world.get_entrance('King Dodongo Boss Room -> Death Mountain'),
651-
'Jabu Jabus Belly Beginning -> Zoras Fountain': world.get_entrance('Barinade Boss Room -> Zoras Fountain'),
652-
'Forest Temple Lobby -> SFM Forest Temple Entrance Ledge': world.get_entrance('Phantom Ganon Boss Room -> Sacred Forest Meadow'),
653-
'Fire Temple Lower -> DMC Fire Temple Entrance': world.get_entrance('Volvagia Boss Room -> DMC Central Local'),
654-
'Water Temple Lobby -> Lake Hylia': world.get_entrance('Morpha Boss Room -> Lake Hylia'),
655-
'Shadow Temple Entryway -> Graveyard Warp Pad Region': world.get_entrance('Bongo Bongo Boss Room -> Graveyard Warp Pad Region'),
656-
'Spirit Temple Lobby -> Desert Colossus From Spirit Lobby': world.get_entrance('Twinrova Boss Room -> Desert Colossus'),
649+
'Deku Tree Lobby -> KF Outside Deku Tree': world.get_entrance('Queen Gohma Blue Warp -> KF Outside Deku Tree'),
650+
'Dodongos Cavern Beginning -> Death Mountain': world.get_entrance('King Dodongo Blue Warp -> Death Mountain'),
651+
'Jabu Jabus Belly Beginning -> Zoras Fountain': world.get_entrance('Barinade Blue Warp -> Zoras Fountain'),
652+
'Forest Temple Lobby -> SFM Forest Temple Entrance Ledge': world.get_entrance('Phantom Ganon Blue Warp -> Sacred Forest Meadow'),
653+
'Fire Temple Lower -> DMC Fire Temple Entrance': world.get_entrance('Volvagia Blue Warp -> DMC Central Local'),
654+
'Water Temple Lobby -> Lake Hylia': world.get_entrance('Morpha Blue Warp -> Lake Hylia'),
655+
'Shadow Temple Entryway -> Graveyard Warp Pad Region': world.get_entrance('Bongo Bongo Blue Warp -> Graveyard Warp Pad Region'),
656+
'Spirit Temple Lobby -> Desert Colossus From Spirit Lobby': world.get_entrance('Twinrova Blue Warp -> Desert Colossus'),
657657
}
658658

659659
for (blue_warp, boss_door_exit) in (
660-
(world.get_entrance('Queen Gohma Boss Room -> KF Outside Deku Tree'), world.get_entrance('Queen Gohma Boss Room -> Deku Tree Before Boss')),
661-
(world.get_entrance('King Dodongo Boss Room -> Death Mountain'), world.get_entrance('King Dodongo Boss Room -> Dodongos Cavern Mouth')),
662-
(world.get_entrance('Barinade Boss Room -> Zoras Fountain'), world.get_entrance('Barinade Boss Room -> Jabu Jabus Belly Before Boss')),
663-
(world.get_entrance('Phantom Ganon Boss Room -> Sacred Forest Meadow'), world.get_entrance('Phantom Ganon Boss Room -> Forest Temple Before Boss')),
664-
(world.get_entrance('Volvagia Boss Room -> DMC Central Local'), world.get_entrance('Volvagia Boss Room -> Fire Temple Before Boss')),
665-
(world.get_entrance('Morpha Boss Room -> Lake Hylia'), world.get_entrance('Morpha Boss Room -> Water Temple Before Boss')),
666-
(world.get_entrance('Bongo Bongo Boss Room -> Graveyard Warp Pad Region'), world.get_entrance('Bongo Bongo Boss Room -> Shadow Temple Before Boss')),
667-
(world.get_entrance('Twinrova Boss Room -> Desert Colossus'), world.get_entrance('Twinrova Boss Room -> Spirit Temple Before Boss')),
660+
(world.get_entrance('Queen Gohma Blue Warp -> KF Outside Deku Tree'), world.get_entrance('Queen Gohma Boss Room -> Deku Tree Before Boss')),
661+
(world.get_entrance('King Dodongo Blue Warp -> Death Mountain'), world.get_entrance('King Dodongo Boss Room -> Dodongos Cavern Mouth')),
662+
(world.get_entrance('Barinade Blue Warp -> Zoras Fountain'), world.get_entrance('Barinade Boss Room -> Jabu Jabus Belly Before Boss')),
663+
(world.get_entrance('Phantom Ganon Blue Warp -> Sacred Forest Meadow'), world.get_entrance('Phantom Ganon Boss Room -> Forest Temple Before Boss')),
664+
(world.get_entrance('Volvagia Blue Warp -> DMC Central Local'), world.get_entrance('Volvagia Boss Room -> Fire Temple Before Boss')),
665+
(world.get_entrance('Morpha Blue Warp -> Lake Hylia'), world.get_entrance('Morpha Boss Room -> Water Temple Before Boss')),
666+
(world.get_entrance('Bongo Bongo Blue Warp -> Graveyard Warp Pad Region'), world.get_entrance('Bongo Bongo Boss Room -> Shadow Temple Before Boss')),
667+
(world.get_entrance('Twinrova Blue Warp -> Desert Colossus'), world.get_entrance('Twinrova Boss Room -> Spirit Temple Before Boss')),
668668
):
669669
target = boss_door_exit.replaces or boss_door_exit
670670
if True: #TODO not world.settings.decouple_entrances

World.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -575,8 +575,8 @@ def load_regions_from_json(self, file_path: str) -> list[tuple[Entrance, str]]:
575575
if 'time_passes' in region:
576576
new_region.time_passes = region['time_passes']
577577
new_region.provides_time = TimeOfDay.ALL
578-
if new_region.name == 'Ganons Castle Grounds':
579-
new_region.provides_time = TimeOfDay.DAMPE
578+
if 'provides_time' in region:
579+
new_region.provides_time = getattr(TimeOfDay, region['provides_time'])
580580
if 'locations' in region:
581581
for location, rule in region['locations'].items():
582582
new_location = LocationFactory(location)

data/World/Bosses.json

Lines changed: 72 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,15 @@
1515
},
1616
"exits": {
1717
"Deku Tree Before Boss": "True",
18-
"KF Outside Deku Tree": "'Defeat Queen Gohma'"
18+
"Queen Gohma Blue Warp": "'Defeat Queen Gohma'"
19+
}
20+
},
21+
{
22+
"region_name": "Queen Gohma Blue Warp",
23+
"scene": "Deku Tree Boss",
24+
"provides_time": "DAY",
25+
"exits": {
26+
"KF Outside Deku Tree": "at_day"
1927
}
2028
},
2129
{
@@ -35,7 +43,15 @@
3543
},
3644
"exits": {
3745
"Dodongos Cavern Mouth": "True",
38-
"Death Mountain": "'Defeat King Dodongo'"
46+
"King Dodongo Blue Warp": "'Defeat King Dodongo'"
47+
}
48+
},
49+
{
50+
"region_name": "King Dodongo Blue Warp",
51+
"scene": "Dodongos Cavern Boss",
52+
"provides_time": "DAY",
53+
"exits": {
54+
"Death Mountain": "at_day"
3955
}
4056
},
4157
{
@@ -57,7 +73,15 @@
5773
},
5874
"exits": {
5975
"Jabu Jabus Belly Before Boss": "False",
60-
"Zoras Fountain": "'Defeat Barinade'"
76+
"Barinade Blue Warp": "'Defeat Barinade'"
77+
}
78+
},
79+
{
80+
"region_name": "Barinade Blue Warp",
81+
"scene": "Jabu Jabus Belly Boss",
82+
"provides_time": "DAY",
83+
"exits": {
84+
"Zoras Fountain": "at_day"
6185
}
6286
},
6387
{
@@ -74,7 +98,15 @@
7498
},
7599
"exits": {
76100
"Forest Temple Before Boss": "False",
77-
"Sacred Forest Meadow": "'Defeat Phantom Ganon'"
101+
"Phantom Ganon Blue Warp": "'Defeat Phantom Ganon'"
102+
}
103+
},
104+
{
105+
"region_name": "Phantom Ganon Blue Warp",
106+
"scene": "Forest Temple Boss",
107+
"provides_time": "DAY",
108+
"exits": {
109+
"Sacred Forest Meadow": "at_day"
78110
}
79111
},
80112
{
@@ -90,7 +122,15 @@
90122
},
91123
"exits": {
92124
"Fire Temple Before Boss": "False",
93-
"DMC Central Local": "'Defeat Volvagia'"
125+
"Volvagia Blue Warp": "'Defeat Volvagia'"
126+
}
127+
},
128+
{
129+
"region_name": "Volvagia Blue Warp",
130+
"scene": "Fire Temple Boss",
131+
"provides_time": "DAY",
132+
"exits": {
133+
"DMC Central Local": "at_day"
94134
}
95135
},
96136
{
@@ -108,7 +148,15 @@
108148
},
109149
"exits": {
110150
"Water Temple Before Boss": "False",
111-
"Lake Hylia": "'Defeat Morpha'"
151+
"Morpha Blue Warp": "'Defeat Morpha'"
152+
}
153+
},
154+
{
155+
"region_name": "Morpha Blue Warp",
156+
"scene": "Water Temple Boss",
157+
"provides_time": "DAY",
158+
"exits": {
159+
"Lake Hylia": "at_day"
112160
}
113161
},
114162
{
@@ -127,7 +175,15 @@
127175
},
128176
"exits": {
129177
"Shadow Temple Before Boss": "False",
130-
"Graveyard Warp Pad Region": "'Defeat Bongo Bongo'"
178+
"Bongo Bongo Blue Warp": "'Defeat Bongo Bongo'"
179+
}
180+
},
181+
{
182+
"region_name": "Bongo Bongo Blue Warp",
183+
"scene": "Shadow Temple Boss",
184+
"provides_time": "DAY",
185+
"exits": {
186+
"Graveyard Warp Pad Region": "at_day"
131187
}
132188
},
133189
{
@@ -143,7 +199,15 @@
143199
},
144200
"exits": {
145201
"Spirit Temple Before Boss": "False",
146-
"Desert Colossus": "'Defeat Twinrova'"
202+
"Twinrova Blue Warp": "'Defeat Twinrova'"
203+
}
204+
},
205+
{
206+
"region_name": "Twinrova Blue Warp",
207+
"scene": "Spirit Temple Boss",
208+
"provides_time": "DAY",
209+
"exits": {
210+
"Desert Colossus": "at_day"
147211
}
148212
},
149213
{

data/World/Overworld.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1425,6 +1425,7 @@
14251425
"region_name": "Ganons Castle Grounds",
14261426
"scene": "Castle Grounds",
14271427
"hint": "OUTSIDE_GANONS_CASTLE",
1428+
"provides_time": "DAMPE",
14281429
"locations": {
14291430
"OGC GS": "True"
14301431
},

version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
__version__ = '8.3.16'
1+
__version__ = '8.3.17'
22

33
# This is a supplemental version number for branches based off of main dev.
44
supplementary_version = 0

0 commit comments

Comments
 (0)