decomp another func and cleanup code

This commit is contained in:
Seth Barberee
2023-05-15 17:37:34 -07:00
parent 346bcc681f
commit 2116aef8c2
26 changed files with 479 additions and 530 deletions

View File

@@ -5,6 +5,7 @@
struct unkStruct_203B480
{
// size: 0x30
/* 0x0 */ u8 mailType;
/* 0x1 */ u8 missionType;
/* 0x4 */ struct DungeonLocation dungeon;
@@ -37,8 +38,21 @@ struct unkStruct_203B48C
s32 unk4[0x20];
};
extern struct unkStruct_203B480 *gUnknown_203B480;
extern struct unkStruct_203B484 *gUnknown_203B484;
extern u32 *gUnknown_203B488;
extern struct unkStruct_203B48C *gUnknown_203B48C;
void sub_80950BC(void);
struct unkStruct_203B480 *sub_80950F8(void);
struct unkStruct_203B484 *sub_8095100(void);
u32 *sub_8095108(void);
struct unkStruct_203B48C *sub_8095110(void);
void sub_8095118(void);
s32 FindOpenMailSlot(void);
bool8 sub_80951BC(struct unkStruct_203B480 *mail);
bool8 sub_80951FC(struct unkStruct_203B480 *param_1);
struct unkStruct_203B480 * sub_8095228(u8 index);
struct unkStruct_203B480 * GetMailatIndex(u8 index);
void DeleteMailAtIndex(u8 index);
void sub_8095274(u32 param_1);
bool8 sub_8095298(s32 param_1);
@@ -49,6 +63,8 @@ u32 CountAllMail(void);
s32 sub_8095374(void);
s32 GetMailIndex(u8 mailType, u32 param_2);
s32 GetFirstIndexofMailType(u8 mailType);
void sub_8095824(struct unkStruct_8094924 * a, struct unkStruct_203B480 *b);
void sub_8095774(struct unkStruct_8094924 * a, struct unkStruct_203B480 *b);
#endif

View File

@@ -1,4 +1,5 @@
#include "wonder_mail.h"
#include "constants/mailbox.h"
struct subStruct_203B490
{
@@ -12,13 +13,13 @@ struct subStruct_203B490
struct unkStruct_203B490
{
// size: 0x330?
/* 0x0 */ struct WonderMail mailboxSlots[4];
/* 0x50 */ struct WonderMail pelipperBoardJobs[8];
/* 0xF0 */ struct WonderMail jobSlots[8];
/* 0x0 */ struct WonderMail mailboxSlots[NUM_MAILBOX_SLOTS];
/* 0x50 */ struct WonderMail pelipperBoardJobs[MAX_ACCEPTED_JOBS];
/* 0xF0 */ struct WonderMail jobSlots[MAX_ACCEPTED_JOBS];
u8 unk190[0x28];
u8 unk1B8[0x78];
struct subStruct_203B490 unk230[16];
u8 PKMNNewsReceived[56];
u8 PKMNNewsReceived[NUM_POKEMON_NEWS];
bool8 unk328;
};

View File

@@ -49,10 +49,10 @@ struct UnkStruct_sub_8011DAC {
struct UnkStruct_203B184 {
/* 0x0 */ struct TeamInventory *MoneyItems;
/* 0x4 */ struct unkStruct_203B45C *recruitedPokemon;
/* 0x8 */ u8 *unk8;
/* 0xC */ u8 *unkC;
/* 0x8 */ struct unkStruct_203B480 *unk8;
/* 0xC */ struct unkStruct_203B484 *unkC;
/* 0x10 */ u32 *unk10;
/* 0x14 */ u32 *unk14;
/* 0x14 */ struct unkStruct_203B48C *unk14;
/* 0x18 */ struct unkStruct_203B490 *mailInfo;
/* 0x1C */ struct RescueTeamData *RescueTeamInfo;
/* 0x20 */ u32 unk20;

View File

@@ -1,27 +0,0 @@
#ifndef GUARD_SUB_8095228_H
#define GUARD_SUB_8095228_H
#include "dungeon_global_data.h"
struct unkStruct_8095228
{
/* 0x0 */ u8 mailType; // mail type
/* 0x1 */ u8 missionType; // mission type
/* 0x2 */ u8 unk2;
/* 0x3 */ u8 unk3;
/* 0x4 */ struct DungeonLocation dungeon; // dungeon
/* 0x8 */ u32 unk8;
/* 0xC */ s16 clientSpecies; // client pokemon
/* 0xE */ s16 targetSpecies; // target
u32 unk10; // TODO: verify that this is just a union of the 4 bytes in Wonder Mail
u8 padding2[0x20 - 0x14];
struct Item unk20;
u8 padding3[0x28 - 0x24];
u32 unk28;
s8 unk2C;
u8 padding4[0x30 - 0x2D];
};
extern struct unkStruct_8095228 *sub_8095228(u8);
#endif // GUARD_SUB_8095228_H