diff options
| author | theo3 <arisstephenson2@gmail.com> | 2020-11-23 22:18:34 -0800 |
|---|---|---|
| committer | theo3 <arisstephenson2@gmail.com> | 2020-11-23 22:18:34 -0800 |
| commit | edbf03101a64b05e9d20cdf53ec2ca4888a2effa (patch) | |
| tree | db67f687b238abf2961b819dd0f121fffbb341c2 /include | |
| parent | 0b52f80e4d01ce7c9104eeb9b474bc1cf77b94ed (diff) | |
done
Diffstat (limited to 'include')
| -rw-r--r-- | include/entity.h | 14 | ||||
| -rw-r--r-- | include/functions.h | 11 | ||||
| -rw-r--r-- | include/global.h | 4 | ||||
| -rw-r--r-- | include/main.h | 1 | ||||
| -rw-r--r-- | include/menu.h | 6 | ||||
| -rw-r--r-- | include/player.h | 5 | ||||
| -rw-r--r-- | include/structures.h | 17 |
7 files changed, 48 insertions, 10 deletions
diff --git a/include/entity.h b/include/entity.h index a90ca7c9..7972bd96 100644 --- a/include/entity.h +++ b/include/entity.h @@ -50,10 +50,10 @@ typedef struct Entity { /* */ } PACKED b; /* */ } PACKED spriteSettings; /*0x19*/ struct { - /* */ u8 b0 : 2; // 1-2 - /* */ u8 alphaBlend : 2; // 4-8 - /* */ u8 b2 : 2; //0x10 - /* */ u8 b3 : 2; //0x40 + /* */ u32 b0 : 2; // 1-2 + /* */ u32 alphaBlend : 2; // 4-8 + /* */ u32 b2 : 2; //0x10 + /* */ u32 b3 : 2; //0x40 /* */ } PACKED spriteRendering; /*0x1a*/ union { /* */ u8 raw; @@ -63,9 +63,9 @@ typedef struct Entity { /* */ } PACKED b; /* */} PACKED palette; /*0x1b*/ struct { - /* */ u8 b0 : 4; - /* */ u8 flipX : 2; //0x10 - /* */ u8 flipY : 2; //0x40 + /* */ u32 b0 : 1; + /* */ u32 b1 : 5; //0x10 + /* */ u32 flipY : 2; //0x40 /* */ } PACKED spriteOrientation; /*0x1c*/ u8 field_0x1c; /*0x1d*/ u8 field_0x1d; diff --git a/include/functions.h b/include/functions.h index 1a7a87d7..9f2a2584 100644 --- a/include/functions.h +++ b/include/functions.h @@ -270,4 +270,15 @@ extern u32 sub_0800442E(Entity*); extern void sub_08081404(Entity*, u32); extern void sub_0807B7D8(u32, u32, u32); extern void sub_08052D74(void*, void*, void*); +extern void sub_0800451C(Entity*); +extern u32 sub_080002F0(u32, u32, u32); +extern u32 sub_080040D8(Entity*, u8*, s32, s32); +extern void sub_08053320(); +extern void sub_0801D79C(u32, u32); +extern u32 sub_0805F8F8(u32); +extern void sub_08002724(void*, u8*); +extern void sub_080026C4(u8*, u8*, u8*, u32); +extern void sub_080026F2(u8*, void*, u8*, u32); +extern u32 sub_0805F7A0(u32); +extern u32* sub_0805F25C(u32); #endif diff --git a/include/global.h b/include/global.h index ad4b9daa..3b2e0446 100644 --- a/include/global.h +++ b/include/global.h @@ -47,6 +47,8 @@ #define min(a, b) ((a) < (b) ? (a) : (b)) #define max(a, b) ((a) >= (b) ? (a) : (b)) +#define static_assert(cond) extern char assertion[(cond) ? 1 : -1] + typedef union { s32 WORD; struct { @@ -74,4 +76,6 @@ union SplitHWord { } PACKED HALF; } PACKED; + + #endif // GUARD_GLOBAL_H diff --git a/include/main.h b/include/main.h index be532570..7fa87211 100644 --- a/include/main.h +++ b/include/main.h @@ -50,6 +50,7 @@ typedef struct { /*0x0A*/ u16 fadeInTime; /*0x0C*/ u8 fillerC[0x3A8]; } UI; +static_assert(sizeof(UI) == 0x3b4); extern Main gUnk_03001000; extern UI gUnk_02032EC0; diff --git a/include/menu.h b/include/menu.h index 765c0b8b..1203978e 100644 --- a/include/menu.h +++ b/include/menu.h @@ -29,15 +29,17 @@ typedef struct { u16 transitionTimer; u16 field_0xa; u8* field_0xc; - u8 unk10[2]; + u8 focusCoords[2]; u8 field_0x12; u8 unk13; - u8 filler14[0x2]; + u8 unk14; + u8 unk15; u8 unk16; u8 filler17[0x13]; u8 unk2a; int field_0x2c; } Menu; +static_assert(sizeof(Menu) == 0x30); extern Menu gMenu; diff --git a/include/player.h b/include/player.h index 0d604dbd..898f23cb 100644 --- a/include/player.h +++ b/include/player.h @@ -62,7 +62,10 @@ typedef struct { /*0x8b*/ u8 field_0x8b; /*0x8c*/ u32 field_0x8c; /*0x90*/ union SplitWord field_0x90; - /*0x94*/ u32 field_0x94[5]; + /*0x94*/ u32 field_0x94; + /*0x98*/ u16 field_0x98; + /*0x9a*/ u16 field_0x9a; + /*0x9c*/ u32 field_0x9c[3]; /*0xa8*/ u8 field_0xa8; /*0xa9*/ u8 field_0xa9; /*0xaa*/ u8 field_0xaa; diff --git a/include/structures.h b/include/structures.h index b6d348a9..bced40db 100644 --- a/include/structures.h +++ b/include/structures.h @@ -174,4 +174,21 @@ typedef struct { } data; } Dialog; +typedef struct { + u8 filler0[0x29C]; + u16 unk29C; + u8 filler29E[0x562]; +} BGBuffer; +extern BGBuffer gBG0Buffer; +extern BGBuffer gBG1Buffer; +static_assert(sizeof(BGBuffer) == 0x800); + +/* +typedef struct { + u16 filler0[0x800]; +} BG3Buffer; +extern BG3Buffer gBG3Buffer; +static_assert(sizeof(BG3Buffer) == 0x1000); +*/ + #endif |
