gUnknown_203B0EC

This commit is contained in:
DizzyEggg 2024-12-15 14:35:10 +01:00
parent 385200e1d6
commit 91ae3c4c24
6 changed files with 40 additions and 63 deletions

View File

@ -3,38 +3,9 @@
.global gUnknown_8270000
gUnknown_8270000: @ 8270000
@ replacing .incbin "baserom.gba", 0x00270000, 0x2724
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x03, 0x00, 0x00, 0x00
.byte 0x02, 0x00, 0x0a, 0x00
.byte 0x1a, 0x00, 0x09, 0x00
.byte 0x09, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x03, 0x00, 0x00, 0x00
.byte 0x17, 0x00, 0x06, 0x00
.byte 0x05, 0x00, 0x03, 0x00
.byte 0x03, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x03, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x03, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.byte 0x00, 0x00, 0x00, 0x00
.4byte Ground_Text

View File

@ -7,7 +7,7 @@
#include "file_system.h"
#include "memory.h"
struct unkStruct_203B0CC *gUnknown_203B0CC;
EWRAM_INIT struct unkStruct_203B0CC *gUnknown_203B0CC = NULL;
struct unkStruct_800F18C
{

View File

@ -2,6 +2,8 @@
#include "file_system.h"
#include "memory.h"
#include "code_800E9E4.h"
#include "dungeon_pokemon_sprites.h"
#include "sprite.h"
struct unkStruct_203B0D0_sub
{
@ -23,7 +25,10 @@ struct unkStruct_203B0D0 {
struct unkStruct_203B0D0_sub unk4[2];
};
struct unkStruct_203B0D0 *gUnknown_203B0D0;
EWRAM_INIT struct unkStruct_203B0D0 *gUnknown_203B0D0 = NULL;
EWRAM_INIT void *gUnknown_203B0D4 = NULL; // TODO: figure out the actual struct
EWRAM_INIT DungeonPokemonSprites *gDungeonPokemonSprites = NULL; // Todo: move to a different file, or merge files in this rom region
EWRAM_INIT SpriteOAM gUnknown_203B0DC = {0};
extern s32 sub_8000728();
OpenedFile *sub_800F1C0(s32, s32);
@ -34,7 +39,7 @@ void sub_800F15C(s32);
void sub_800ED38(s32 r0)
{
if(gUnknown_203B0D0 == 0)
if(gUnknown_203B0D0 == 0)
{
gUnknown_203B0D0 = MemoryAlloc(sizeof(struct unkStruct_203B0D0), 0xB);
MemoryClear8(gUnknown_203B0D0, sizeof(struct unkStruct_203B0D0));

View File

@ -1,5 +1,31 @@
#include "global.h"
#include "code_8004AA0.h"
#include "text.h"
EWRAM_INIT struct UnkBgStruct *gUnknown_203B0E4 = NULL;
EWRAM_INIT void *gUnknown_203B0E8 = NULL; // Pointer to some unknown struct
EWRAM_INIT UnkTextStruct2 gUnknown_203B0EC[4] = { // Exact location of this variable is unknown. Find a better place for it once more code is decompiled.
[0] = {
.unk4 = 3,
.unk8 = {2, 10},
.unkC = 26,
.unkE = 9,
.unk10 = 9,
},
[1] = {
.unk4 = 3,
.unk8 = {23, 6},
.unkC = 5,
.unkE = 3,
.unk10 = 3,
},
[2] = {
.unk4 = 3,
},
[3] = {
.unk4 = 3,
},
};
void sub_8010EF0(void)
{

View File

@ -1,33 +1,5 @@
.align 2
gUnknown_203B0CC: /* 203B0CC (sub_800DE8C - sub_800DC14) */
.space 0x4
gUnknown_203B0D0: /* 203B0D0 (sub_800ED38 - sub_800EF64) */
.space 0x4
gUnknown_203B0D4: /* 203B0D4 (sub_800F034 - sub_800F19C) */
.space 0x4
gDungeonPokemonSprites: /* 203B0D8 (GetDungeonPokemonSprite - sub_800F958) */
.space 0x4
gUnknown_203B0DC: /* 203B0DC (DrawStatusSprite) */
.space 0x8
gUnknown_203B0E4: /* 203B0E4 (sub_800F990 - sub_801169C) */
.space 0x4
gUnknown_203B0E8: /* 203B0E8 (sub_8010268 - sub_8010B74) */
.space 0x4
gUnknown_203B0EC: /* 203B0EC (sub_8010C58) */
.space 0x60
.include "src/debug.o"
.space 0x2B

View File

@ -12,3 +12,6 @@
.include "src/flash.o"
.include "src/code_800C9CC.o"
.include "src/cpu.o"
.include "src/code_800DAC0.o"
.include "src/code_800ED38.o"
.include "src/code_8010EF0.o"