From ed7dad1ae175be49551583e1a396bfd5660e9b44 Mon Sep 17 00:00:00 2001 From: jeboo Date: Mon, 5 Oct 2026 12:54:43 -0400 Subject: [PATCH 1/5] objectives screen: show areas if discovered --- patches/ips/pause_menu_objectives.ips | Bin 2354 -> 2809 bytes patches/rom_map/Bank 85.txt | 1 + patches/src/constants.asm | 1 + patches/src/pause_menu_objectives.asm | 304 ++++++++++++++++++++------ rust/maprando/src/patch.rs | 46 ++-- scripts/build_ips.py | 2 +- 6 files changed, 268 insertions(+), 86 deletions(-) diff --git a/patches/ips/pause_menu_objectives.ips b/patches/ips/pause_menu_objectives.ips index dec655bff2d9c0240a95f09485146d29bb089557..eaa86fd9e74dbb043e548ab0d8e3f97e764bac86 100644 GIT binary patch delta 848 zcmZWjT}V@57=FK?$n`z&yzl!w@6Y$9;`h;D zP3^r=ZewEuRcS!m_C1VqRBZyH=$BFTY0z4aMHHzfjMI;!p(}Re4?R4?Se|npt5YGb zLYoRzMLEyZP0QySmNY>xeDJ8kwE9`-YbAOS`gM(Hfz-?dszt7zD0gS5`PCQ+F9GIS zB2jl;za;tn>8)MqY9u;XBHfQfyGo>f-bk2qp8v-?`AbBbVw6sF@^i#A>f!II&!flu zq?$ST+D^ohFp`#}SmTru*67&Vk@P$*#lWW2kL(2hMNOk&ep~H8Ju`NV5qVW9KKcgP@ud-F2GR=A-%V!hVTl{9rt0l>|W%HB^2F@r@E(YZ6LZ#LD#p+s9YWE-4%2 z9WetLV4(||0I=^6nGBN|VEL}uCRvg8KZkhaC;G!=ltyI%K5hR8AeZ36<%@p-o0epz delta 443 zcmew6aVpL^iV2iN;u^H858JPcc{AX0tWnfb(nF|t9pABTn&Yc)+ z!1!=ti=Jl1yw(Jz$spneh)|giB%*-C+9dh2(ef9V6;A9-V4AJKa&F>nNycjvzlO&w zXkb|X=YNyt|N2&;56X)e7;Y&Xnf-xxx5E9|E4fwYGg#C$uz)x(Ud;aW;)&3O2dfiq zb#bj)S;x@IwEw{C{#J(lFMuS=a)w_jED8I8>QCO)_`vewMZ@QW&Hju!jP+~gw`O;H zuU^2#05pB?(z)}!%<5je=;*lc87j1X?))w^p|f-6=b#B)pF4jIs?cgAV|QX2dl+Ku z { obj_coords_vec.sort(); for (obj_i, coords) in obj_coords_vec.iter().enumerate() { let obj = obj_coords[coords]; - let (addr, mask) = match obj { - Kraid => (0xD829, 1), - Ridley => (0xD82A, 1), - Phantoon => (0xD82B, 1), - Draygon => (0xD82C, 1), - SporeSpawn => (0xD829, 2), - Crocomire => (0xD82A, 2), - Botwoon => (0xD82C, 2), - GoldenTorizo => (0xD82A, 4), - MetroidRoom1 => (0xD822, 1), - MetroidRoom2 => (0xD822, 2), - MetroidRoom3 => (0xD822, 4), - MetroidRoom4 => (0xD822, 8), - BombTorizo => (0xD828, 4), - BowlingStatue => (0xD823, 1), - AcidChozoStatue => (0xD821, 0x10), - PitRoom => (0xD823, 2), - BabyKraidRoom => (0xD823, 4), - PlasmaRoom => (0xD823, 8), - MetalPiratesRoom => (0xD823, 0x10), + let (addr, mask, room_hdr, offset_state_hdr, offset_x, offset_y, obj_tiles_x, obj_tiles_y) = match obj { + Kraid => (0xD829, 1, 0xA59F, 18, 0, 0, 2, 2), + Ridley => (0xD82A, 1, 0xB32E, 18, 0, 0, 1, 2), + Phantoon => (0xD82B, 1, 0xCD13, 18, 0, 0, 1, 1), + Draygon => (0xD82C, 1, 0xDA60, 18, 0, 0, 2, 2), + SporeSpawn => (0xD829, 2, 0x9DC7, 18, 0, 0, 1, 3), + Crocomire => (0xD82A, 2, 0xA98D, 18, 0, 0, 8, 1), + Botwoon => (0xD82C, 2, 0xD95E, 18, 0, 0, 2, 1), + GoldenTorizo => (0xD82A, 4, 0xB283, 18, 0, 0, 2, 2), + MetroidRoom1 => (0xD822, 1, 0xDAE1, 18, 0, 0, 6, 1), + MetroidRoom2 => (0xD822, 2, 0xDB31, 18, 0, 0, 1, 2), + MetroidRoom3 => (0xD822, 4, 0xDB7D, 18, 0, 0, 6, 1), + MetroidRoom4 => (0xD822, 8, 0xDBCD, 18, 0, 0, 1, 2), + BombTorizo => (0xD828, 4, 0x9804, 23, 0, 0, 1, 1), + BowlingStatue => (0xD823, 1, 0xC98E, 18, 4, 1, 1, 1), + AcidChozoStatue => (0xD821, 0x10, 0xB1E5, 13, 0, 0, 1, 1), + PitRoom => (0xD823, 2, 0x99BD, 13, 0, 0, 3, 1), + BabyKraidRoom => (0xD823, 4, 0xA521, 18, 0, 0, 6, 1), + PlasmaRoom => (0xD823, 8, 0xD2AA, 13, 0, 0, 2, 3), + MetalPiratesRoom => (0xD823, 0x10, 0xB62B, 13, 0, 0, 3, 1), }; self.rom.write_u16(snes2pc(0x8FEBC0) + obj_i * 2, addr)?; self.rom.write_u16(snes2pc(0x8FEBE8) + obj_i * 2, mask)?; + self.rom.write_u16(snes2pc(0x8FED00) + obj_i * 7, room_hdr)?; + self.rom.write_u8(snes2pc(0x8FED02) + obj_i * 7, offset_state_hdr)?; + self.rom.write_u8(snes2pc(0x8FED03) + obj_i * 7, offset_x)?; + self.rom.write_u8(snes2pc(0x8FED04) + obj_i * 7, offset_y)?; + self.rom.write_u8(snes2pc(0x8FED05) + obj_i * 7, obj_tiles_x)?; + self.rom.write_u8(snes2pc(0x8FED06) + obj_i * 7, obj_tiles_y)?; } Ok(()) diff --git a/scripts/build_ips.py b/scripts/build_ips.py index 0438568c17..d26e6edb01 100644 --- a/scripts/build_ips.py +++ b/scripts/build_ips.py @@ -132,7 +132,7 @@ def check_range(filename, other_filename, overlap_start, overlap_end): ], 'pause_menu_objectives': [ ['map_area', 0x82910A, 0x82910D], - ['hud_expansion_opaque', 0xB69A00, 0xB6AD40] + ['hud_expansion_opaque', 0xB69A00, 0xB6AE00] ], 'hud_expansion_opaque': [ ['max_ammo_display_fast', 0x858851, 0x858A93], From 91961005af90cc0ac96826b5f0bda23c1769abe5 Mon Sep 17 00:00:00 2001 From: jeboo Date: Mon, 5 Oct 2026 12:59:43 -0400 Subject: [PATCH 2/5] formatting.. --- rust/maprando/src/patch.rs | 23 ++++++++++++++++++----- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/rust/maprando/src/patch.rs b/rust/maprando/src/patch.rs index 63d2c2f130..43e8d8e4c4 100644 --- a/rust/maprando/src/patch.rs +++ b/rust/maprando/src/patch.rs @@ -3577,7 +3577,16 @@ impl Patcher<'_> { obj_coords_vec.sort(); for (obj_i, coords) in obj_coords_vec.iter().enumerate() { let obj = obj_coords[coords]; - let (addr, mask, room_hdr, offset_state_hdr, offset_x, offset_y, obj_tiles_x, obj_tiles_y) = match obj { + let ( + addr, + mask, + room_hdr, + offset_state_hdr, + offset_x, + offset_y, + obj_tiles_x, + obj_tiles_y, + ) = match obj { Kraid => (0xD829, 1, 0xA59F, 18, 0, 0, 2, 2), Ridley => (0xD82A, 1, 0xB32E, 18, 0, 0, 1, 2), Phantoon => (0xD82B, 1, 0xCD13, 18, 0, 0, 1, 1), @@ -3600,12 +3609,16 @@ impl Patcher<'_> { }; self.rom.write_u16(snes2pc(0x8FEBC0) + obj_i * 2, addr)?; self.rom.write_u16(snes2pc(0x8FEBE8) + obj_i * 2, mask)?; - self.rom.write_u16(snes2pc(0x8FED00) + obj_i * 7, room_hdr)?; - self.rom.write_u8(snes2pc(0x8FED02) + obj_i * 7, offset_state_hdr)?; + self.rom + .write_u16(snes2pc(0x8FED00) + obj_i * 7, room_hdr)?; + self.rom + .write_u8(snes2pc(0x8FED02) + obj_i * 7, offset_state_hdr)?; self.rom.write_u8(snes2pc(0x8FED03) + obj_i * 7, offset_x)?; self.rom.write_u8(snes2pc(0x8FED04) + obj_i * 7, offset_y)?; - self.rom.write_u8(snes2pc(0x8FED05) + obj_i * 7, obj_tiles_x)?; - self.rom.write_u8(snes2pc(0x8FED06) + obj_i * 7, obj_tiles_y)?; + self.rom + .write_u8(snes2pc(0x8FED05) + obj_i * 7, obj_tiles_x)?; + self.rom + .write_u8(snes2pc(0x8FED06) + obj_i * 7, obj_tiles_y)?; } Ok(()) From 7afc5237387a4c2cdddf1c391483ab751b89bd25 Mon Sep 17 00:00:00 2001 From: jeboo Date: Wed, 7 Oct 2026 12:49:37 -0400 Subject: [PATCH 3/5] optimizations --- patches/ips/pause_menu_objectives.ips | Bin 2809 -> 2798 bytes patches/src/pause_menu_objectives.asm | 21 ++++++--------------- 2 files changed, 6 insertions(+), 15 deletions(-) diff --git a/patches/ips/pause_menu_objectives.ips b/patches/ips/pause_menu_objectives.ips index eaa86fd9e74dbb043e548ab0d8e3f97e764bac86..5672335b70b64cf9a528357b8602df93111b647a 100644 GIT binary patch delta 100 zcmV-q0Gt2$748+V8wN8hpnw3c{QrU}|9|j!WEQ3tAcn>82q2rqsS725Q(C1K3JMB1 zF8_;^MM+ zDz{2vKkM86lZ=cL%&cBpy`JpHW?-}ZXcbW91g@oW5}6HJ^BFAaUc8w7Oblw?QLziH ks}pW@ajjZe$I!~O|G?}1R)+mAfF#RuhF_bvuvxJH0LK13+5i9m diff --git a/patches/src/pause_menu_objectives.asm b/patches/src/pause_menu_objectives.asm index dd4bd8ca49..740f113f12 100644 --- a/patches/src/pause_menu_objectives.asm +++ b/patches/src/pause_menu_objectives.asm @@ -893,23 +893,18 @@ check_objs_2: .check_if_seen PHY ; tilemap ptr -; obj # * 7 LDA $16 - STA $1E ASL ASL ASL SEC - SBC $1E + SBC $16 ; n*7, straight from the index TAX ; obj tiles table ptr CLC LDA !objectives_tiles+5,X ; grid size to check - CMP #$0101 ; valid size? + SEC + SBC #$0101 ; valid size? BCC .skip_check - DEC - XBA - DEC - XBA STA $1A ; grid x-1, y-1 LDA !objectives_tiles,X ; room hdr PHX @@ -954,18 +949,14 @@ check_objs_2: objective_done: ; X = index - PHX TXA ASL TAX - LDA.w #$007E - STA.b $02 - LDA.l !objectives_addrs,X - STA.b $00 LDA.l !objectives_bitmasks,X STA.b $04 - LDA.b [$00] - PLX + LDA.l !objectives_addrs,X + TAX + LDA.l $7e0000,X BIT.b $04 RTS From 73f0942c841e85b2d92285d4ab3db2f0985f89fe Mon Sep 17 00:00:00 2001 From: jeboo Date: Fri, 9 Oct 2026 09:14:49 -0400 Subject: [PATCH 4/5] add toggle --- patches/ips/pause_menu_objectives.ips | Bin 2798 -> 2815 bytes patches/src/pause_menu_objectives.asm | 17 +++++-- .../Community Race Season 5.json | 3 +- rust/data/presets/full-settings/Default.json | 3 +- .../full-settings/Mentor Tournament.json | 3 +- .../Summer Series Expert Challenge.json | 3 +- rust/data/presets/objectives/Bosses.json | 3 +- rust/data/presets/objectives/Chozos.json | 3 +- rust/data/presets/objectives/Metroids.json | 3 +- rust/data/presets/objectives/Minibosses.json | 3 +- rust/data/presets/objectives/None.json | 3 +- rust/data/presets/objectives/Pirates.json | 3 +- rust/data/presets/objectives/Random.json | 3 +- .../templates/generate/objectives.html | 11 ++++- .../templates/generate/scripts.html | 2 + .../templates/seed/objective_details.html | 6 +++ rust/maprando/src/patch.rs | 46 +++++++++++++----- rust/maprando/src/settings.rs | 19 ++++++++ 18 files changed, 106 insertions(+), 28 deletions(-) diff --git a/patches/ips/pause_menu_objectives.ips b/patches/ips/pause_menu_objectives.ips index 5672335b70b64cf9a528357b8602df93111b647a..ba8b964041cdc3169d9c66fbb035d8c1a266c4f2 100644 GIT binary patch delta 99 zcmaDS`d@T|G@Fj?f(C~5fBrXV{;$8l>@)Rfir6wSh3Q8>a44)fx{_P9A#Odx+x`oz zKwd-mWJ@+z)xAfnfSd_jOXVao8?@##Sk%3EG5eVq)QqEIADDdvk8WPT=Enj6<8CdJ delta 60 zcmV-C0K@82q2rqsS725Q$A(2BFM22KPt{uzJ( diff --git a/patches/src/pause_menu_objectives.asm b/patches/src/pause_menu_objectives.asm index 740f113f12..8876e695a1 100644 --- a/patches/src/pause_menu_objectives.asm +++ b/patches/src/pause_menu_objectives.asm @@ -879,7 +879,10 @@ check_objs_2: ;;; PHB is on stack LDY.w #!line_size*2 ; start of 1st line LDA !objectives_num : AND #$7FFF - BEQ .exit + BNE .not_null + JMP .exit + +.not_null STZ $16 ; obj index .obj_check_lp @@ -892,6 +895,12 @@ check_objs_2: BRA .write_tile .check_if_seen + LDA $8FED00 + BNE .enabled ; areas enabled? + JSR find_next_check + BRA .next + +.enabled PHY ; tilemap ptr LDA $16 ASL @@ -941,8 +950,8 @@ check_objs_2: INC $16 LDA !objectives_num : AND #$7FFF CMP $16 - BNE .obj_check_lp - + BEQ .exit + JMP .obj_check_lp .exit PLB RTS @@ -1104,7 +1113,7 @@ org $b6a0c0 db $00, $00, $18, $00, $18, $00, $00, $00, $00, $00, $18, $00, $18, $00, $00, $00 db $FF, $00, $FF, $18, $FF, $18, $FF, $00, $FF, $00, $FF, $18, $FF, $18, $FF, $00 -; check mark +; check mark (white) org $b6a160 db $01, $01, $03, $03, $06, $06, $8C, $8C, $D8, $D8, $70, $70, $20, $20, $00, $00 db $01, $01, $03, $03, $06, $06, $8C, $8C, $D8, $D8, $70, $70, $20, $20, $00, $00 diff --git a/rust/data/presets/full-settings/Community Race Season 5.json b/rust/data/presets/full-settings/Community Race Season 5.json index bb8ac788eb..71634f3815 100644 --- a/rust/data/presets/full-settings/Community Race Season 5.json +++ b/rust/data/presets/full-settings/Community Race Season 5.json @@ -4877,7 +4877,8 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Disabled" }, "map_layout": "Standard", "doors_settings": { diff --git a/rust/data/presets/full-settings/Default.json b/rust/data/presets/full-settings/Default.json index 31130449bf..17dbbb6d26 100644 --- a/rust/data/presets/full-settings/Default.json +++ b/rust/data/presets/full-settings/Default.json @@ -4789,7 +4789,8 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" }, "map_layout": "Standard", "doors_settings": { diff --git a/rust/data/presets/full-settings/Mentor Tournament.json b/rust/data/presets/full-settings/Mentor Tournament.json index db84d74848..d01c82ee74 100644 --- a/rust/data/presets/full-settings/Mentor Tournament.json +++ b/rust/data/presets/full-settings/Mentor Tournament.json @@ -4877,7 +4877,8 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Disabled" }, "map_layout": "Standard", "doors_settings": { diff --git a/rust/data/presets/full-settings/Summer Series Expert Challenge.json b/rust/data/presets/full-settings/Summer Series Expert Challenge.json index f7e22a14a2..3f7d292d6c 100644 --- a/rust/data/presets/full-settings/Summer Series Expert Challenge.json +++ b/rust/data/presets/full-settings/Summer Series Expert Challenge.json @@ -4789,7 +4789,8 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Disabled" }, "map_layout": "Standard", "doors_settings": { diff --git a/rust/data/presets/objectives/Bosses.json b/rust/data/presets/objectives/Bosses.json index dd844ae9dd..697eeded3e 100644 --- a/rust/data/presets/objectives/Bosses.json +++ b/rust/data/presets/objectives/Bosses.json @@ -23,5 +23,6 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/data/presets/objectives/Chozos.json b/rust/data/presets/objectives/Chozos.json index 9fb255f107..4a49c2f30c 100644 --- a/rust/data/presets/objectives/Chozos.json +++ b/rust/data/presets/objectives/Chozos.json @@ -23,5 +23,6 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/data/presets/objectives/Metroids.json b/rust/data/presets/objectives/Metroids.json index d524737ef5..05de803c54 100644 --- a/rust/data/presets/objectives/Metroids.json +++ b/rust/data/presets/objectives/Metroids.json @@ -23,5 +23,6 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/data/presets/objectives/Minibosses.json b/rust/data/presets/objectives/Minibosses.json index 236cb235f5..8d9c2b01bf 100644 --- a/rust/data/presets/objectives/Minibosses.json +++ b/rust/data/presets/objectives/Minibosses.json @@ -23,5 +23,6 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/data/presets/objectives/None.json b/rust/data/presets/objectives/None.json index 48f4202fd6..343cb81aee 100644 --- a/rust/data/presets/objectives/None.json +++ b/rust/data/presets/objectives/None.json @@ -23,5 +23,6 @@ ], "min_objectives": 0, "max_objectives": 0, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/data/presets/objectives/Pirates.json b/rust/data/presets/objectives/Pirates.json index a14c1d6fed..101afa98ef 100644 --- a/rust/data/presets/objectives/Pirates.json +++ b/rust/data/presets/objectives/Pirates.json @@ -23,5 +23,6 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/data/presets/objectives/Random.json b/rust/data/presets/objectives/Random.json index 02e34b70bc..12fcd91726 100644 --- a/rust/data/presets/objectives/Random.json +++ b/rust/data/presets/objectives/Random.json @@ -23,5 +23,6 @@ ], "min_objectives": 4, "max_objectives": 4, - "objective_screen": "Enabled" + "objective_screen": "Enabled", + "objective_areas": "Enabled" } diff --git a/rust/maprando-web/templates/generate/objectives.html b/rust/maprando-web/templates/generate/objectives.html index 01c91f2a00..09d008efa9 100644 --- a/rust/maprando-web/templates/generate/objectives.html +++ b/rust/maprando-web/templates/generate/objectives.html @@ -49,7 +49,7 @@

Objectives

- +
@@ -57,6 +57,15 @@

Objectives

+
+ +
+ + + + +
+
+
+
Show areas for discovered objectives:
+
+ {{ format!("{:?}", settings.objective_settings.objective_areas) }} +
+
diff --git a/rust/maprando/src/patch.rs b/rust/maprando/src/patch.rs index 43e8d8e4c4..fa889143d3 100644 --- a/rust/maprando/src/patch.rs +++ b/rust/maprando/src/patch.rs @@ -20,8 +20,9 @@ use crate::{ settings::{ AreaAssignmentPreset, CrashFixes, CrashFixesPreset, DisableETankSetting, ETankRefill, EnemyDrops, Fanfares, FixMode, ItemCount, MapPreset, MotherBrainFight, ObjPreset, - Objective, ObjectiveScreen, ProgressionPreset, QolPreset, RandomizerSettings, SaveAnimals, - SaveState, SkillPreset, SpeedBooster, StartLocationMode, WallJump, + Objective, ObjectiveAreas, ObjectiveScreen, ProgressionPreset, QolPreset, + RandomizerSettings, SaveAnimals, SaveState, SkillPreset, SpeedBooster, StartLocationMode, + WallJump, }, }; use anyhow::{Context, Result, bail, ensure}; @@ -3609,16 +3610,37 @@ impl Patcher<'_> { }; self.rom.write_u16(snes2pc(0x8FEBC0) + obj_i * 2, addr)?; self.rom.write_u16(snes2pc(0x8FEBE8) + obj_i * 2, mask)?; - self.rom - .write_u16(snes2pc(0x8FED00) + obj_i * 7, room_hdr)?; - self.rom - .write_u8(snes2pc(0x8FED02) + obj_i * 7, offset_state_hdr)?; - self.rom.write_u8(snes2pc(0x8FED03) + obj_i * 7, offset_x)?; - self.rom.write_u8(snes2pc(0x8FED04) + obj_i * 7, offset_y)?; - self.rom - .write_u8(snes2pc(0x8FED05) + obj_i * 7, obj_tiles_x)?; - self.rom - .write_u8(snes2pc(0x8FED06) + obj_i * 7, obj_tiles_y)?; + match self.settings.objective_settings.objective_areas { + ObjectiveAreas::Enabled => { + self.rom + .write_u16(snes2pc(0x8FED00) + obj_i * 7, room_hdr)?; + self.rom + .write_u8(snes2pc(0x8FED02) + obj_i * 7, offset_state_hdr)?; + self.rom.write_u8(snes2pc(0x8FED03) + obj_i * 7, offset_x)?; + self.rom.write_u8(snes2pc(0x8FED04) + obj_i * 7, offset_y)?; + self.rom + .write_u8(snes2pc(0x8FED05) + obj_i * 7, obj_tiles_x)?; + self.rom + .write_u8(snes2pc(0x8FED06) + obj_i * 7, obj_tiles_y)?; + } + ObjectiveAreas::Disabled => {} + } + + match self.settings.objective_settings.objective_areas { + ObjectiveAreas::Enabled => {} + ObjectiveAreas::Disabled => { + self.rom.write_u16(snes2pc(0x8FED00), 0x0000)?; // disabled flag + + let green_check = [ + 0x01, 0x00, 0x03, 0x00, 0x06, 0x00, 0x8C, 0x00, 0xD8, 0x00, 0x70, 0x00, + 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + ]; + for (i, &byte) in green_check.iter().enumerate() { + self.rom.write_u8(snes2pc(0x62A160) + i, byte)?; + } + } + } } Ok(()) diff --git a/rust/maprando/src/settings.rs b/rust/maprando/src/settings.rs index 3c6cff5693..c92f8891ae 100644 --- a/rust/maprando/src/settings.rs +++ b/rust/maprando/src/settings.rs @@ -562,6 +562,12 @@ pub enum ObjectiveScreen { Enabled, } +#[derive(Serialize, Deserialize, Clone, PartialEq, Debug)] +pub enum ObjectiveAreas { + Disabled, + Enabled, +} + #[derive(Serialize, Deserialize, Clone, PartialEq)] pub struct ObjectiveSettings { pub preset: Option, @@ -569,6 +575,7 @@ pub struct ObjectiveSettings { pub min_objectives: i32, pub max_objectives: i32, pub objective_screen: ObjectiveScreen, + pub objective_areas: ObjectiveAreas, } pub struct ObjectiveGroup { @@ -1456,6 +1463,18 @@ fn upgrade_objective_settings( .unwrap() .insert("objective_screen".to_string(), "Enabled".into()); } + if !settings_obj["objective_settings"] + .as_object() + .unwrap() + .contains_key("objective_areas") + { + settings_obj + .get_mut("objective_settings") + .unwrap() + .as_object_mut() + .unwrap() + .insert("objective_areas".to_string(), "Enabled".into()); + } Ok(()) } From 248d0b63892a25576807d1f1dff2728bb95661f3 Mon Sep 17 00:00:00 2001 From: jeboo Date: Fri, 9 Oct 2026 09:23:32 -0400 Subject: [PATCH 5/5] missing setting --- rust/maprando/tests/logic_scenarios.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/rust/maprando/tests/logic_scenarios.rs b/rust/maprando/tests/logic_scenarios.rs index 52e945b1f2..2372b6d37b 100644 --- a/rust/maprando/tests/logic_scenarios.rs +++ b/rust/maprando/tests/logic_scenarios.rs @@ -322,6 +322,7 @@ fn get_settings(scenario: &Scenario) -> Result { min_objectives: 0, max_objectives: 0, objective_screen: maprando::settings::ObjectiveScreen::Disabled, + objective_areas: maprando::settings::ObjectiveAreas::Disabled, }, map_layout: String::new(), doors_settings: DoorsSettings {