diff --git a/splat.yaml b/splat.yaml index 6b822a9..a106d2f 100644 --- a/splat.yaml +++ b/splat.yaml @@ -115,9 +115,9 @@ segments: - [0x18F30, asm] - [0x18F80, asm] - [0x19050, c, "_ob_past_brick"] - - [0x19DD0, asm] + - [0x19DD0, c, "_ob_questionable_glass"] - [0x19E10, asm] - - [0x19E30, asm] + - [0x19E30, c, "_ob_yielding_ice"] - [0x19EB0, asm] - [0x19FC0, c, "black"] - [0x1A050, c, "_ob_icy_coast"] diff --git a/src/5C060.c b/src/5C060.c deleted file mode 100644 index b872712..0000000 --- a/src/5C060.c +++ /dev/null @@ -1,64 +0,0 @@ -#include "common.h" - -/* 5C060 80186160 */ -void func_80186160(void) { - D_80197168[0] |= 1; -} - -/* 5C078 80186178 */ -void func_80186178(void) { - D_80197168[0] &= 0xFE; -} - -/* 5C090 80186190 */ -void func_80186190(s32 arg0, s32 arg1) { - if (arg1 != 0) { - s32 var_a1 = ((arg0 >= 0) ? arg0 : arg0 + 7); - D_80197168[(var_a1 >> 3)] = D_80197168[(var_a1 >> 3)] | (1 << (arg0 - ((var_a1 >> 3) * 8))); - } else { - s32 var_a1_3 = (arg0 >= 0) ? arg0 : arg0 + 7; - D_80197168[(var_a1_3 >> 3)] = D_80197168[(var_a1_3 >> 3)] & ~(1 << (arg0 - ((var_a1_3 >> 3) * 8))); - } -} - -/* 5C110 80186210 */ -s32 func_80186210(s32 arg0) { - s32 var_v1 = (arg0 >= 0 ? arg0 : arg0 + 7); - - return (D_80197168[(var_v1 >> 3)] >> (arg0 - ((var_v1 >> 3) * 8))) & 1; -} - -/* 5C140 80186240 */ -s32 func_80186240(s32 arg0) { - s32 temp_v1; - s32 var_v0; - s32 var_v1; - - if(arg0 == -1) - return 1; - - var_v1 = arg0; - if (arg0 < 0) { - var_v1 = arg0 + 7; - } - temp_v1 = var_v1 >> 3; - return ((D_80197AE7[temp_v1] >> (arg0 - (temp_v1 * 8))) & 1) ^ 1; -} - - -/* 5C184 80186284 */ -void func_80186284(s32 arg0) { - D_80196F58 = arg0; -} - - -/* 5C190 80186290 */ -void func_80186290(void) { - D_801951A1 |= 1; -} - -/* 5C1A8 801862A8 */ -void func_801862A8(void) { - bzero(&D_80197AE7, 8); -} - diff --git a/src/19DD0.c b/src/_ob_questionable_glass.c similarity index 88% rename from src/19DD0.c rename to src/_ob_questionable_glass.c index c4b43f7..5d29d64 100644 --- a/src/19DD0.c +++ b/src/_ob_questionable_glass.c @@ -1,9 +1,10 @@ #include "common.h" +/* 19DD0 800899D0 */ void set_swap_buffer_func(void (*arg0)(void**)) { s32 mask; mask = osSetIntMask(OS_IM_NONE); SWAP_BUFFER_FUNC = arg0; osSetIntMask(mask); -} +} \ No newline at end of file diff --git a/src/19E30.c b/src/_ob_yielding_ice.c similarity index 94% rename from src/19E30.c rename to src/_ob_yielding_ice.c index c09581b..a1e830a 100644 --- a/src/19E30.c +++ b/src/_ob_yielding_ice.c @@ -1,5 +1,6 @@ #include "common.h" +/* 19E30 80089A30 */ void __dma_load_loop(s32 count) { Stack__dma_load_loop sp10; OSMesgQueue mq; diff --git a/src/segment_obdata/_ob_hallowed_class.c b/src/segment_obdata/_ob_hallowed_class.c index 7541278..b872712 100644 --- a/src/segment_obdata/_ob_hallowed_class.c +++ b/src/segment_obdata/_ob_hallowed_class.c @@ -1,17 +1,64 @@ #include "common.h" -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186160); +/* 5C060 80186160 */ +void func_80186160(void) { + D_80197168[0] |= 1; +} -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186178); +/* 5C078 80186178 */ +void func_80186178(void) { + D_80197168[0] &= 0xFE; +} -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186190); +/* 5C090 80186190 */ +void func_80186190(s32 arg0, s32 arg1) { + if (arg1 != 0) { + s32 var_a1 = ((arg0 >= 0) ? arg0 : arg0 + 7); + D_80197168[(var_a1 >> 3)] = D_80197168[(var_a1 >> 3)] | (1 << (arg0 - ((var_a1 >> 3) * 8))); + } else { + s32 var_a1_3 = (arg0 >= 0) ? arg0 : arg0 + 7; + D_80197168[(var_a1_3 >> 3)] = D_80197168[(var_a1_3 >> 3)] & ~(1 << (arg0 - ((var_a1_3 >> 3) * 8))); + } +} -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186210); +/* 5C110 80186210 */ +s32 func_80186210(s32 arg0) { + s32 var_v1 = (arg0 >= 0 ? arg0 : arg0 + 7); -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186240); + return (D_80197168[(var_v1 >> 3)] >> (arg0 - ((var_v1 >> 3) * 8))) & 1; +} -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186284); +/* 5C140 80186240 */ +s32 func_80186240(s32 arg0) { + s32 temp_v1; + s32 var_v0; + s32 var_v1; -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_80186290); + if(arg0 == -1) + return 1; + + var_v1 = arg0; + if (arg0 < 0) { + var_v1 = arg0 + 7; + } + temp_v1 = var_v1 >> 3; + return ((D_80197AE7[temp_v1] >> (arg0 - (temp_v1 * 8))) & 1) ^ 1; +} + + +/* 5C184 80186284 */ +void func_80186284(s32 arg0) { + D_80196F58 = arg0; +} + + +/* 5C190 80186290 */ +void func_80186290(void) { + D_801951A1 |= 1; +} + +/* 5C1A8 801862A8 */ +void func_801862A8(void) { + bzero(&D_80197AE7, 8); +} -INCLUDE_ASM(const s32, "segment_obdata/_ob_hallowed_class", func_801862A8);