From c274fd455daed374c099343bb6623b5e1b2cfaf7 Mon Sep 17 00:00:00 2001 From: csaldiasdev Date: Sun, 5 Jul 2026 20:20:39 -0400 Subject: [PATCH] =?UTF-8?q?rename:=20literal=200x98=20=E2=86=92=20SPECIES?= =?UTF-8?q?=5FBLANK=20in=20373A0.c?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Four sites in func_800367A0 (case 0x33 and case 0x32) where arg1 (a species ID) is checked against the upper-bound sentinel before decrementing to a 0-indexed array. Introduces #include "pokemon.h" in this file. Other 0x98 occurrences in 373A0.c (lines 24, 31, 41) are D_80077970[] data table entries (per-species animation/sound parameter values), not species IDs — left untouched. Callers: func_80048408-area (src/3D140.c:857, etc.) Still matching: md5 ed1378bc… (verified by `make`) --- src/373A0.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/373A0.c b/src/373A0.c index 638dee0..334abb1 100644 --- a/src/373A0.c +++ b/src/373A0.c @@ -1,4 +1,5 @@ #include "373A0.h" +#include "include/pokemon.h" #include "src/4CBC0.h" #include "src/373A0.h" #include "src/3D140.h" @@ -210,11 +211,11 @@ s32 func_800367A0(u32 arg0, s32 arg1, s32 arg2) { return 0; case 0x33: - if (arg1 >= 0x98) { + if (arg1 >= SPECIES_BLANK) { arg1 = 3; } - if ((arg1 > 0) && (arg1 < 0x98)) { + if ((arg1 > 0) && (arg1 < SPECIES_BLANK)) { arg1--; } else { arg1 = 0; @@ -242,11 +243,11 @@ s32 func_800367A0(u32 arg0, s32 arg1, s32 arg2) { return func_80039024(D_800FC6A4, D_800FC6A8, 0x20, 0x80, 0x80, -1); } - if (arg1 >= 0x98) { + if (arg1 >= SPECIES_BLANK) { arg1 = 2; } - if ((arg1 > 0) && (arg1 < 0x98)) { + if ((arg1 > 0) && (arg1 < SPECIES_BLANK)) { arg1--; } else { arg1 = 0;