through c3_80BF560

This commit is contained in:
PikalaxALT 2017-11-24 21:06:46 -05:00
parent 2746967bef
commit b210d5f86b
3 changed files with 36 additions and 104 deletions

View File

@ -5,107 +5,6 @@
.text .text
thumb_func_start sub_8134DC4
sub_8134DC4: @ 8134DC4
push {r4,r5,lr}
sub sp, 0xC
adds r4, r0, 0
lsls r4, 24
lsrs r4, 24
movs r5, 0x94
lsls r5, 2
movs r0, 0
movs r1, 0
adds r2, r5, 0
movs r3, 0xD
bl SetWindowBorderStyle
ldr r2, =gText_IsThisTheCorrectTime
movs r0, 0x1
str r0, [sp]
movs r0, 0
str r0, [sp, 0x4]
str r0, [sp, 0x8]
movs r1, 0x1
movs r3, 0
bl PrintTextOnWindow
movs r0, 0
bl PutWindowTilemap
movs r0, 0
bl schedule_bg_copy_tilemap_to_vram
ldr r0, =gUnknown_085B21F4
adds r1, r5, 0
movs r2, 0xD
movs r3, 0x1
bl CreateYesNoMenu
ldr r1, =gTasks
lsls r0, r4, 2
adds r0, r4
lsls r0, 3
adds r0, r1
ldr r1, =c3_80BF560
str r1, [r0]
add sp, 0xC
pop {r4,r5}
pop {r0}
bx r0
.pool
thumb_func_end sub_8134DC4
thumb_func_start c3_80BF560
c3_80BF560: @ 8134E30
push {r4,lr}
lsls r0, 24
lsrs r4, r0, 24
bl sub_8198C58
lsls r0, 24
asrs r1, r0, 24
cmp r1, 0
beq _08134E56
cmp r1, 0
bgt _08134E50
movs r0, 0x1
negs r0, r0
cmp r1, r0
beq _08134E74
b _08134E96
_08134E50:
cmp r1, 0x1
beq _08134E74
b _08134E96
_08134E56:
movs r0, 0x5
bl PlaySE
ldr r0, =gTasks
lsls r1, r4, 2
adds r1, r4
lsls r1, 3
adds r1, r0
ldr r0, =sub_8134EA4
b _08134E94
.pool
_08134E74:
movs r0, 0x5
bl PlaySE
movs r0, 0
movs r1, 0
bl sub_8198070
movs r0, 0
bl ClearWindowTilemap
ldr r0, =gTasks
lsls r1, r4, 2
adds r1, r4
lsls r1, 3
adds r1, r0
ldr r0, =sub_8134CE8
_08134E94:
str r0, [r1]
_08134E96:
pop {r4}
pop {r0}
bx r0
.pool
thumb_func_end c3_80BF560
thumb_func_start sub_8134EA4 thumb_func_start sub_8134EA4
sub_8134EA4: @ 8134EA4 sub_8134EA4: @ 8134EA4
push {r4,lr} push {r4,lr}

View File

@ -84,5 +84,6 @@ extern const u8 gText_RegisteredDataDeleted[];
extern const u8 gUnknown_085EA79D[]; extern const u8 gUnknown_085EA79D[];
extern const u8 gText_Confirm3[]; extern const u8 gText_Confirm3[];
extern const u8 gText_Cancel4[]; extern const u8 gText_Cancel4[];
extern const u8 gText_IsThisTheCorrectTime[];
#endif //GUARD_STRINGS_H #endif //GUARD_STRINGS_H

View File

@ -15,6 +15,8 @@
#include "unknown_task.h" #include "unknown_task.h"
#include "task.h" #include "task.h"
#include "strings.h" #include "strings.h"
#include "sound.h"
#include "songs.h"
#include "decompress.h" #include "decompress.h"
// static types // static types
@ -23,8 +25,10 @@
static void sub_8134C9C(void); static void sub_8134C9C(void);
static void sub_8134CB8(u8 taskId); static void sub_8134CB8(u8 taskId);
void sub_8134DC4(u8 taskId); static void sub_8134CE8(u8 taskId);
void sub_8134CE8(u8 taskId); static void sub_8134DC4(u8 taskId);
static void c3_80BF560(u8 taskId);
void sub_8134EA4(u8 taskId);
void sub_8134F10(u8 taskId); void sub_8134F10(u8 taskId);
u16 sub_8134FFC(u16 a0, u8 a1, u8 a2); u16 sub_8134FFC(u16 a0, u8 a1, u8 a2);
void sub_813504C(u8 taskId, u8 a1); void sub_813504C(u8 taskId, u8 a1);
@ -674,7 +678,7 @@ static void sub_8134CB8(u8 taskId)
} }
} }
void sub_8134CE8(u8 taskId) static void sub_8134CE8(u8 taskId)
{ {
if (gTasks[taskId].data[0] % 6) if (gTasks[taskId].data[0] % 6)
{ {
@ -715,3 +719,31 @@ void sub_8134CE8(u8 taskId)
} }
} }
} }
static void sub_8134DC4(u8 taskId)
{
SetWindowBorderStyle(0, FALSE, 0x250, 0x0d);
PrintTextOnWindow(0, 1, gText_IsThisTheCorrectTime, 0, 1, 0, NULL);
PutWindowTilemap(0);
schedule_bg_copy_tilemap_to_vram(0);
CreateYesNoMenu(&gUnknown_085B21F4, 0x250, 0x0d, 1);
gTasks[taskId].func = c3_80BF560;
}
static void c3_80BF560(u8 taskId)
{
switch (sub_8198C58())
{
case 0:
PlaySE(SE_SELECT);
gTasks[taskId].func = sub_8134EA4;
break;
case 1:
case -1:
PlaySE(SE_SELECT);
sub_8198070(0, FALSE);
ClearWindowTilemap(0);
gTasks[taskId].func = sub_8134CE8;
break;
}
}