move from raq scene to walda phrase

This commit is contained in:
DizzyEggg 2017-10-20 20:46:26 +02:00
parent 8c85a27346
commit 31e0b468c7
4 changed files with 11 additions and 22 deletions

View File

@ -5968,26 +5968,5 @@ _081D99B4:
bx r0
thumb_func_end sub_81D98B4
thumb_func_start sub_81D99BC
sub_81D99BC: @ 81D99BC
push {r4,lr}
bl IsWaldaPhraseEmpty
cmp r0, 0
bne _081D99DC
ldr r4, =gStringVar1
bl GetWaldaPhrasePtr
adds r1, r0, 0
adds r0, r4, 0
bl StringCopy
movs r0, 0x1
b _081D99DE
.pool
_081D99DC:
movs r0, 0
_081D99DE:
pop {r4}
pop {r1}
bx r1
thumb_func_end sub_81D99BC
.align 2, 0 @ Don't pad with nop.

View File

@ -519,7 +519,7 @@ gSpecials:: @ 81DBA64
def_special sub_813B80C
def_special sub_81D4BEC
def_special sub_80224D0
def_special sub_81D99BC
def_special TryBufferWaldaPhrase
def_special DoWaldaNamingScreen
def_special TryGetWallpaperWithWaldaPhrase
def_special sub_8139ED0

View File

@ -1,6 +1,7 @@
#ifndef GUARD_WALDA_PHRASE_H
#define GUARD_WALDA_PHRASE_H
u16 TryBufferWaldaPhrase(void);
void DoWaldaNamingScreen(void);
u16 TryGetWallpaperWithWaldaPhrase(void);

View File

@ -44,6 +44,15 @@ enum
PHRASE_FIRST_ATTEMPT
};
u16 TryBufferWaldaPhrase(void)
{
if (IsWaldaPhraseEmpty())
return FALSE;
StringCopy(gStringVar1, GetWaldaPhrasePtr());
return TRUE;
}
void DoWaldaNamingScreen(void)
{
StringCopy(gStringVar2, GetWaldaPhrasePtr());