mirror of
https://github.com/Druthulu/BFM-decomp
synced 2026-09-26 13:33:34 -04:00
chore(decomp): commit in-tree banked work before the next gate
Uncommitted src/ changes found at gate entry. These are banked functions from a lane that gates with commit=False, not residue — preserved, not reverted. Top-level src/*.c (main TUs) are excluded by construction (S59).
This commit is contained in:
@@ -211,7 +211,24 @@ void func_800CB1BC(void *a0)
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_MAIN_022/nonmatchings/md_MAIN_022", func_800CB2F4);
|
||||
extern void func_80146CA0(s32);
|
||||
|
||||
void func_800CB2F4(void *a0) {
|
||||
void *a1;
|
||||
s16 v0;
|
||||
|
||||
a1 = *(void **)((s32)a0 + 0x20);
|
||||
*(u16 *)((s32)a0 + 0x60) += 0x60;
|
||||
v0 = *(u16 *)((s32)a1 + 0x1A) + 0x200;
|
||||
*(u16 *)((s32)a1 + 0x1A) = v0;
|
||||
*(u16 *)((s32)a1 + 0x18) = v0;
|
||||
if (v0 >= 0x1001) {
|
||||
*(u16 *)((s32)a1 + 0x1A) = 0x1000;
|
||||
*(u16 *)((s32)a1 + 0x18) = 0x1000;
|
||||
func_80146CA0((s32)a0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
extern void func_80146CA0(s32);
|
||||
extern s32 func_80146A6C(s32 a0, void *a1, s32 a2, s32 a3, s32 a4, s32 a5, s32 a6);
|
||||
|
||||
@@ -155,7 +155,28 @@ void func_800CB564(int param_1)
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_MAIN_028/nonmatchings/md_MAIN_028", func_800CB59C);
|
||||
extern u16 D_800B99DA;
|
||||
extern s32 func_80146E98(s32 a0);
|
||||
extern void func_800CB684(s32 a0, s32 a1);
|
||||
|
||||
void func_800CB59C(s32 a0) {
|
||||
s32 ptr;
|
||||
s32 v;
|
||||
|
||||
v = D_800B99DA & 1;
|
||||
ptr = *(s32 *)((s32)a0 + 0x20);
|
||||
if (v == 0) {
|
||||
v = 0x160;
|
||||
} else {
|
||||
v = 0x140;
|
||||
}
|
||||
*(u16 *)(ptr + 0x2A) = v;
|
||||
if (func_80146E98((s32)a0) != 0) {
|
||||
func_800CB684((s32)a0, 0x100);
|
||||
*(u16 *)((s32)a0 + 2) = 1;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
extern void func_80162CCC(void);
|
||||
s32 func_800CB600(void)
|
||||
|
||||
@@ -1147,7 +1147,28 @@ void func_800CC4E8(void *a0) {
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_MAIN_034/nonmatchings/md_MAIN_034", func_800CC5E4);
|
||||
void func_800CC5E4(void *a0) {
|
||||
void *a1;
|
||||
register s32 v0 __asm__("$2");
|
||||
s32 v1;
|
||||
s32 t;
|
||||
|
||||
a1 = *(void **)((u8 *)a0 + 0x20);
|
||||
*(u16 *)((u8 *)a1 + 0x1E) += 0x200;
|
||||
v0 = *(u16 *)((u8 *)a0 + 0x60) + 0xC0;
|
||||
*(u16 *)((u8 *)a0 + 0x60) = v0;
|
||||
v1 = *(u16 *)((u8 *)a1 + 0x1A) + v0;
|
||||
*(u16 *)((u8 *)a1 + 0x1A) = v1;
|
||||
__asm__ __volatile__("" ::: "memory");
|
||||
t = *(s16 *)((u8 *)a1 + 0x1A);
|
||||
*(u16 *)((u8 *)a1 + 0x18) = v1;
|
||||
if (t >= 0xC01) {
|
||||
*(u16 *)((u8 *)a1 + 0x1A) = 0xC00;
|
||||
*(u16 *)((u8 *)a1 + 0x18) = 0xC00;
|
||||
func_80146CA0(a0);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void func_800CC658(void *a0) {
|
||||
void *v1;
|
||||
|
||||
@@ -56,7 +56,28 @@ void func_800CCD30(void) {
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_MAIN_046/nonmatchings/md_MAIN_046", func_800CCD50);
|
||||
void func_800CCD50(void) {
|
||||
register void *a0 __asm__("$4");
|
||||
extern void func_80154274(s32 *a0, s32 a1);
|
||||
extern void func_80146D90(s32 a0);
|
||||
extern void func_800CCDB0(s32 *a0);
|
||||
extern M2C_UNK D_800CE010;
|
||||
s32 s0;
|
||||
s32 v0;
|
||||
u16 v1;
|
||||
|
||||
s0 = (s32)a0;
|
||||
func_80154274((s32 *)s0, (s32)&D_800CE010);
|
||||
v0 = *(s32 *)(s0 + 0x20);
|
||||
v1 = *(u16 *)(v0 + 0x12);
|
||||
*(u16 *)(s0 + 0x246) = 0x200;
|
||||
*(u16 *)(s0 + 0x244) = v1;
|
||||
func_80146D90(s0);
|
||||
func_800CCDB0((s32 *)s0);
|
||||
*(u16 *)(s0 + 0x240) = 0;
|
||||
func_80147324(0x8E4);
|
||||
}
|
||||
|
||||
|
||||
void func_800CCDB0(s32 *a0) {
|
||||
*(s32 *)((s32)a0 + 0x23C) = 0;
|
||||
@@ -249,7 +270,22 @@ void func_800CD1F4(s32 *a0) {
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_MAIN_046/nonmatchings/md_MAIN_046", func_800CD240);
|
||||
extern void func_801599A4(void *a0);
|
||||
extern void func_80159B3C(void *a0);
|
||||
|
||||
s32 func_800CD240(void *arg0) {
|
||||
s32 s0;
|
||||
|
||||
s0 = (s32)arg0;
|
||||
__asm__ __volatile__("" : "=r"(s0) : "0"(s0));
|
||||
if (*(s16 *)(s0 + 0x1C8) != 0) {
|
||||
return 0;
|
||||
}
|
||||
func_801599A4((void *)s0);
|
||||
func_80159B3C((void *)s0);
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_MAIN_046/nonmatchings/md_MAIN_046", func_800CD288);
|
||||
|
||||
|
||||
@@ -218,7 +218,14 @@ void func_801E2ACC(void *a0) {
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_SC03_136/nonmatchings/md_SC03_136", func_801E2B08);
|
||||
void func_801E2B08(void) {
|
||||
extern void func_801E2B30(s32 param_1, s16 *param_2);
|
||||
extern s16 D_801274E8;
|
||||
s32 x;
|
||||
|
||||
func_801E2B30(x, &D_801274E8);
|
||||
}
|
||||
|
||||
|
||||
typedef struct { short vx, vy, vz, pad; } SVECTOR;
|
||||
typedef struct { short m[3][3]; long t[3]; } MATRIX;
|
||||
|
||||
@@ -220,7 +220,13 @@ void func_801E7FF8(void *a0) {
|
||||
}
|
||||
|
||||
|
||||
INCLUDE_ASM("asm/md_SC04_029/nonmatchings/md_SC04_029", func_801E8034);
|
||||
extern void func_801E805C(s32 param_1, s16 *param_2);
|
||||
|
||||
void func_801E8034(s32 param_1) {
|
||||
extern s16 D_801274E8;
|
||||
func_801E805C(param_1, &D_801274E8);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* MATRIX 0x20: short m[3][3] @0x00 (18B) + 2B pad, long t[3] @0x14 (PsyQ layout) */
|
||||
|
||||
Reference in New Issue
Block a user