mirror of
https://github.com/Ninjdai1/pokeemerald.git
synced 2024-11-16 11:37:40 +01:00
SetLilicoveQuizLady
This commit is contained in:
parent
73ee165ef6
commit
28d0fa33fe
@ -5,79 +5,6 @@
|
||||
|
||||
.text
|
||||
|
||||
thumb_func_start SetLilycoveQuizLady
|
||||
SetLilycoveQuizLady: @ 818DF68
|
||||
push {r4-r6,lr}
|
||||
ldr r2, =gUnknown_0203CD68
|
||||
ldr r0, =gSaveBlock1Ptr
|
||||
ldr r0, [r0]
|
||||
ldr r1, =0x00003b58
|
||||
adds r0, r1
|
||||
str r0, [r2]
|
||||
movs r1, 0
|
||||
strb r1, [r0]
|
||||
ldr r0, [r2]
|
||||
strb r1, [r0, 0x1]
|
||||
movs r3, 0
|
||||
adds r4, r2, 0
|
||||
ldr r6, =gGameLanguage
|
||||
adds r5, r4, 0
|
||||
ldr r0, =0x0000ffff
|
||||
adds r2, r0, 0
|
||||
_0818DF8A:
|
||||
ldr r1, [r5]
|
||||
lsls r0, r3, 1
|
||||
adds r1, 0x2
|
||||
adds r1, r0
|
||||
ldrh r0, [r1]
|
||||
orrs r0, r2
|
||||
strh r0, [r1]
|
||||
adds r0, r3, 0x1
|
||||
lsls r0, 24
|
||||
lsrs r3, r0, 24
|
||||
cmp r3, 0x8
|
||||
bls _0818DF8A
|
||||
ldr r0, [r4]
|
||||
ldr r1, =0x0000ffff
|
||||
strh r1, [r0, 0x14]
|
||||
movs r1, 0x1
|
||||
negs r1, r1
|
||||
strh r1, [r0, 0x16]
|
||||
movs r3, 0
|
||||
adds r5, r4, 0
|
||||
movs r2, 0
|
||||
_0818DFB4:
|
||||
ldr r0, [r5]
|
||||
lsls r1, r3, 1
|
||||
adds r0, 0x20
|
||||
adds r0, r1
|
||||
strh r2, [r0]
|
||||
adds r0, r3, 0x1
|
||||
lsls r0, 24
|
||||
lsrs r3, r0, 24
|
||||
cmp r3, 0x3
|
||||
bls _0818DFB4
|
||||
ldr r0, [r4]
|
||||
movs r2, 0
|
||||
movs r1, 0
|
||||
strh r1, [r0, 0x28]
|
||||
adds r0, 0x2A
|
||||
strb r2, [r0]
|
||||
ldr r0, [r4]
|
||||
adds r0, 0x2C
|
||||
movs r1, 0x10
|
||||
strb r1, [r0]
|
||||
ldr r0, [r4]
|
||||
ldrb r1, [r6]
|
||||
adds r0, 0x2D
|
||||
strb r1, [r0]
|
||||
bl sub_818DF00
|
||||
pop {r4-r6}
|
||||
pop {r0}
|
||||
bx r0
|
||||
.pool
|
||||
thumb_func_end SetLilycoveQuizLady
|
||||
|
||||
thumb_func_start sub_818E004
|
||||
sub_818E004: @ 818E004
|
||||
ldr r2, =gUnknown_0203CD68
|
||||
|
@ -670,15 +670,18 @@ enum {
|
||||
struct LilycoveLadyQuiz
|
||||
{
|
||||
/*0x000*/ u8 id;
|
||||
/*0x001*/ u8 language;
|
||||
/*0x001*/ u8 unk_001;
|
||||
/*0x002*/ u16 unk_002[9];
|
||||
/*0x014*/ u16 unk_014;
|
||||
/*0x016*/ u8 filler_016[2];
|
||||
/*0x016*/ u16 unk_016;
|
||||
/*0x018*/ u8 unk_018;
|
||||
/*0x019*/ u8 filler_019[15];
|
||||
/*0x019*/ u8 filler_019[7];
|
||||
/*0x020*/ u16 unk_020[4];
|
||||
/*0x028*/ u16 unk_028;
|
||||
/*0x02a*/ u8 filler_02a;
|
||||
/*0x02a*/ u8 unk_02a;
|
||||
/*0x02b*/ u8 unk_02b;
|
||||
/*0x02c*/ u8 unk_02c;
|
||||
/*0x02d*/ u8 language;
|
||||
};
|
||||
|
||||
struct LilycoveLadyFavour
|
||||
|
@ -319,3 +319,27 @@ void sub_818DF00(void)
|
||||
gUnknown_0203CD68->unk_02b = v0;
|
||||
gUnknown_0203CD68->unk_018 = 0xFF;
|
||||
}
|
||||
|
||||
void SetLilycoveQuizLady(void)
|
||||
{
|
||||
u8 i;
|
||||
|
||||
gUnknown_0203CD68 = &gSaveBlock1Ptr->lilycoveLady.quiz;
|
||||
gUnknown_0203CD68->id = LILYCOVE_LADY_QUIZ;
|
||||
gUnknown_0203CD68->unk_001 = 0;
|
||||
for (i = 0; i < 9; i ++)
|
||||
{
|
||||
gUnknown_0203CD68->unk_002[i] = -1;
|
||||
}
|
||||
gUnknown_0203CD68->unk_014 = -1;
|
||||
gUnknown_0203CD68->unk_016 = -1;
|
||||
for (i = 0; i < 4; i ++)
|
||||
{
|
||||
gUnknown_0203CD68->unk_020[i] = 0;
|
||||
}
|
||||
gUnknown_0203CD68->unk_028 = 0;
|
||||
gUnknown_0203CD68->unk_02a = 0;
|
||||
gUnknown_0203CD68->unk_02c = 0x10;
|
||||
gUnknown_0203CD68->language = gGameLanguage;
|
||||
sub_818DF00();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user