From 252e85f7e2f1ca17ea86ee5f420c5a16c68213e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20K=C5=82ysz?= Date: Fri, 27 Nov 2026 16:31:16 +0000 Subject: [PATCH 1/2] fix(us2): name the Visibomb gun's added gate by its level datum v2.00's visibomb_gun_update_us2 reads gp+0x2870 (level 0: 0x001B1860), the same word visibomb_missile_update_us2 reads. It is v1.01's g_hero_scalar_transition_value (D_L00_001B18E0), not an executable datum. D_US2_001B1860 stated no level, so the port's release view turned it into D_001B1860, v1.01's executable datum, which level 0 keeps at 0x001B1BA0. The port read that word, found it set, and the gun never fired. Checked: tests/check_repository.py, unittest (468 OK), progress.py --check; OpenRAC hostgen for rac2-ntsc2 now reads OPENRAC_LDATA(0, 0x001B1860). Not run: tools/build.py --version us2 (no compiler/dumps here). --- config/names.tsv | 1 - config/names_local.tsv | 1 - include/names/us2.h | 1 - src/us2/levels/shared/L00_00390CB4.c | 6 +++--- 4 files changed, 3 insertions(+), 6 deletions(-) diff --git a/config/names.tsv b/config/names.tsv index 3f3e863d7..cc496d84b 100644 --- a/config/names.tsv +++ b/config/names.tsv @@ -14772,7 +14772,6 @@ D_L03_001B2AC8 g_level_flag_word_a descriptive config/names_local.tsv D_L03_001B3730 g_level_flag_word_b descriptive config/names_local.tsv D_L03_001B3738 g_level_flag_word_c descriptive config/names_local.tsv D_L11_0021F8B0 g_level_flags descriptive config/names_local.tsv -D_US2_001B1860 g_level_float_flag descriptive config/names_local.tsv D_001B2350 g_level_float_param descriptive config/names_local.tsv D_001B2EF4 g_level_float_param_2 descriptive config/names_local.tsv D_L16_001B3AAC g_level_l16_float_param descriptive config/names_local.tsv diff --git a/config/names_local.tsv b/config/names_local.tsv index b4913880c..4079b644b 100644 --- a/config/names_local.tsv +++ b/config/names_local.tsv @@ -13727,7 +13727,6 @@ D_L03_001B2AC8 g_level_flag_word_a declared only (medium) D_L03_001B3730 g_level_flag_word_b declared only (medium) D_L03_001B3738 g_level_flag_word_c declared only (medium) D_L11_0021F8B0 g_level_flags LevelFlags -D_US2_001B1860 g_level_float_flag use in source (medium) D_001B2350 g_level_float_param compared to 0.9 (medium) D_001B2EF4 g_level_float_param_2 declared only float (medium) D_L16_001B3AAC g_level_l16_float_param declared only (medium) diff --git a/include/names/us2.h b/include/names/us2.h index 9c73f1ee2..497c2d5d6 100644 --- a/include/names/us2.h +++ b/include/names/us2.h @@ -83,7 +83,6 @@ #define g_level_init_flag_c D_US2_001B03EC #define g_level_init_flag_d D_US2_001B0C60 #define g_level_init_flag_e D_US2_001B0D58 -#define g_level_float_flag D_US2_001B1860 #define g_pending_request_flag D_US2_001B19BC #define g_level_int_value_b D_US2_001B1CFC #define g_hero_sound_flag D_US2_001C9700 diff --git a/src/us2/levels/shared/L00_00390CB4.c b/src/us2/levels/shared/L00_00390CB4.c index 1510a085a..c6471bae9 100644 --- a/src/us2/levels/shared/L00_00390CB4.c +++ b/src/us2/levels/shared/L00_00390CB4.c @@ -1,7 +1,7 @@ #include "include_asm.h" /* func_US2_L00_00390CB4, the v2.00 copy of func_L00_0038F8B8: the same C with one test added - * after the level 111/98 gate, on D_US2_001B1860. */ + * after the level 111/98 gate, on g_hero_scalar_transition_value. */ #include "common.h" /* Partial resident view: only fields observed by the launch gate are named. */ typedef struct { char pad00[0xA8]; u16 launches; char padAA[2]; u32 best_time, mask; } LaunchStats; @@ -20,7 +20,7 @@ extern LaunchInput g_pad_state; extern u32 g_frame_counter MACRO_ADDR; extern u32 g_current_map_index[] __attribute__((sda)); extern char *g_follow_camera_object; -extern float g_level_float_flag __attribute__((sda)); +extern float g_hero_scalar_transition_value __attribute__((sda)); extern int math_fast_float_d(int *), weapon_spend_ammo(int, int); extern float vec_length_xy(void *), mat_fast_helper_a(float, float); extern void vec_build_spherical_offset(float *, float, float, float), FastVecAdd(void *, void *, void *); @@ -42,7 +42,7 @@ void visibomb_gun_update_us2(char *actor) { else g_hero_state.cooldown = 40; if (g_game_l00_mode[0] || g_input_lock_state[0] != -2 || !(g_pad_state.buttons & g_hero_state.buttons) || state[0] || state[1] || g_hero_state.busy) goto finish; if (g_hero_state.state == 7 || g_hero_state.state == 2 || g_hero_state.state == 3 || g_hero_state.state == 4 || g_hero_state.state == 5 || g_hero_state.state == 6 || g_hero_state.state == 16 || g_hero_state.state == 14 || g_hero_state.state == 9 || g_hero_state.state == 10 || g_hero_state.state == 11 || g_hero_state.state >= 13 || g_hero_state.level == 111 || g_hero_state.level == 98) goto finish; - if (g_level_float_flag != 0.0f) goto finish; + if (g_hero_scalar_transition_value != 0.0f) goto finish; if ((g_follow_camera_object && *(short *)(g_follow_camera_object + 0x86) == 5) || !g_hero_state.grounded || g_hero_state.resource < 23) goto finish; if (g_hero_state.support && (*(short *)(g_hero_state.support + 0xAA) == 0x13E || *(short *)(g_hero_state.support + 0xAA) == 0x46F) && ready) goto finish; if (!weapon_spend_ammo(-1, 1)) goto denied; From c1fb081688751afe993a2d6053631d5cc4573e1b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20K=C5=82ysz?= Date: Fri, 27 Nov 2026 16:58:50 +0000 Subject: [PATCH 2/2] fix(pal,us2): name more release level data by their level Some of PAL's and USA v2.00's own level C named a level datum with an executable name (D_PAL_XXXXXXXX, D_US2_XXXXXXXX). The disc forms the stated address in these functions, but the port's release view read the name as v1.01's executable datum of that number, which the level keeps elsewhere. Now each uses v1.01's level name of the same datum where one exists, and a level name of the release's own otherwise: - us2 L00_00432D98 (page record f): g_prompt_bar_params_a/b/c (port read 0x1AE500, disc 0x1AE1C0) - pal L00_00436E20: g_prompt_bar_params_a/b (0x1AE500/520, disc 0x1AE200/220) - pal L00_003FA3D0: g_vaporizer_trail_step_speed (0x1B0CCC, disc 0x1B09CC) - pal L01_0041B900: g_bobbing_amplitude (0x1B2450, disc 0x1B1A50) - pal L00_003EFC00: g_particle_params_a/b -> D_PAL_L00_001B0800/0810 (0x1B0B00/B10, disc 0x1B0800/0810) - pal L05_0042C044: g_target_object -> D_PAL_L05_001B1510 (0x1B1ED0, disc 0x1B1510) Checked against each function's code in the dumped PAL and v2.00 programs. Other hits of the same search were false alarms (the port already reads what the disc forms). Checked: tests/check_repository.py, unittest (468 OK), progress.py --check, names.py check. OpenRAC hostgen for rac2-pal and rac2-ntsc2: only these files change. Not run: tools/build.py (no compiler here). --- config/names.tsv | 13 +++---------- config/names_local.tsv | 13 +++---------- include/names/pal.h | 10 +++------- include/names/us2.h | 3 --- src/pal/levels/01_oozla/L01_0041B900-g8.c | 4 ++-- src/pal/levels/shared/L00_003FA3D0-g8.c | 4 ++-- src/pal/levels/shared/L00_00436E20-g8.c | 8 ++++---- src/us2/levels/shared/L00_00432D98-g8.c | 12 ++++++------ 8 files changed, 23 insertions(+), 44 deletions(-) diff --git a/config/names.tsv b/config/names.tsv index cc496d84b..8089900fb 100644 --- a/config/names.tsv +++ b/config/names.tsv @@ -10390,9 +10390,6 @@ D_US2_001ADE60 g_child_param_pair_a descriptive config/names_local.tsv D_US2_001ADE70 g_child_param_pair_b descriptive config/names_local.tsv D_US2_001ADE80 g_child_param_pair_c descriptive config/names_local.tsv D_US2_001ADE90 g_child_param_pair_d descriptive config/names_local.tsv -D_US2_001AE1A0 g_child_param_pair_e descriptive config/names_local.tsv -D_US2_001AE1C0 g_child_param_pair_f descriptive config/names_local.tsv -D_US2_001AE1D0 g_child_param_pair_g descriptive config/names_local.tsv D_PAL_001ADE68 g_child_params_a descriptive config/names_local.tsv D_PAL_001ADEB0 g_child_params_b descriptive config/names_local.tsv D_PAL_001ADEF0 g_child_params_c descriptive config/names_local.tsv @@ -10444,7 +10441,6 @@ D_0018C0D7 g_class_flag_byte descriptive config/names_local.tsv D_L00_001B1CE0 g_class_l00_flags_table descriptive config/names_local.tsv D_L00_001DD180 g_class_l00_flags_table_2 descriptive config/names_local.tsv D_PAL_001B1A4C g_class_float_base descriptive config/names_local.tsv -D_PAL_001B1A50 g_class_float_random_scale descriptive config/names_local.tsv D_PAL_001B1A48 g_class_float_scale descriptive config/names_local.tsv D_L00_001DA680 g_class_ids_by_slot descriptive config/names_local.tsv D_L20_001DBA60 g_class_index_table descriptive config/names_local.tsv @@ -14715,8 +14711,6 @@ D_L01_0025C274 g_level_byte_data descriptive config/names_local.tsv D_L01_001A7A6F g_level_l01_byte_flag descriptive config/names_local.tsv D_L05_001B4568 g_level_l05_byte_flag descriptive config/names_local.tsv D_L05_0020B220 g_level_byte_ptr_table descriptive config/names_local.tsv -D_PAL_001AE200 g_level_child_params_a descriptive config/names_local.tsv -D_PAL_001AE220 g_level_child_params_b descriptive config/names_local.tsv D_PAL_001AE230 g_level_child_params_c descriptive config/names_local.tsv D_L00_001B1944 g_level_chunk_base descriptive config/names_local.tsv D_L00_001B1E8C g_level_chunk_count_a descriptive config/names_local.tsv @@ -16629,8 +16623,8 @@ D_L07_001B0AB4 g_particle_pair_lift_speed descriptive config/names_local.tsv D_L07_001B0AC0 g_particle_pair_scale_range descriptive config/names_local.tsv D_L07_001B0AB0 g_particle_pair_speed descriptive config/names_local.tsv D_L07_001B0AD0 g_particle_pair_value_range descriptive config/names_local.tsv -D_PAL_001B0800 g_particle_params_a descriptive config/names_local.tsv -D_PAL_001B0810 g_particle_params_b descriptive config/names_local.tsv +D_PAL_L00_001B0800 g_particle_params_a descriptive config/names_local.tsv +D_PAL_L00_001B0810 g_particle_params_b descriptive config/names_local.tsv D_PAL_001B0820 g_particle_params_c descriptive config/names_local.tsv D_L05_001AFC60 g_particle_params_first descriptive config/names_local.tsv D_L05_001AFC70 g_particle_params_second descriptive config/names_local.tsv @@ -17845,7 +17839,6 @@ D_L03_001B1C04 g_robot_turn_scale descriptive config/names_local.tsv D_L03_00238040 g_rope_strand_points descriptive config/names_local.tsv D_001B5358 g_rotation_base_angle descriptive config/names_local.tsv D_L07_001B0C6C g_rotation_base_step descriptive config/names_local.tsv -D_PAL_001B09CC g_rotation_length_scale descriptive config/names_local.tsv D_L07_001B0C70 g_rotation_step_a descriptive config/names_local.tsv D_L07_001B0C74 g_rotation_step_b descriptive config/names_local.tsv D_L16_001B0C78 g_rotation_step_degrees descriptive config/names_local.tsv @@ -20326,7 +20319,7 @@ D_L00_001AFCE0 g_target_lock_disabled descriptive config/names_local.tsv D_L00_001B28E4 g_target_lock_range descriptive config/names_local.tsv D_L00_001AFCE8 g_target_lock_timer descriptive config/names_local.tsv D_0018A3E0 g_target_moby descriptive config/names_local.tsv -D_PAL_001B1510 g_target_object descriptive config/names_local.tsv +D_PAL_L05_001B1510 g_target_object descriptive config/names_local.tsv D_L00_001AA300 g_target_point descriptive config/names_local.tsv D_L23_001AFAB4 g_target_point_dot_threshold descriptive config/names_local.tsv D_001A85C0 g_target_scale_factor descriptive config/names_local.tsv diff --git a/config/names_local.tsv b/config/names_local.tsv index 4079b644b..97b58d581 100644 --- a/config/names_local.tsv +++ b/config/names_local.tsv @@ -9345,9 +9345,6 @@ D_US2_001ADE60 g_child_param_pair_a use in source (medium) D_US2_001ADE70 g_child_param_pair_b use in source (medium) D_US2_001ADE80 g_child_param_pair_c use in source (medium) D_US2_001ADE90 g_child_param_pair_d use in source (medium) -D_US2_001AE1A0 g_child_param_pair_e use in source (medium) -D_US2_001AE1C0 g_child_param_pair_f use in source (medium) -D_US2_001AE1D0 g_child_param_pair_g use in source (medium) D_PAL_001ADE68 g_child_params_a int[2] passed to child setup (medium) D_PAL_001ADEB0 g_child_params_b int[2] passed to child setup (medium) D_PAL_001ADEF0 g_child_params_c int[2] passed to child setup (medium) @@ -9399,7 +9396,6 @@ D_0018C0D7 g_class_flag_byte set on class 13 (medium) D_L00_001B1CE0 g_class_l00_flags_table indexed by class, 0x80 flag (medium) D_L00_001DD180 g_class_l00_flags_table_2 int table 0xFFFC0000 (medium) D_PAL_001B1A4C g_class_float_base base added to f18 (medium) -D_PAL_001B1A50 g_class_float_random_scale multiplied by random f (medium) D_PAL_001B1A48 g_class_float_scale multiplies class f24 (medium) D_L00_001DA680 g_class_ids_by_slot short table by class (medium) D_L20_001DBA60 g_class_index_table indexed by class id (medium) @@ -13670,8 +13666,6 @@ D_L01_0025C274 g_level_byte_data declared only u8 array (medium) D_L01_001A7A6F g_level_l01_byte_flag declared only (medium) D_L05_001B4568 g_level_l05_byte_flag declared only (medium) D_L05_0020B220 g_level_byte_ptr_table declared only (medium) -D_PAL_001AE200 g_level_child_params_a int[2] passed to child setup (medium) -D_PAL_001AE220 g_level_child_params_b int[2] passed to child setup (medium) D_PAL_001AE230 g_level_child_params_c int[2] passed to child setup (medium) D_L00_001B1944 g_level_chunk_base assigned from pointer (medium) D_L00_001B1E8C g_level_chunk_count_a loop bound from header (medium) @@ -15584,8 +15578,8 @@ D_L07_001B0AB4 g_particle_pair_lift_speed scaled velocity (medium) D_L07_001B0AC0 g_particle_pair_scale_range random range D_L07_001B0AB0 g_particle_pair_speed random direction speed (medium) D_L07_001B0AD0 g_particle_pair_value_range random int range -D_PAL_001B0800 g_particle_params_a particle spawn arg (medium) -D_PAL_001B0810 g_particle_params_b particle spawn arg (medium) +D_PAL_L00_001B0800 g_particle_params_a particle spawn arg (medium) +D_PAL_L00_001B0810 g_particle_params_b particle spawn arg (medium) D_PAL_001B0820 g_particle_params_c particle spawn arg (medium) D_L05_001AFC60 g_particle_params_first particle spawn array (medium) D_L05_001AFC70 g_particle_params_second particle spawn array (medium) @@ -16800,7 +16794,6 @@ D_L03_001B1C04 g_robot_turn_scale shared by bots (medium) D_L03_00238040 g_rope_strand_points pool row column vectors D_001B5358 g_rotation_base_angle FastAddRotations base (medium) D_L07_001B0C6C g_rotation_base_step rotation add (medium) -D_PAL_001B09CC g_rotation_length_scale scales vec length (medium) D_L07_001B0C70 g_rotation_step_a step var (medium) D_L07_001B0C74 g_rotation_step_b step var (medium) D_L16_001B0C78 g_rotation_step_degrees axis rotation angle (medium) @@ -19281,7 +19274,7 @@ D_L00_001AFCE0 g_target_lock_disabled blocks lock and tether (medium) D_L00_001B28E4 g_target_lock_range 35.0 (medium) D_L00_001AFCE8 g_target_lock_timer state timer (medium) D_0018A3E0 g_target_moby compared to moby (medium) -D_PAL_001B1510 g_target_object pointer, +0x10 position used for spring (medium) +D_PAL_L05_001B1510 g_target_object pointer, +0x10 position used for spring (medium) D_L00_001AA300 g_target_point V3 point in target lookup (medium) D_L23_001AFAB4 g_target_point_dot_threshold dot product compare (medium) D_001A85C0 g_target_scale_factor target reticle scale (medium) diff --git a/include/names/pal.h b/include/names/pal.h index 920734836..4555b724b 100644 --- a/include/names/pal.h +++ b/include/names/pal.h @@ -60,8 +60,6 @@ #define g_child_params_e D_PAL_001ADF10 #define g_child_params_f D_PAL_001ADF20 #define g_child_params_g D_PAL_001ADF30 -#define g_level_child_params_a D_PAL_001AE200 -#define g_level_child_params_b D_PAL_001AE220 #define g_level_child_params_c D_PAL_001AE230 #define g_object_offset_x_a D_PAL_001AE330 #define g_object_offset_y_a D_PAL_001AE334 @@ -86,11 +84,8 @@ #define g_menu_field_eight_b D_PAL_001AE3F8 #define g_menu_field_nine_b D_PAL_001AE400 #define g_object_direction_scale D_PAL_001AECC0 -#define g_particle_params_a D_PAL_001B0800 -#define g_particle_params_b D_PAL_001B0810 #define g_particle_params_c D_PAL_001B0820 #define g_slot_t_increment D_PAL_001B09B8 -#define g_rotation_length_scale D_PAL_001B09CC #define g_slot_u_increment D_PAL_001B09F0 #define g_level_data_pointer D_PAL_001B0CD0 #define g_mark_particle_params_a D_PAL_001B0EF8 @@ -98,12 +93,10 @@ #define g_mark_particle_params_c D_PAL_001B0F18 #define g_level_float_scale_a D_PAL_001B1420 #define g_level_float_scale_b D_PAL_001B1424 -#define g_target_object D_PAL_001B1510 #define g_level_toggle_flag D_PAL_001B16F8 #define g_pending_value D_PAL_001B1A3C #define g_class_float_scale D_PAL_001B1A48 #define g_class_float_base D_PAL_001B1A4C -#define g_class_float_random_scale D_PAL_001B1A50 #define g_class_rotation_scale D_PAL_001B1A64 #define g_class_random_range D_PAL_001B1A88 #define g_level_return_value D_PAL_001B1D7C @@ -117,6 +110,8 @@ #define g_lift_sound_table D_PAL_00701818 #define g_lift_sound_table_alt D_PAL_00702018 #define g_level_base_pointer D_PAL_FFFF001B +#define g_particle_params_a D_PAL_L00_001B0800 +#define g_particle_params_b D_PAL_L00_001B0810 #define g_str_level_debug_format D_PAL_L02_001B1258 #define g_text_l02_print_scale D_PAL_L02_001B14C8 #define g_text_l02_print_color D_PAL_L02_001B14CC @@ -142,6 +137,7 @@ #define g_debug_l04_tune_value_c D_PAL_L04_001B0BCC #define g_debug_l04_tune_value_d D_PAL_L04_001B0BD0 #define g_str_l04_debug_tune_format D_PAL_L04_001B0BD8 +#define g_target_object D_PAL_L05_001B1510 #define console_get_region_pal func_PAL_00131620 #define gfx_append_splash_packet_pal func_PAL_0026E780 #define ShowSplashImage_pal func_PAL_0026E838 diff --git a/include/names/us2.h b/include/names/us2.h index 497c2d5d6..75c7c2a6e 100644 --- a/include/names/us2.h +++ b/include/names/us2.h @@ -51,9 +51,6 @@ #define g_child_param_pair_c D_US2_001ADE80 #define g_child_param_pair_d D_US2_001ADE90 #define g_str_status_format D_US2_001ADF70 -#define g_child_param_pair_e D_US2_001AE1A0 -#define g_child_param_pair_f D_US2_001AE1C0 -#define g_child_param_pair_g D_US2_001AE1D0 #define g_object_offset_x_a_2 D_US2_001AE298 #define g_object_offset_y_a_2 D_US2_001AE29C #define g_object_offset_x_b_2 D_US2_001AE2A0 diff --git a/src/pal/levels/01_oozla/L01_0041B900-g8.c b/src/pal/levels/01_oozla/L01_0041B900-g8.c index cdb30933a..11e89c97b 100644 --- a/src/pal/levels/01_oozla/L01_0041B900-g8.c +++ b/src/pal/levels/01_oozla/L01_0041B900-g8.c @@ -43,7 +43,7 @@ extern void gfx_draw_glow_rings_pal(Obj_397870 *); extern float g_class_float_scale __attribute__((sda)); extern float g_class_float_base __attribute__((sda)); -extern float g_class_float_random_scale __attribute__((sda)); +extern float g_bobbing_amplitude __attribute__((sda)); extern float g_class_rotation_scale __attribute__((sda)); extern int g_class_random_range __attribute__((sda)); @@ -57,7 +57,7 @@ void bobbing_l01_moby_update_2_pal(Obj_397870 *moby) if (moby->b20 == 1) { sine = math_fast_sin_or_cos_b(moby->fFC); - moby->f18 = vars->f18 + g_class_float_base + g_class_float_random_scale * sine; + moby->f18 = vars->f18 + g_class_float_base + g_bobbing_amplitude * sine; moby->fF0 = FastAddRotations(moby->fF0, vars->f68); moby->fF4 = FastAddRotations(moby->fF4, vars->f64); moby->fF8 = FastAddRotations(moby->fF8, vars->f60); diff --git a/src/pal/levels/shared/L00_003FA3D0-g8.c b/src/pal/levels/shared/L00_003FA3D0-g8.c index f8528c94a..6620e1977 100644 --- a/src/pal/levels/shared/L00_003FA3D0-g8.c +++ b/src/pal/levels/shared/L00_003FA3D0-g8.c @@ -36,7 +36,7 @@ extern void FastVecAdd(void *, void *, void *); extern float g_slot_t_increment __attribute__((sda)); extern float g_slot_u_increment __attribute__((sda)); -extern float g_rotation_length_scale __attribute__((sda)); +extern float g_vaporizer_trail_step_speed __attribute__((sda)); /* Advances one vaporizer trail sample each frame: scrolls its texture coordinates and moves it along its direction, and frees it when it has expired (PAL: 50 Hz steps). */ int vaporizer_bolt_update_trail_sample_pal(TrailActor *self) @@ -60,7 +60,7 @@ int vaporizer_bolt_update_trail_sample_pal(TrailActor *self) slots[source->index].u += g_slot_u_increment; if (slots[source->index].u >= 4.0f) slots[source->index].u -= 4.0f; - vec_scale_to_length(rot, source, g_rotation_length_scale * 0.020000001f); + vec_scale_to_length(rot, source, g_vaporizer_trail_step_speed * 0.020000001f); FastVecAdd(&slots[source->index], &slots[source->index], rot); FastVecAdd(&slots[source->index].a, &slots[source->index].a, rot); return 1; diff --git a/src/pal/levels/shared/L00_00436E20-g8.c b/src/pal/levels/shared/L00_00436E20-g8.c index a46eede6f..5b532b560 100644 --- a/src/pal/levels/shared/L00_00436E20-g8.c +++ b/src/pal/levels/shared/L00_00436E20-g8.c @@ -11,7 +11,7 @@ extern void prompt_bar_set_text_offsets_pal(void *, float, float, float, float, extern int menu_handle_page_input_c_pal(void *, int); extern int g_onoff_menu_prompt_ids[2] __attribute__((sda)); -extern int g_level_child_params_a[2] __attribute__((sda)); +extern int g_prompt_bar_params_a[2] __attribute__((sda)); /* Builds the first on/off menu page: allocates its cell, sets up the prompt bar with three texts and offsets. */ void menu_build_page_a_pal(char *object, void *parent) @@ -31,7 +31,7 @@ void menu_build_page_a_pal(char *object, void *parent) **(float **)(object + 0x2DC) = 255.0f; (*(float **)(object + 0x2DC))[1] = 195.0f; child = object + 8; - prompt_bar_init_pal(child, parent, g_level_child_params_a); + prompt_bar_init_pal(child, parent, g_prompt_bar_params_a); text_a = GetLocalizedString(0xB72); text_b = GetLocalizedString(0xB5F); prompt_bar_set_texts_pal(child, text_a, text_b, GetLocalizedString(0xB60)); @@ -45,7 +45,7 @@ void menu_build_page_a_pal(char *object, void *parent) extern int menu_update_two_part_flags_b_pal(void *, int); -extern int g_level_child_params_b[2] __attribute__((sda)); +extern int g_prompt_bar_params_b[2] __attribute__((sda)); /* Builds the text_b on/off menu page, the same as the first with its own parameters. */ void menu_build_page_b_pal(char *object, void *parent) @@ -65,7 +65,7 @@ void menu_build_page_b_pal(char *object, void *parent) **(float **)(object + 0x2DC) = 255.0f; (*(float **)(object + 0x2DC))[1] = 195.0f; child = object + 8; - prompt_bar_init_pal(child, parent, g_level_child_params_b); + prompt_bar_init_pal(child, parent, g_prompt_bar_params_b); text_a = GetLocalizedString(0xB72); text_b = GetLocalizedString(0xB5F); prompt_bar_set_texts_pal(child, text_a, text_b, GetLocalizedString(0xB60)); diff --git a/src/us2/levels/shared/L00_00432D98-g8.c b/src/us2/levels/shared/L00_00432D98-g8.c index b2c91ce3c..35a10e549 100644 --- a/src/us2/levels/shared/L00_00432D98-g8.c +++ b/src/us2/levels/shared/L00_00432D98-g8.c @@ -11,7 +11,7 @@ extern void prompt_bar_set_text_offsets_us2(void *, float, float, float, float, extern int menu_handle_page_input_c_us2(void *, int); extern int g_onoff_menu_prompt_ids[2] __attribute__((sda)); -extern int g_child_param_pair_e[2] __attribute__((sda)); +extern int g_prompt_bar_params_a[2] __attribute__((sda)); /* Initialises a menu page with a prompt bar of three texts (confirm, back, extra), a sizing cell and the page's first state. */ void menu_l00_init_page_record_g_us2(char *menu, void *parent) @@ -31,7 +31,7 @@ void menu_l00_init_page_record_g_us2(char *menu, void *parent) **(float **)(menu + 0x2DC) = 255.0f; (*(float **)(menu + 0x2DC))[1] = 195.0f; prompt_bar = menu + 8; - prompt_bar_init_us2(prompt_bar, parent, g_child_param_pair_e); + prompt_bar_init_us2(prompt_bar, parent, g_prompt_bar_params_a); first_text = GetLocalizedString(0x2BF7); second_text = GetLocalizedString(0x2BE4); prompt_bar_set_texts_us2(prompt_bar, first_text, second_text, GetLocalizedString(0x2BE5)); @@ -45,7 +45,7 @@ void menu_l00_init_page_record_g_us2(char *menu, void *parent) extern int menu_handle_page_input_e_us2(void *, int); -extern int g_child_param_pair_f[2] __attribute__((sda)); +extern int g_prompt_bar_params_b[2] __attribute__((sda)); /* Initialises a menu page with a prompt bar of three texts (confirm, back, extra), a sizing cell and the page's first state. */ void menu_l00_init_page_record_h_us2(char *menu, void *parent) @@ -65,7 +65,7 @@ void menu_l00_init_page_record_h_us2(char *menu, void *parent) **(float **)(menu + 0x2DC) = 255.0f; (*(float **)(menu + 0x2DC))[1] = 195.0f; prompt_bar = menu + 8; - prompt_bar_init_us2(prompt_bar, parent, g_child_param_pair_f); + prompt_bar_init_us2(prompt_bar, parent, g_prompt_bar_params_b); first_text = GetLocalizedString(0x2BF7); second_text = GetLocalizedString(0x2BE4); prompt_bar_set_texts_us2(prompt_bar, first_text, second_text, GetLocalizedString(0x2BE5)); @@ -79,7 +79,7 @@ void menu_l00_init_page_record_h_us2(char *menu, void *parent) extern int menu_handle_page_input_f_us2(void *, int); -extern int g_child_param_pair_g[2] __attribute__((sda)); +extern int g_prompt_bar_params_c[2] __attribute__((sda)); /* Initialises a menu page with a prompt bar of three texts (confirm, back, extra), a sizing cell and the page's first state. */ void menu_l00_init_page_record_i_us2(char *menu, void *parent) @@ -99,7 +99,7 @@ void menu_l00_init_page_record_i_us2(char *menu, void *parent) **(float **)(menu + 0x2DC) = 255.0f; (*(float **)(menu + 0x2DC))[1] = 195.0f; prompt_bar = menu + 8; - prompt_bar_init_us2(prompt_bar, parent, g_child_param_pair_g); + prompt_bar_init_us2(prompt_bar, parent, g_prompt_bar_params_c); first_text = GetLocalizedString(0x2BF7); second_text = GetLocalizedString(0x2BE4); prompt_bar_set_texts_us2(prompt_bar, first_text, second_text, GetLocalizedString(0x2BE5));