diff options
author | Dennis <dhilhorst2000@gmail.com> | 2021-07-10 18:23:20 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-10 11:23:20 -0500 |
commit | 92a8e55fdd348a88a365eb389181d8e29da6dad9 (patch) | |
tree | 2467ef22cb8cf75bdf056143fab3fac4a68ef404 /src/code_801B3C0.c | |
parent | 386299d1f401cb939e6fe3ea16d0ca57731b2648 (diff) |
Decompiled some item related functions (#42)
* decompile sub_8091290
* decompile sub_80912c8
* rename functions / struct field
* more names
* decompile 80913A0
* decompile GetItemMove
* decompile sub_80913E0
* rename function
* decompile CanSellItem function
* rename inventory struct
* add some item check functions
* fix renaming stuff
* this file shouldnt have been here
* forgot merge conflict
* decompile more item functions
* rename some stuff
* fix HM/TM naming
* Update src/code_801AFA4.c
Use enum value for USED_TM
* Fix incorrect value
Co-authored-by: Seth Barberee <seth.barberee@gmail.com>
Diffstat (limited to 'src/code_801B3C0.c')
-rw-r--r-- | src/code_801B3C0.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/code_801B3C0.c b/src/code_801B3C0.c index da993d5..502ce60 100644 --- a/src/code_801B3C0.c +++ b/src/code_801B3C0.c @@ -3,7 +3,7 @@ #include "input.h" #include "memory.h" #include "item.h" -#include "gUnknown_203B460.h" +#include "team_inventory.h" struct subStruct_203B240 { @@ -16,7 +16,7 @@ struct unkStruct_203B230 { // size: 0x94 s32 state; - struct ItemStruct_203B460 unk4; + struct ItemSlot unk4; s32 unk8; s32 unkC; struct subStruct_203B240 *unk10[2]; @@ -36,11 +36,11 @@ extern u8 gUnknown_80DBA4C[]; extern void sub_8008C54(u32); extern void sub_80073E0(u32); extern void sub_80073B8(u32); -extern void sub_8014FF0(u32, u32, u8 *, u32, u32); +extern void xxx_format_and_draw(u32, u32, u8 *, u32, u32); extern void PlayMenuSoundEffect(u32); extern void sub_8013F84(void); extern u32 sub_8012A64(u32 *, u32); -extern s32 sub_80913E0(struct ItemStruct_203B460 *, u32, struct subStruct_203B240 **); +extern s32 sub_80913E0(struct ItemSlot *, u32, struct subStruct_203B240 **); extern void sub_801317C(u32 *); extern void sub_80140B4(struct UnkTextStruct2 *); @@ -52,7 +52,7 @@ void sub_801B590(); void sub_801B480(); -u32 sub_801B3C0(struct ItemStruct_203B460 *param_1) +u32 sub_801B3C0(struct ItemSlot *param_1) { ResetSprites(1); gUnknown_203B230 = MemoryAlloc(sizeof(struct unkStruct_203B230),8); @@ -115,8 +115,8 @@ void sub_801B480(void) sub_80073B8(gUnknown_203B230->unk24); preload = gUnknown_203B230->unk10[gUnknown_203B230->unk8]; strcpy(gAvailablePokemonNames, preload->pokeName); - sub_8014FF0(16, 0, gUnknown_80DBA4C, gUnknown_203B230->unk24, 0); // $m0 - sub_8014FF0(4, 16, gUnknown_203B230->unk10[gUnknown_203B230->unk8]->unk4, gUnknown_203B230->unk24, 0); + xxx_format_and_draw(16, 0, gUnknown_80DBA4C, gUnknown_203B230->unk24, 0); // $m0 + xxx_format_and_draw(4, 16, gUnknown_203B230->unk10[gUnknown_203B230->unk8]->unk4, gUnknown_203B230->unk24, 0); sub_80073E0(gUnknown_203B230->unk24); break; case 2: |