text1/text2 rename

This commit is contained in:
Kermalis
2023-08-05 15:34:20 -04:00
parent 2159697af6
commit 938f8cf177
12 changed files with 57 additions and 32 deletions

View File

@@ -32,7 +32,7 @@ struct UnkTextStruct2_sub
// I haven't found a func that reads these separately yet, but simply making an arr[2] will cause assignments to break.
// Some funcs only match with this union for some reason even though they don't access the variables separately...
// The first func to break is currently sub_801A5D8 in kecleon_bros.c
// The first func I matched that uses the array is sub_8006554 in text_1.c (using the separated fields doesn't match or get even close)
// The first func I matched that uses the array is sub_8006554 in text2.c (using the separated fields doesn't match or get even close)
union {
struct {
s16 unk0;
@@ -56,17 +56,4 @@ struct UnkTextStruct2
const u8 *unk14;
};
void LoadCharmaps(void);
void SelectCharmap(u32);
u32 xxx_update_some_bg_tiles(u32 a0);
void sub_800641C(struct UnkTextStruct2 *a0, u8 a1, u8 a2);
void sub_8006438(const struct UnkTextStruct2 *, u8, u8, struct UnkTextStruct2_sub *);
void sub_8006518(struct UnkTextStruct2 *);
void sub_8006554(struct UnkTextStruct1 *, void *, u8 *, u16 *, u32, const struct UnkTextStruct2 *, u8, u32, struct UnkTextStruct2_sub *, u8);
void sub_800898C(void);
void sub_80089AC(const struct UnkTextStruct2 *, struct UnkTextStruct2_sub *);
void sub_8009388(void);
extern void xxx_call_draw_string(s32 x, u32 y, const u8 *str, u32 , u32);
#endif

14
include/text1.h Normal file
View File

@@ -0,0 +1,14 @@
#ifndef GUARD_TEXT1_H
#define GUARD_TEXT1_H
#include "text.h"
extern EWRAM_DATA struct UnkTextStruct2 gUnknown_202AFC0[4];
void LoadCharmaps(void);
void SelectCharmap(u32);
u32 xxx_update_some_bg_tiles(u32 a0);
void sub_800641C(struct UnkTextStruct2 *a0, u8 a1, u8 a2);
#endif // GUARD_TEXT1_H

12
include/text2.h Normal file
View File

@@ -0,0 +1,12 @@
#ifndef GUARD_TEXT2_H
#define GUARD_TEXT2_H
#include "text.h"
void sub_8006518(struct UnkTextStruct2 *);
void sub_8006554(struct UnkTextStruct1 *, void *, u8 *, u16 *, u32, const struct UnkTextStruct2 *, u8, u32, struct UnkTextStruct2_sub *, u8);
// text.s
extern void xxx_call_draw_string(s32 x, u32 y, const u8 *str, u32 , u32);
#endif // GUARD_TEXT2_H

View File

@@ -67,8 +67,8 @@ SECTIONS {
asm/code_8005838.o(.text);
src/code_800558C.o(.text);
src/random.o(.text);
src/text.o(.text);
src/text_1.o(.text);
src/text1.o(.text);
src/text2.o(.text);
asm/text.o(.text);
src/code_8009804.o(.text);
asm/code_8009804.o(.text);

View File

@@ -1,7 +1,7 @@
#include "global.h"
#include "constants/dungeon.h"
#include "memory.h"
#include "text.h"
#include "text2.h"
#include "input.h"
#include "menu.h"
#include "item.h"

View File

@@ -5,7 +5,7 @@
#include "pokemon_3.h"
#include "file_system.h"
#include "input.h"
#include "text.h"
#include "text1.h"
#include "team_inventory.h"
#include "menu_input.h"
#include "gulpin_shop.h"

View File

@@ -2,9 +2,7 @@
#include "file_system.h"
#include "code_800558C.h"
#include "code_800B540.h"
#include "text.h"
extern char gUnknown_3000E94[];
#include "text1.h"
EWRAM_DATA struct UnkTextStruct1 gUnknown_2027370[4];
EWRAM_DATA u8 *gCharmaps[2];
@@ -22,14 +20,26 @@ EWRAM_DATA u32 gUnknown_202B030;
EWRAM_DATA u8 gUnknown_202B034;
EWRAM_DATA u16 gUnknown_202B038[2][32][32];
// ?
extern char gUnknown_3000E94[];
// data.s
extern const struct UnkTextStruct2 gUnknown_80B857C[4];
extern const char gKanjiA_file_string[];
extern const char gKanjiB_file_string[];
extern const struct FileArchive gSystemFileArchive;
extern const u32 gUnknown_80B87C4[8];
extern const u32 gUnknown_80B87E4[8];
extern const u32 gUnknown_80B8804[4];
extern u32 gUnknown_80B8814[];
extern const u32 gUnknown_80B8814[];
extern const char gKanjiA_file_string[];
extern const char gKanjiB_file_string[];
// system_sbin.s
extern const struct FileArchive gSystemFileArchive;
// text.s
extern void sub_800898C(void);
extern void sub_80089AC(const struct UnkTextStruct2 *, struct UnkTextStruct2_sub *);
extern void sub_8009388(void);
void sub_8006438(const struct UnkTextStruct2 *, u8, u8, struct UnkTextStruct2_sub *);
void LoadCharmaps(void)
{

View File

@@ -1,9 +1,10 @@
#include "global.h"
#include "text.h"
#include "text2.h"
extern struct UnkTextStruct2 gUnknown_202AFC0[4];
extern u32 gUnknown_80B8814[];
// data.s
extern const u32 gUnknown_80B8814[];
// text.s
extern void sub_800677C(struct UnkTextStruct1 *, s32, u16 *, u8);
extern void sub_80069CC(struct UnkTextStruct1 *, s32, s32, s32, u16 *);
extern void sub_8006AC4(struct UnkTextStruct1 *, s32, s32, u32, u16 *);

View File

@@ -3,7 +3,7 @@
#include "main_menu.h"
#include "memory.h"
#include "menu.h"
#include "text.h"
#include "text1.h"
#include "menu_input.h"
struct unkSprite

View File

@@ -4,7 +4,7 @@
#include "code_800D090.h"
#include "input.h"
#include "memory.h"
#include "text.h"
#include "text2.h"
#include "pokemon_mail.h"
#include "wonder_mail.h"
#include "code_802C39C.h"

View File

@@ -4,7 +4,7 @@
#include "constants/input.h"
#include "memory.h"
#include "text.h"
#include "text1.h"
#include "input.h"
#include "mailbox.h"
#include "menu.h"

View File

@@ -2,7 +2,8 @@
#include "memory.h"
#include "input.h"
#include "file_system.h"
#include "text.h"
#include "text1.h"
#include "text2.h"
#include "pokemon.h"
#include "menu.h"
#include "code_8094F88.h"