Skip to content

Commit 0877d1d

Browse files
authored
Merge pull request #2991 from UmedMuzl/quickfix
Quick Fixes
2 parents acc3024 + 664f88d commit 0877d1d

File tree

7 files changed

+82
-47
lines changed

7 files changed

+82
-47
lines changed

base-hack/src/randomizers/k_rool_order.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,7 @@ void completeBoss(void) {
100100
if ((k_rool_phase == 4) || (Rando.k_rool_order[k_rool_phase + 1] == 0xFF)) {
101101
// Ending phase
102102
setPermFlag(FLAG_GAME_BEATEN);
103+
save();
103104
if (inU8List(CurrentMap, &maps_with_extended_end_cs, sizeof(maps_with_extended_end_cs))) {
104105
playCutscene(CurrentActorPointer_0, 0x1A, 1);
105106
renderingParamsData* render = Player->rendering_param_pointer;

randomizer/Lists/CustomLocations.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ class LocationTypes(IntEnum):
295295
max_size=56,
296296
logic_region=Regions.JapesPaintingRoomHill,
297297
group=1,
298-
banned_types=[LocationTypes.MelonCrate],
298+
banned_types=[LocationTypes.MelonCrate, LocationTypes.Bananaport],
299299
),
300300
CustomLocation(
301301
map=Maps.JungleJapes,

randomizer/Settings.py

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1673,9 +1673,14 @@ def resolve_settings(self):
16731673
if item_type == Types.Cranky:
16741674
item_types = [sk for sk in [Types.Cranky, Types.Snide, Types.Candy, Types.Funky] if shopkeeper_type_mapping[sk] not in guaranteed_starting_moves]
16751675
elif item_type == Types.TrainingBarrel:
1676-
item_types = [Types.TrainingBarrel, Types.PreGivenMove]
1677-
if self.climbing_status != ClimbingStatus.normal:
1678-
item_types.append(Types.Climbing)
1676+
# Only include TrainingBarrel type if training moves aren't all guaranteed starting moves
1677+
training_barrel_items = [Items.Vines, Items.Swim, Items.Oranges, Items.Barrels]
1678+
if all(tb_item in guaranteed_starting_moves for tb_item in training_barrel_items):
1679+
item_types = []
1680+
else:
1681+
item_types = [Types.TrainingBarrel, Types.PreGivenMove]
1682+
if self.climbing_status != ClimbingStatus.normal:
1683+
item_types.append(Types.Climbing)
16791684
elif item_type == Types.Medal and IsItemSelected(self.cb_rando_enabled, self.cb_rando_list_selected, Levels.DKIsles):
16801685
item_types = [Types.Medal, Types.IslesMedal]
16811686
for x in selector_types:
@@ -1708,6 +1713,15 @@ def resolve_settings(self):
17081713
):
17091714
self.item_pool_info[pool_index].is_shuffled = False
17101715
self.shuffled_location_types = list(set(self.shuffled_location_types))
1716+
1717+
# If training moves are not in any shuffled pool, add them to guaranteed_starting_moves
1718+
if Types.TrainingBarrel not in self.shuffled_location_types:
1719+
training_barrel_items = [Items.Vines, Items.Swim, Items.Oranges, Items.Barrels]
1720+
for tb_item in training_barrel_items:
1721+
if tb_item not in guaranteed_starting_moves:
1722+
guaranteed_starting_moves.append(tb_item)
1723+
self.training_barrels = TrainingBarrels.normal
1724+
17111725
self.enemy_drop_rando = Types.Enemies in self.shuffled_location_types
17121726
if Types.Shop in self.shuffled_location_types:
17131727
self.move_rando = MoveRando.item_shuffle
@@ -2645,7 +2659,7 @@ def update_valid_locations(self, spoiler):
26452659
if Types.Shockwave in self.shuffled_location_types:
26462660
locations_excluding_kong_shops.append(Locations.CameraAndShockwave)
26472661
self.valid_locations[Types.Shockwave] = locations_excluding_kong_shops.copy()
2648-
if Types.TrainingBarrel in self.shuffled_location_types:
2662+
if Types.TrainingBarrel in self.shuffled_location_types or self.training_barrels != TrainingBarrels.normal:
26492663
self.valid_locations[Types.TrainingBarrel] = locations_excluding_kong_shops.copy()
26502664
if Types.Climbing in self.shuffled_location_types:
26512665
self.valid_locations[Types.Climbing] = locations_excluding_kong_shops.copy()

static/js/rando_options.js

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1074,6 +1074,7 @@ function unshuffled_pool_list_changed(evt) {
10741074
let shopsInPool = true;
10751075
let shockwaveInPool = true;
10761076
let shopownersInPool = true;
1077+
let trainingMovesInPool = true;
10771078

10781079
const unshuffled_pool = document.getElementById(`item_rando_list_0`);
10791080
const types_in_pool = unshuffled_pool.getElementsByTagName("li");
@@ -1087,10 +1088,17 @@ function unshuffled_pool_list_changed(evt) {
10871088
if (types_in_pool[i].getAttribute("value") == "shopowners") {
10881089
shopownersInPool = false;
10891090
}
1091+
if (types_in_pool[i].getAttribute("value") == "trainingmoves") {
1092+
trainingMovesInPool = false;
1093+
}
10901094
}
10911095

10921096
let camera_option = document.getElementById("starting_move_52");
10931097
let shockwave_option = document.getElementById("starting_move_53");
1098+
let vines_option = document.getElementById("starting_move_8");
1099+
let swim_option = document.getElementById("starting_move_9");
1100+
let oranges_option = document.getElementById("starting_move_10");
1101+
let barrels_option = document.getElementById("starting_move_11");
10941102
let cranky_option = document.getElementById("starting_move_92");
10951103
let funky_option = document.getElementById("starting_move_93");
10961104
let candy_option = document.getElementById("starting_move_94");
@@ -1107,6 +1115,18 @@ function unshuffled_pool_list_changed(evt) {
11071115
camera_option.removeAttribute("hidden");
11081116
shockwave_option.removeAttribute("hidden");
11091117
}
1118+
if (!trainingMovesInPool) {
1119+
vines_option.setAttribute("hidden", "hidden");
1120+
swim_option.setAttribute("hidden", "hidden");
1121+
oranges_option.setAttribute("hidden", "hidden");
1122+
barrels_option.setAttribute("hidden", "hidden");
1123+
}
1124+
else {
1125+
vines_option.removeAttribute("hidden");
1126+
swim_option.removeAttribute("hidden");
1127+
oranges_option.removeAttribute("hidden");
1128+
barrels_option.removeAttribute("hidden");
1129+
}
11101130
if (!shopownersInPool) {
11111131
cranky_option.setAttribute("hidden", "hidden");
11121132
funky_option.setAttribute("hidden", "hidden");

static/patches/shrink-dk64.bps

-26 Bytes
Binary file not shown.

static/patches/symbols.json

Lines changed: 41 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1031,47 +1031,47 @@
10311031
"blast_entrances": 2153743048,
10321032
"swap_ending_cutscene_model": 2153743072,
10331033
"completeboss": 2153743288,
1034-
"fixkroolkong": 2153744000,
1035-
"handlekroolsaveprogress": 2153744100,
1036-
"k_rool_phase": 2153744428,
1037-
"writehudamount": 2153744604,
1038-
"coinhudelements": 2153744772,
1039-
"movetransplant": 2153744816,
1040-
"isshopempty": 2153744884,
1041-
"getinstrumentlevel": 2153744992,
1042-
"getprice": 2153745048,
1043-
"getnextmovepurchase": 2153745236,
1044-
"purchasemove": 2153745580,
1045-
"checkfirstmovepurchase": 2153746076,
1046-
"purchasefirstmovehandler": 2153746240,
1047-
"setlocation": 2153746308,
1048-
"setlocationstatus": 2153746336,
1049-
"getlocationstatus": 2153746556,
1050-
"displaymovetext": 2153746584,
1051-
"getnextmovetext": 2153746896,
1052-
"displaybfimovetext": 2153749248,
1053-
"showpostmovetext": 2153749376,
1054-
"simianslamnames": 2153750520,
1055-
"specialmovesnames": 2153750528,
1056-
"gunnames": 2153750568,
1057-
"gunupgnames": 2153750576,
1058-
"ammobeltnames": 2153750580,
1059-
"instrumentnames": 2153750584,
1060-
"instrumentupgnames": 2153750592,
1061-
"destroybonus": 2153750600,
1062-
"completebonus": 2153750632,
1063-
"helminit": 2153750760,
1064-
"helmbarrelcode": 2153751688,
1065-
"crowndoorcheck": 2153752056,
1066-
"coindoorcheck": 2153752068,
1067-
"unlockmoves": 2153752184,
1068-
"starting_item_data": 2153752636,
1069-
"auto_turn_keys": 2153752700,
1070-
"qualityoflife_shorteners": 2153752832,
1071-
"fastwarp": 2153752924,
1072-
"fastwarp_playmusic": 2153752956,
1073-
"fastwarpshockwavefix": 2153752984,
1074-
"clearvulturecutscene": 2153753088,
1034+
"fixkroolkong": 2153744008,
1035+
"handlekroolsaveprogress": 2153744108,
1036+
"k_rool_phase": 2153744436,
1037+
"writehudamount": 2153744612,
1038+
"coinhudelements": 2153744780,
1039+
"movetransplant": 2153744824,
1040+
"isshopempty": 2153744892,
1041+
"getinstrumentlevel": 2153745000,
1042+
"getprice": 2153745056,
1043+
"getnextmovepurchase": 2153745244,
1044+
"purchasemove": 2153745588,
1045+
"checkfirstmovepurchase": 2153746084,
1046+
"purchasefirstmovehandler": 2153746248,
1047+
"setlocation": 2153746316,
1048+
"setlocationstatus": 2153746344,
1049+
"getlocationstatus": 2153746564,
1050+
"displaymovetext": 2153746592,
1051+
"getnextmovetext": 2153746904,
1052+
"displaybfimovetext": 2153749256,
1053+
"showpostmovetext": 2153749384,
1054+
"simianslamnames": 2153750528,
1055+
"specialmovesnames": 2153750536,
1056+
"gunnames": 2153750576,
1057+
"gunupgnames": 2153750584,
1058+
"ammobeltnames": 2153750588,
1059+
"instrumentnames": 2153750592,
1060+
"instrumentupgnames": 2153750600,
1061+
"destroybonus": 2153750608,
1062+
"completebonus": 2153750640,
1063+
"helminit": 2153750768,
1064+
"helmbarrelcode": 2153751696,
1065+
"crowndoorcheck": 2153752064,
1066+
"coindoorcheck": 2153752076,
1067+
"unlockmoves": 2153752192,
1068+
"starting_item_data": 2153752644,
1069+
"auto_turn_keys": 2153752708,
1070+
"qualityoflife_shorteners": 2153752840,
1071+
"fastwarp": 2153752932,
1072+
"fastwarp_playmusic": 2153752964,
1073+
"fastwarpshockwavefix": 2153752992,
1074+
"clearvulturecutscene": 2153753096,
10751075
"codeend": 2153754112,
10761076
"copyfunc": 2153756496,
10771077
"regularframeloop": 2153759408,

wiki/article_markdown/custom_locations/CustomLocationsMiscellaneous.MD

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
| Jungle Japes | Diddy Cavern | | `self.logic = lambda _: True` |
1111
| Jungle Japes | Inside Diddy's Cavern | | `self.logic = lambda _: True` |
1212
| Jungle Japes | First tunnel - later half | | `self.logic = lambda _: True` |
13-
| Jungle Japes | Painting Hill | MelonCrate | `self.logic = lambda _: True` |
13+
| Jungle Japes | Painting Hill | MelonCrate, Bananaport | `self.logic = lambda _: True` |
1414
| Jungle Japes | Hive area near Hunky barrel | | `self.logic = lambda _: True` |
1515
| Jungle Japes | Near Stump | | `self.logic = lambda _: True` |
1616
| Jungle Japes | Near Log | | `self.logic = lambda _: True` |

0 commit comments

Comments
 (0)