Decompiled CB2_PokeNav

This commit is contained in:
Phlosioneer 2019-02-12 01:34:43 -05:00
parent 69b014f7aa
commit cd84c92cfa
2 changed files with 16 additions and 47 deletions

View File

@ -5,38 +5,6 @@
.text .text
thumb_func_start CB2_PokeNav
CB2_PokeNav: @ 81C7250
push {r4,lr}
ldr r4, =gUnknown_0203CF40
movs r0, 0x5C
bl Alloc
str r0, [r4]
cmp r0, 0
bne _081C7270
ldr r0, =CB2_ReturnToFieldWithOpenMenu
bl SetMainCallback2
b _081C7292
.pool
_081C7270:
bl sub_81C7360
bl ResetTasks
movs r0, 0
bl SetVBlankCallback
ldr r0, =sub_81C742C
movs r1, 0
bl CreateTask
ldr r0, =sub_81C7400
bl SetMainCallback2
ldr r0, =sub_81C7418
bl SetVBlankCallback
_081C7292:
pop {r4}
pop {r0}
bx r0
.pool
thumb_func_end CB2_PokeNav
thumb_func_start sub_81C72A4 thumb_func_start sub_81C72A4
sub_81C72A4: @ 81C72A4 sub_81C72A4: @ 81C72A4
push {lr} push {lr}

View File

@ -46,21 +46,7 @@ extern void sub_81C742C(u8 taskId);
extern void sub_81C7400(void); extern void sub_81C7400(void);
extern void sub_81C7418(void); extern void sub_81C7418(void);
/*
void CB2_PokeNav(void)
{
gUnknown_0203CF40 = Alloc(0x5C);
if (gUnknown_0203CF40 == NULL) {
SetMainCallback2(CB2_ReturnToFieldWithOpenMenu);
} else {
sub_81C7360();
ResetTasks();
SetVBlankCallback(NULL);
CreateTask(sub_81C742C, 0);
SetMainCallback2(sub_81C7400);
SetVBlankCallback(sub_81C7418);
}
}*/
extern u8 gUnknown_0203CF3C; extern u8 gUnknown_0203CF3C;
extern void sub_81C7170(u8 a0); extern void sub_81C7170(u8 a0);
@ -171,4 +157,19 @@ void sub_81C71E4(u8 taskId) {
case 2: case 2:
case 3: case 3:
} }
}
void CB2_PokeNav(void)
{
gUnknown_0203CF40 = Alloc(0x5C);
if (gUnknown_0203CF40 == NULL) {
SetMainCallback2(CB2_ReturnToFieldWithOpenMenu);
} else {
sub_81C7360();
ResetTasks();
SetVBlankCallback(NULL);
CreateTask(sub_81C742C, 0);
SetMainCallback2(sub_81C7400);
SetVBlankCallback(sub_81C7418);
}
} }