mirror of
https://github.com/jiangzhengwenjz/katam.git
synced 2024-11-26 22:50:39 +00:00
decompile more data
This commit is contained in:
parent
afa68e9e24
commit
401de65d45
10
data/chest.s
Normal file
10
data/chest.s
Normal file
@ -0,0 +1,10 @@
|
||||
.include "asm/macros.inc"
|
||||
.include "constants/constants.inc"
|
||||
|
||||
.section .rodata
|
||||
|
||||
gUnk_082D9244:: @ 082D9244
|
||||
.incbin "baserom.gba", 0x2D9244, 0x0000010
|
||||
|
||||
gUnk_082D9254:: @ 082D9254
|
||||
.incbin "baserom.gba", 0x2D9254, 0x0000010
|
@ -9811,10 +9811,7 @@ gUnk_082D1600:: @ 082D1600
|
||||
.incbin "baserom.gba", 0x2D1600, 0x0000040
|
||||
|
||||
gUnk_082D1640:: @ 082D1640
|
||||
.incbin "baserom.gba", 0x2D1640, 0x00011C6
|
||||
|
||||
gUnk_082D2806:: @ 082D2806
|
||||
.incbin "baserom.gba", 0x2D2806, 0x00001C2
|
||||
.incbin "baserom.gba", 0x2D1640, 0x0001388
|
||||
|
||||
gUnk_082D29C8:: @ 082D29C8
|
||||
.incbin "baserom.gba", 0x2D29C8, 0x00004B0
|
||||
@ -9866,75 +9863,3 @@ gUnk_082D7850:: @ 082D7850
|
||||
|
||||
gUnk_082D83FC:: @ 082D83FC
|
||||
.incbin "baserom.gba", 0x2D83FC, 0x0000090
|
||||
|
||||
gUnk_082D848C:: @ 082D848C
|
||||
.incbin "baserom.gba", 0x2D848C, 0x000000C
|
||||
|
||||
gUnk_082D8498:: @ 082D8498
|
||||
.incbin "baserom.gba", 0x2D8498, 0x00002D0
|
||||
|
||||
gUnk_082D8768:: @ 082D8768
|
||||
.incbin "baserom.gba", 0x2D8768, 0x0000150
|
||||
|
||||
gUnk_082D88B8:: @ 082D88B8
|
||||
.incbin "baserom.gba", 0x2D88B8, 0x0000400
|
||||
|
||||
gUnk_082D8CB8:: @ 082D8CB8
|
||||
.incbin "baserom.gba", 0x2D8CB8, 0x0000008
|
||||
|
||||
gUnk_082D8CC0:: @ 082D8CC0
|
||||
.incbin "baserom.gba", 0x2D8CC0, 0x0000010
|
||||
|
||||
gUnk_082D8CD0:: @ 082D8CD0
|
||||
.incbin "baserom.gba", 0x2D8CD0, 0x0000020
|
||||
|
||||
gUnk_082D8CF0:: @ 082D8CF0
|
||||
.incbin "baserom.gba", 0x2D8CF0, 0x0000008
|
||||
|
||||
gUnk_082D8CF8:: @ 082D8CF8
|
||||
.incbin "baserom.gba", 0x2D8CF8, 0x0000010
|
||||
|
||||
gUnk_082D8D08:: @ 082D8D08
|
||||
.incbin "baserom.gba", 0x2D8D08, 0x0000020
|
||||
|
||||
gUnk_082D8D28:: @ 082D8D28
|
||||
.incbin "baserom.gba", 0x2D8D28, 0x0000008
|
||||
|
||||
gUnk_082D8D30:: @ 082D8D30
|
||||
.incbin "baserom.gba", 0x2D8D30, 0x0000010
|
||||
|
||||
gUnk_082D8D40:: @ 082D8D40
|
||||
.incbin "baserom.gba", 0x2D8D40, 0x0000020
|
||||
|
||||
gUnk_082D8D60:: @ 082D8D60
|
||||
.incbin "baserom.gba", 0x2D8D60, 0x0000014
|
||||
|
||||
gUnk_082D8D74:: @ 082D8D74
|
||||
.incbin "baserom.gba", 0x2D8D74, 0x0000030
|
||||
|
||||
gUnk_082D8DA4:: @ 082D8DA4
|
||||
.incbin "baserom.gba", 0x2D8DA4, 0x0000400
|
||||
|
||||
gUnk_082D91A4:: @ 082D91A4
|
||||
.incbin "baserom.gba", 0x2D91A4, 0x0000018
|
||||
|
||||
gUnk_082D91BC:: @ 082D91BC
|
||||
.incbin "baserom.gba", 0x2D91BC, 0x0000018
|
||||
|
||||
gSpawnFuncTable2:: @ 082D91D4
|
||||
.4byte NULL, NULL, NULL, NULL
|
||||
|
||||
gUnk_082D91E4:: @ 082D91E4
|
||||
.incbin "baserom.gba", 0x2D91E4, 0x0000018
|
||||
|
||||
gUnk_082D91FC:: @ 082D91FC
|
||||
.incbin "baserom.gba", 0x2D91FC, 0x0000040
|
||||
|
||||
gUnk_082D923C:: @ 082D923C
|
||||
.4byte sub_0800AD10, sub_0800AD1C
|
||||
|
||||
gUnk_082D9244:: @ 082D9244
|
||||
.incbin "baserom.gba", 0x2D9244, 0x0000010
|
||||
|
||||
gUnk_082D9254:: @ 082D9254
|
||||
.incbin "baserom.gba", 0x2D9254, 0x0000010
|
||||
|
9
graphics/corrupted_save/palette.pal
Normal file
9
graphics/corrupted_save/palette.pal
Normal file
@ -0,0 +1,9 @@
|
||||
JASC-PAL
|
||||
0100
|
||||
6
|
||||
0 255 255
|
||||
230 238 164
|
||||
255 0 0
|
||||
98 74 230
|
||||
255 255 255
|
||||
0 0 0
|
BIN
graphics/corrupted_save/tilemap.bin
Normal file
BIN
graphics/corrupted_save/tilemap.bin
Normal file
Binary file not shown.
BIN
graphics/corrupted_save/tileset.png
Normal file
BIN
graphics/corrupted_save/tileset.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.6 KiB |
@ -0,0 +1,2 @@
|
||||
graphics/corrupted_save/tileset.4bpp: %.4bpp: %.png
|
||||
$(GFX) $< $@ -num_tiles 97 -Wnum_tiles
|
14
include/code_08019CB8.h
Normal file
14
include/code_08019CB8.h
Normal file
@ -0,0 +1,14 @@
|
||||
#ifndef GUARD_CODE_08019CB8_H
|
||||
#define GUARD_CODE_08019CB8_H
|
||||
|
||||
#include "global.h"
|
||||
|
||||
struct Unk_02038960 {
|
||||
u8 unk0[0x10];
|
||||
u32 unk10[4];
|
||||
u16 unk20;
|
||||
}; /* size = 0x24 */
|
||||
|
||||
extern struct Unk_02038960 gUnk_02038960;
|
||||
|
||||
#endif
|
@ -603,9 +603,9 @@ extern u8 gUnk_02024ED0[][1950];
|
||||
extern u16 gUnk_02026D50[];
|
||||
extern u8 gUnk_02026D60[][1954];
|
||||
|
||||
extern u8 gUnk_02028BF0[];
|
||||
extern u32 gUnk_02028C10[];
|
||||
extern u16 gUnk_02028CA0[];
|
||||
extern u8 gUnk_02028BF0[0x20];
|
||||
extern u32 gUnk_02028C10[0x20];
|
||||
extern u16 gUnk_02028CA0[0x120];
|
||||
|
||||
extern u8 gUnk_02028EE0[][1950 * 8];
|
||||
|
||||
@ -619,6 +619,7 @@ extern struct LevelInfo gCurLevelInfo[4];
|
||||
extern u16 gUnk_020382C8[5][4];
|
||||
extern u32 gUnk_02038580;
|
||||
extern struct Unk_02038590 gUnk_02038590[4];
|
||||
|
||||
extern u16 gUnk_02038990[][2];
|
||||
extern u32 gUnk_0203AD10;
|
||||
extern u8 gUnk_0203AD14;
|
||||
@ -680,20 +681,14 @@ struct Unk_3007DE0 {
|
||||
extern const struct LevelInfo_1A0* gUnk_082D7850[];
|
||||
extern const u32 gUnk_082D88B8[];
|
||||
extern const u16 gUnk_082D8CB8[];
|
||||
extern const u16 gUnk_082D8CF0[];
|
||||
extern const u32 gUnk_082D8CF8[];
|
||||
extern const s32 gUnk_082D8D08[][2];
|
||||
extern const bool32 gUnk_082D8CC0[];
|
||||
extern const s32 gUnk_082D8CD0[][2];
|
||||
extern const u16 gUnk_082D8CF0[];
|
||||
extern const s32 gUnk_082D8D08[][2];
|
||||
extern const u16 gUnk_082D8D28[];
|
||||
extern const bool32 gUnk_082D8D30[];
|
||||
extern const s32 gUnk_082D8D40[][2];
|
||||
|
||||
extern u16 (*const gUnk_082D8DA4[])(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
|
||||
extern const s16 gUnk_082D91A4[4][3];
|
||||
extern const s16 gUnk_082D91BC[4][3];
|
||||
|
||||
extern void *(*const gSpawnFuncTable2[])(const struct Object *, u8);
|
||||
extern void *(*const gSpawnFuncTable1[])(const struct Object *, u8);
|
||||
|
||||
@ -818,7 +813,7 @@ struct Unk_08002E48 {
|
||||
}; /* size = 0x28 */
|
||||
|
||||
|
||||
extern void (*const gUnk_082D8D60[2])(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
extern void (*const gUnk_082D8D60[])(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
|
||||
struct Unk_08D6CD0C {
|
||||
const u16 *const *unk0;
|
||||
|
@ -22,7 +22,6 @@ u32 sub_080017E8(struct ObjectBase *);
|
||||
u32 sub_08001894(struct ObjectBase *);
|
||||
u32 sub_08001940(struct ObjectBase *);
|
||||
void sub_080019F8(struct LevelInfo *);
|
||||
void sub_08001C40(u32, struct LevelInfo *);
|
||||
void sub_08001D18(u8 playerId);
|
||||
void sub_08001FF8(void);
|
||||
void sub_08002118(void);
|
||||
@ -72,9 +71,6 @@ void sub_08002D40(u16, u8 *, u8 *); // TODO: a2 and a3 are not consistent with K
|
||||
|
||||
void sub_08002C98(u16, u16 *, u32 *, u32 *);
|
||||
void sub_08002D40(u16, u8 *, u8 *);
|
||||
void sub_08002D60(u32, struct LevelInfo *);
|
||||
void sub_08002DA0(u32, struct LevelInfo *);
|
||||
void sub_08002DFC(u8, struct LevelInfo *);
|
||||
void sub_08002E3C(void);
|
||||
void sub_08002E48(struct Task *);
|
||||
|
||||
|
@ -70,15 +70,6 @@ struct Multi_08032B0C
|
||||
u16 unk58;
|
||||
}; /* size = 0x5C */
|
||||
|
||||
struct Multi_082D91FC
|
||||
{
|
||||
u8 *unk0;
|
||||
u32 unk4;
|
||||
}; /* size = 0x8 */
|
||||
|
||||
extern const struct Multi_082D91FC gUnk_082D91E4[];
|
||||
extern const struct Multi_082D91FC gUnk_082D91FC[];
|
||||
|
||||
extern struct Unk_020382A0 gUnk_020382A0;
|
||||
|
||||
void sub_08030C94(u8, union Unk_020382A0_8 *);
|
||||
|
@ -9,6 +9,16 @@ struct Unk_0800A96C {
|
||||
u16 a, b, c, d;
|
||||
}; /* size = 8 */
|
||||
|
||||
|
||||
struct Multi_082D91FC
|
||||
{
|
||||
u8 *unk0;
|
||||
u32 unk4;
|
||||
}; /* size = 0x8 */
|
||||
|
||||
extern const struct Multi_082D91FC gUnk_082D91E4[];
|
||||
extern const struct Multi_082D91FC gUnk_082D91FC[];
|
||||
|
||||
s16 sub_0800A91C(s32, u16);
|
||||
void sub_0800A96C(s32 , struct Unk_0800A96C *);
|
||||
s16 sub_0800A9F4(s32, u16);
|
||||
|
@ -410,6 +410,10 @@ SECTIONS {
|
||||
*libc.a:memcpy.o(.text);
|
||||
*libc.a:memset.o(.text);
|
||||
data/data_1.o(.rodata);
|
||||
src/init.o(.rodata);
|
||||
src/code_080023A4.o(.rodata);
|
||||
src/save.o(.rodata);
|
||||
data/chest.o(.rodata);
|
||||
src/warp_star.o(.rodata);
|
||||
src/code_0800E0E4.o(.rodata);
|
||||
src/code_0800ECAC.o(.rodata);
|
||||
|
@ -8,6 +8,445 @@
|
||||
|
||||
// TODO: define file boundaries
|
||||
|
||||
static void sub_08001C40(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
static void sub_08002D60(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
static void sub_08002DA0(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
static void nullsub_10(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
static void sub_08002DFC(struct Unk_08002E48 *, struct LevelInfo *);
|
||||
static u16 sub_08006960(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08006B90(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08006CCC(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08006DF8(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800705C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_080072BC(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08007528(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08007720(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800798C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08007B84(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08007DE0(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08008038(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08008298(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08008484(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_080086E0(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_080088CC(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08008C04(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800913C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009674(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_080099C4(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E08(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E0C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E20(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E34(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E48(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E5C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E70(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E84(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009E98(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009EAC(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009EC0(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009ED4(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009EE8(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009EFC(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F10(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F24(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F38(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F4C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F60(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F74(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F88(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009F9C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009FB0(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009FC4(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009FD8(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_08009FEC(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A000(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A014(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A028(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A03C(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A050(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A064(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
static u16 sub_0800A078(struct Kirby *, struct Unk_3007DE0 *, u16);
|
||||
|
||||
const u32 gUnk_082D88B8[] = {
|
||||
0x1, 0xB0000000, 0xC0000000, 0x80000000, 0x70000000, 0x10000000, 0x20000000, 0x60000000,
|
||||
0x50000000, 0xA0000000, 0x90000000, 0x30000000, 0x40000000, 0x200, 0xC, 0x4,
|
||||
0x1000000C, 0x2000000C, 0x6000000C, 0x5000000C, 0x10000004, 0x20000004, 0x60000004, 0x50000004,
|
||||
0x3000000C, 0x4000000C, 0x30000004, 0x40000004, 0x1002001, 0x2002001, 0x4002001, 0x8002001,
|
||||
0x10C, 0x101, 0x200, 0x200, 0x200, 0x200, 0x200, 0x200,
|
||||
0x1000801, 0x2000801, 0x4000801, 0x8000801, 0x1000803, 0x2000803, 0x4000803, 0x8000803,
|
||||
0x5000803, 0x9000803, 0xA000803, 0x6000803, 0xA0000002, 0xA0000002, 0x90000002, 0x90000002,
|
||||
0x30000002, 0x30000002, 0x40000002, 0x40000002, 0xB0000002, 0xC0000002, 0x80000002, 0x70000002,
|
||||
0x10000002, 0x20000002, 0x60000002, 0x50000002, 0xA0000002, 0x90000002, 0x30000002, 0x40000002,
|
||||
0x3, 0x6, 0x10000010, 0x20000010, 0x60000010, 0x50000010, 0x30000010, 0x40000010,
|
||||
0x210, 0x1100801, 0x2100801, 0x4100801, 0x8100801, 0x1200801, 0x2200801, 0x4200801,
|
||||
0x8200801, 0xC000401, 0x102200, 0x102001, 0x81, 0x202200, 0x202001, 0x1100803,
|
||||
0x2100803, 0x4100803, 0x8100803, 0x1200803, 0x2200803, 0x4200803, 0x8200803, 0x4008A00,
|
||||
0x8008A00, 0x4108A00, 0x8108A00, 0x4208A00, 0x8208A00, 0x1002003, 0x2002003, 0x4002003,
|
||||
0x8002003, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0,
|
||||
0x1200, 0x101260, 0x240, 0x41, 0x101200, 0x201200, 0x301220, 0x401200,
|
||||
0x0, 0x0, 0x0, 0x0, 0x104002, 0x4002, 0x104001, 0x4001,
|
||||
};
|
||||
|
||||
const u16 gUnk_082D8CB8[] = {
|
||||
0x323, 0x323, 0x323, 0x323
|
||||
};
|
||||
|
||||
const bool32 gUnk_082D8CC0[] = {
|
||||
FALSE, FALSE, FALSE, FALSE
|
||||
};
|
||||
|
||||
const s32 gUnk_082D8CD0[][2] = {
|
||||
{ 0x6000, 0x9000 },
|
||||
{ 0x5000, 0x9000 },
|
||||
{ 0x4000, 0x9000 },
|
||||
{ 0x3000, 0x9000 },
|
||||
};
|
||||
|
||||
const u16 gUnk_082D8CF0[] = {
|
||||
0x321, 0x321, 0x321, 0x321
|
||||
};
|
||||
|
||||
const u32 gUnk_082D8CF8[] = {
|
||||
0, 0, 0, 0
|
||||
};
|
||||
|
||||
const s32 gUnk_082D8D08[][2] = {
|
||||
{ 0x6000, 0x1000 },
|
||||
{ 0x5000, 0x1000 },
|
||||
{ 0x4000, 0x1000 },
|
||||
{ 0x3000, 0x1000 },
|
||||
};
|
||||
|
||||
const u16 gUnk_082D8D28[] = {
|
||||
0x321, 0x321, 0x321, 0x321
|
||||
};
|
||||
|
||||
const bool32 gUnk_082D8D30[] = {
|
||||
FALSE, TRUE, FALSE, TRUE
|
||||
};
|
||||
|
||||
const s32 gUnk_082D8D40[][2] = {
|
||||
{ 0xF000, 0xF000 },
|
||||
{ 0x11000, 0xF000 },
|
||||
{ 0xD000, 0xF000 },
|
||||
{ 0x13000, 0xF000 },
|
||||
};
|
||||
|
||||
void (*const gUnk_082D8D60[])(struct Unk_08002E48 *, struct LevelInfo *) = {
|
||||
sub_08001C40,
|
||||
sub_08002D60,
|
||||
sub_08002DA0,
|
||||
nullsub_10,
|
||||
sub_08002DFC,
|
||||
};
|
||||
|
||||
struct LevelInfo_1A0 *const gUnk_082D8D74[] = {
|
||||
&gCurLevelInfo[0].unk180[0],
|
||||
&gCurLevelInfo[1].unk180[0],
|
||||
&gCurLevelInfo[2].unk180[0],
|
||||
&gCurLevelInfo[3].unk180[0],
|
||||
&gCurLevelInfo[0].unk180[1],
|
||||
&gCurLevelInfo[1].unk180[1],
|
||||
&gCurLevelInfo[2].unk180[1],
|
||||
&gCurLevelInfo[3].unk180[1],
|
||||
&gCurLevelInfo[0].unk180[2],
|
||||
&gCurLevelInfo[1].unk180[2],
|
||||
&gCurLevelInfo[2].unk180[2],
|
||||
&gCurLevelInfo[3].unk180[2],
|
||||
};
|
||||
|
||||
u16 (*const gUnk_082D8DA4[])(struct Kirby *, struct Unk_3007DE0 *, u16) = {
|
||||
sub_08006960,
|
||||
sub_08009E20,
|
||||
sub_08009E34,
|
||||
sub_08009E5C,
|
||||
sub_08009E48,
|
||||
sub_08009E70,
|
||||
sub_08009E84,
|
||||
sub_08009EAC,
|
||||
sub_08009E98,
|
||||
sub_08009ED4,
|
||||
sub_08009EC0,
|
||||
sub_08009EE8,
|
||||
sub_08009EFC,
|
||||
sub_08009E0C,
|
||||
sub_08006B90,
|
||||
sub_08006CCC,
|
||||
sub_080072BC,
|
||||
sub_08007528,
|
||||
sub_0800798C,
|
||||
sub_08007720,
|
||||
sub_08008038,
|
||||
sub_08008298,
|
||||
sub_080086E0,
|
||||
sub_08008484,
|
||||
sub_08006DF8,
|
||||
sub_0800705C,
|
||||
sub_08007B84,
|
||||
sub_08007DE0,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006B90,
|
||||
sub_08006960,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_08009ED4,
|
||||
sub_08009ED4,
|
||||
sub_08009EC0,
|
||||
sub_08009EC0,
|
||||
sub_08009EE8,
|
||||
sub_08009EE8,
|
||||
sub_08009EFC,
|
||||
sub_08009EFC,
|
||||
sub_08009E20,
|
||||
sub_08009E34,
|
||||
sub_08009E5C,
|
||||
sub_08009E48,
|
||||
sub_08009F10,
|
||||
sub_08009F24,
|
||||
sub_08009F4C,
|
||||
sub_08009F38,
|
||||
sub_08009ED4,
|
||||
sub_08009EC0,
|
||||
sub_08009F60,
|
||||
sub_08009F74,
|
||||
sub_080099C4,
|
||||
sub_08009E0C,
|
||||
sub_08009F88,
|
||||
sub_08009F9C,
|
||||
sub_08009FC4,
|
||||
sub_08009FB0,
|
||||
sub_08009FD8,
|
||||
sub_08009FEC,
|
||||
sub_0800A000,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_080088CC,
|
||||
sub_08008C04,
|
||||
sub_08006960,
|
||||
sub_08009674,
|
||||
sub_0800913C,
|
||||
sub_08006960,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_080099C4,
|
||||
sub_0800A014,
|
||||
sub_0800A028,
|
||||
sub_0800A03C,
|
||||
sub_0800A050,
|
||||
sub_0800A064,
|
||||
sub_0800A078,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08006960,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E0C,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08009E08,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
sub_08006960,
|
||||
};
|
||||
|
||||
const s16 gUnk_082D91A4[4][3] = {
|
||||
{ -0x100, -0x200, -0x280 },
|
||||
{ 0x180, 0x280, 0x400 },
|
||||
{ 0x100, 0x200, 0x280 },
|
||||
{ -0x100, -0x150, -0x300 },
|
||||
};
|
||||
|
||||
const s16 gUnk_082D91BC[4][3] = {
|
||||
{ -0xA0, -0x110, -0x180 },
|
||||
{ 0x180, 0x200, 0x280 },
|
||||
{ 0xA0, 0x110, 0x180 },
|
||||
{ -0xA0, -0x100, -0x180 },
|
||||
};
|
||||
|
||||
void *(*const gSpawnFuncTable2[])(const struct Object *, u8) = {
|
||||
NULL, NULL, NULL, NULL
|
||||
};
|
||||
|
||||
#define Macro_08004008(arg0, arg1, arg2, arg3) ({ \
|
||||
u8 _ugh = sub_08002470( \
|
||||
(arg0)->base.base.base.unk56, \
|
||||
@ -467,7 +906,7 @@ void sub_080019F8(struct LevelInfo *arg0)
|
||||
}
|
||||
}
|
||||
|
||||
void sub_08001C40(u32 arg0, struct LevelInfo *levelInfo)
|
||||
static void sub_08001C40(struct Unk_08002E48 *arg0, struct LevelInfo *levelInfo)
|
||||
{
|
||||
bool32 var0 = FALSE, var1 = FALSE;
|
||||
struct Kirby *kirby = gKirbys + levelInfo->unk660;
|
||||
@ -1247,7 +1686,7 @@ void sub_08002D40(u16 arg0, u8 *arg1, u8 *arg2)
|
||||
*arg2 = gUnk_0893CB44[arg0][1];
|
||||
}
|
||||
|
||||
void sub_08002D60(u32 arg0, struct LevelInfo *levelInfo)
|
||||
static void sub_08002D60(struct Unk_08002E48 *arg0, struct LevelInfo *levelInfo)
|
||||
{
|
||||
struct ObjectBase *var0 = &gKirbys[levelInfo->unk660].base.base.base;
|
||||
|
||||
@ -1257,7 +1696,7 @@ void sub_08002D60(u32 arg0, struct LevelInfo *levelInfo)
|
||||
sub_08002DA0(arg0, levelInfo);
|
||||
}
|
||||
|
||||
void sub_08002DA0(u32 arg0, struct LevelInfo *levelInfo)
|
||||
static void sub_08002DA0(struct Unk_08002E48 *arg0 __attribute__((unused)), struct LevelInfo *levelInfo)
|
||||
{
|
||||
s32 var0 = levelInfo->unkC + levelInfo->unk1C;
|
||||
s32 var1 = levelInfo->unk10 + levelInfo->unk20;
|
||||
@ -1279,9 +1718,9 @@ void sub_08002DA0(u32 arg0, struct LevelInfo *levelInfo)
|
||||
levelInfo->unk20 -= var1 - levelInfo->unk78;
|
||||
}
|
||||
|
||||
static void nullsub_10(void) {}
|
||||
static void nullsub_10(struct Unk_08002E48 *arg0 __attribute__((unused)), struct LevelInfo *arg1 __attribute__((unused))) {}
|
||||
|
||||
void sub_08002DFC(u8 arg0, struct LevelInfo *arg1)
|
||||
static void sub_08002DFC(struct Unk_08002E48 *arg0, struct LevelInfo *arg1)
|
||||
{
|
||||
struct LevelInfo *var0 = gCurLevelInfo + arg1->unk661;
|
||||
|
||||
@ -5395,8 +5834,8 @@ u8 sub_08009DC8(struct Kirby *arg0) { return sub_0800385C(arg0, 0x4); }
|
||||
u8 sub_08009DD8(struct Kirby *arg0) { return sub_0800385C(arg0, 0x0); }
|
||||
u8 sub_08009DE8(struct Kirby *arg0) { return sub_0800385C(arg0, 0x1); }
|
||||
u8 sub_08009DF8(struct Kirby *arg0) { return sub_0800385C(arg0, 0x2); }
|
||||
u8 sub_08009E08(struct Kirby *arg0) { return 0xF; }
|
||||
|
||||
static u16 sub_08009E08(struct Kirby *arg0 __attribute__((unused)), struct Unk_3007DE0 *arg1 __attribute__((unused)), u16 arg2 __attribute__((unused))) { return 0xF; }
|
||||
static u16 sub_08009E0C(struct Kirby *arg0, struct Unk_3007DE0 *arg1, u16 arg2) { return sub_080042BC(arg0, arg1, arg2, 0xD); }
|
||||
static u16 sub_08009E20(struct Kirby *arg0, struct Unk_3007DE0 *arg1, u16 arg2) { return sub_080047E0(arg0, arg1, arg2, 0x1); }
|
||||
static u16 sub_08009E34(struct Kirby *arg0, struct Unk_3007DE0 *arg1, u16 arg2) { return sub_08004888(arg0, arg1, arg2, 0x2); }
|
||||
|
@ -1,12 +1,5 @@
|
||||
#include "global.h"
|
||||
|
||||
struct Unk_02038960 {
|
||||
u8 unk0[0x10];
|
||||
u32 unk10[4];
|
||||
u16 unk20;
|
||||
}; /* size = 0x24 */
|
||||
|
||||
extern struct Unk_02038960 gUnk_02038960;
|
||||
#include "code_08019CB8.h"
|
||||
|
||||
// not referenced
|
||||
void sub_08019CB8(void) {
|
||||
|
18
src/init.c
18
src/init.c
@ -9,10 +9,6 @@
|
||||
#include "save.h"
|
||||
#include "gba/m4a.h"
|
||||
|
||||
extern const u16 gUnk_082D848C[];
|
||||
extern const u32 gUnk_082D8498[];
|
||||
extern const u32 gUnk_082D8768[];
|
||||
|
||||
static void sub_080002C8(void);
|
||||
|
||||
#define SUB_0800043C_WAIT() ({ \
|
||||
@ -60,10 +56,14 @@ void sub_080001CC(void) {
|
||||
CreateLogo();
|
||||
}
|
||||
|
||||
static const u16 gUnk_082D848C[] = INCBIN_U16("graphics/corrupted_save/palette.gbapal");
|
||||
static const u32 gUnk_082D8498[] = INCBIN_U32("graphics/corrupted_save/tileset.4bpp.lz");
|
||||
static const u32 gUnk_082D8768[] = INCBIN_U32("graphics/corrupted_save/tilemap.bin.lz");
|
||||
|
||||
static void sub_080002C8(void) {
|
||||
s32 i;
|
||||
u16 ie, dispcnt, bldcnt, bldalpha, *r2;
|
||||
const u16* r3;
|
||||
u16 ie, dispcnt, bldcnt, bldalpha, *paletteDst;
|
||||
const u16* paletteSrc;
|
||||
if (!(gMainFlags & 0x1000)) {
|
||||
m4aSoundVSyncOff();
|
||||
ie = REG_IE;
|
||||
@ -79,10 +79,10 @@ static void sub_080002C8(void) {
|
||||
REG_BG0HOFS = 0;
|
||||
REG_BG0HOFS = 0;
|
||||
REG_IME = INTR_FLAG_VBLANK;
|
||||
r3 = gUnk_082D848C;
|
||||
r2 = (u16*)BG_PLTT;
|
||||
paletteSrc = gUnk_082D848C;
|
||||
paletteDst = (u16*)BG_PLTT;
|
||||
for (i = 4; i >= 0; i--) {
|
||||
*r2++ = *r3++;
|
||||
*paletteDst++ = *paletteSrc++;
|
||||
}
|
||||
LZ77UnCompVram(gUnk_082D8498, (void*)VRAM);
|
||||
LZ77UnCompVram(gUnk_082D8768, (void*)VRAM + 0x2000);
|
||||
|
27
src/save.c
27
src/save.c
@ -1,9 +1,34 @@
|
||||
#include "save.h"
|
||||
#include "code_08019CB8.h"
|
||||
#include "functions.h"
|
||||
|
||||
static void sub_0800AD10(void);
|
||||
static void sub_0800AD1C(void);
|
||||
static const struct Multi_082D91FC *sub_0800AD2C(u32);
|
||||
|
||||
extern void (*const gUnk_082D923C[])(void);
|
||||
extern char SoundMainRAM_Buffer[0x400] __attribute__((aligned(4)));
|
||||
|
||||
const struct Multi_082D91FC gUnk_082D91E4[] = {
|
||||
{ (void *)SoundMainRAM_Buffer + 0x404, 2 }, // TODO: how this is supposed to work
|
||||
{ (void *)&gUnk_0203AD48, sizeof(gUnk_0203AD48) },
|
||||
{ (void *)-1u, -1u },
|
||||
};
|
||||
|
||||
|
||||
const struct Multi_082D91FC gUnk_082D91FC[] = {
|
||||
{ (void *)gUnk_02028BF0, sizeof(gUnk_02028BF0) },
|
||||
{ (void *)gUnk_02028C10, sizeof(gUnk_02028C10) },
|
||||
{ (void *)gUnk_02028CA0, sizeof(gUnk_02028CA0) - 2 }, // TODO: replace with MAX_DOOR(?)
|
||||
{ (void *)&gUnk_02038960, sizeof(gUnk_02038960) },
|
||||
{ (void *)&gUnk_020229D0, sizeof(gUnk_020229D0) },
|
||||
{ (void *)&gUnk_020229D8, sizeof(gUnk_020229D8) },
|
||||
{ (void *)&gUnk_0203AD2C, sizeof(gUnk_0203AD2C) },
|
||||
{ (void *)-1u, -1u },
|
||||
};
|
||||
|
||||
void (*const gUnk_082D923C[])(void) = {
|
||||
sub_0800AD10, sub_0800AD1C
|
||||
};
|
||||
|
||||
static void nullsub_4(void) {}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user