mirror of
https://github.com/pret/pokeruby.git
synced 2025-03-03 18:37:47 +00:00
wip asm
This commit is contained in:
parent
ce569feb58
commit
d9fe7d182d
@ -3992,7 +3992,11 @@ _0813930C:
|
||||
bl StrCpyDecodeToDisplayedStringBattle
|
||||
ldr r4, _08139354 @ =gUnknown_03004210
|
||||
ldr r1, _08139374 @ =gDisplayedStringBattle
|
||||
.ifdef ENGLISH
|
||||
movs r2, 0xDC
|
||||
.else
|
||||
movs r2, 0xDE
|
||||
.endif
|
||||
lsls r2, 1
|
||||
movs r0, 0x23
|
||||
str r0, [sp]
|
||||
|
@ -3603,5 +3603,61 @@ _0813611E:
|
||||
.align 2, 0
|
||||
_0813612C: .4byte gSaveBlock2 + 0x556
|
||||
thumb_func_end sub_813610C
|
||||
|
||||
|
||||
.ifdef GERMAN
|
||||
thumb_func_start de_sub_81364AC
|
||||
de_sub_81364AC: @ 81364AC
|
||||
push {lr}
|
||||
ldr r2, _DE_081364C0 @ =gSaveBlock2
|
||||
ldr r0, _DE_081364C4 @ =0x00000564
|
||||
adds r1, r2, r0
|
||||
ldrb r0, [r1]
|
||||
cmp r0, 0xC8
|
||||
bne _DE_081364CC
|
||||
ldr r1, _DE_081364C8 @ =0x00000499
|
||||
adds r0, r2, r1
|
||||
b _DE_081364F2
|
||||
.align 2, 0
|
||||
_DE_081364C0: .4byte gSaveBlock2
|
||||
_DE_081364C4: .4byte 0x00000564
|
||||
_DE_081364C8: .4byte 0x00000499
|
||||
_DE_081364CC:
|
||||
cmp r0, 0x63
|
||||
bhi _DE_081364E4
|
||||
ldr r2, _DE_081364E0 @ =gBattleTowerTrainers
|
||||
ldrb r1, [r1]
|
||||
lsls r0, r1, 1
|
||||
adds r0, r1
|
||||
lsls r0, 3
|
||||
adds r0, r2
|
||||
b _DE_081364F2
|
||||
.align 2, 0
|
||||
_DE_081364E0: .4byte gBattleTowerTrainers
|
||||
_DE_081364E4:
|
||||
ldrb r0, [r1]
|
||||
subs r0, 0x64
|
||||
movs r1, 0xA4
|
||||
muls r0, r1
|
||||
adds r0, r2
|
||||
adds r1, 0xA9
|
||||
adds r0, r1
|
||||
_DE_081364F2:
|
||||
ldrb r0, [r0]
|
||||
pop {r1}
|
||||
bx r1
|
||||
thumb_func_end de_sub_81364AC
|
||||
|
||||
thumb_func_start de_sub_81364F8
|
||||
de_sub_81364F8: @ 81364F8
|
||||
ldr r0, _DE_08136504 @ =gSaveBlock2
|
||||
ldr r1, _DE_08136508 @ =0x00000499
|
||||
adds r0, r1
|
||||
ldrb r0, [r0]
|
||||
bx lr
|
||||
.align 2, 0
|
||||
_DE_08136504: .4byte gSaveBlock2
|
||||
_DE_08136508: .4byte 0x00000499
|
||||
thumb_func_end de_sub_81364F8
|
||||
.endif
|
||||
|
||||
.align 2, 0 @ Don't pad with nop.
|
||||
|
@ -2516,7 +2516,11 @@ _080A4470:
|
||||
bl ItemId_GetItem
|
||||
adds r1, r0, 0
|
||||
adds r0, r7, 0
|
||||
.ifdef ENGLISH
|
||||
movs r2, 0x60
|
||||
.else
|
||||
movs r2, 0x63
|
||||
.endif
|
||||
movs r3, 0
|
||||
bl sub_8072C74
|
||||
ldr r0, _080A44F0 @ =gStringVar1
|
||||
|
@ -720,7 +720,11 @@ _080F7770:
|
||||
ldr r2, [r1, 0x24]
|
||||
ldr r3, [sp, 0x58]
|
||||
asrs r0, r3, 16
|
||||
.ifdef ENGLISH
|
||||
adds r0, 0x20
|
||||
.else
|
||||
adds r0, 0x18
|
||||
.endif
|
||||
strh r0, [r2, 0x20]
|
||||
ldr r2, [r1, 0x24]
|
||||
mov r0, r8
|
||||
|
@ -30,9 +30,14 @@ RomHeaderGameTitle:
|
||||
|
||||
RomHeaderGameCode:
|
||||
.ifdef SAPPHIRE
|
||||
.ascii "AXPE"
|
||||
.ascii "AXP"
|
||||
.else
|
||||
.ascii "AXVE"
|
||||
.ascii "AXV"
|
||||
.endif
|
||||
.ifdef ENGLISH
|
||||
.ascii "E"
|
||||
.else
|
||||
.ascii "D"
|
||||
.endif
|
||||
|
||||
RomHeaderMakerCode:
|
||||
|
@ -1956,10 +1956,56 @@ void sub_80FECB8(u8 decoCat)
|
||||
sub_80FE470(decoCat, 16, 1, 0xff);
|
||||
}
|
||||
|
||||
#if ENGLISH
|
||||
void sub_80FECE0(u8 decoCat)
|
||||
{
|
||||
sub_8072AB0(gDecorations[gUnknown_020388D0[decoCat]].description, 0x80, 0x68, 0x68, 0x30, 0x1);
|
||||
}
|
||||
#elif GERMAN
|
||||
__attribute__((naked))
|
||||
void sub_80FECE0(u8 decoCat)
|
||||
{
|
||||
asm(".syntax unified\n\
|
||||
push {lr}\n\
|
||||
sub sp, 0x8\n\
|
||||
lsls r0, 24\n\
|
||||
lsrs r2, r0, 24\n\
|
||||
ldr r0, _080FED18 @ =gUnknown_020388D5\n\
|
||||
ldrb r0, [r0]\n\
|
||||
cmp r2, r0\n\
|
||||
beq _080FED24\n\
|
||||
ldr r1, _080FED1C @ =gDecorations\n\
|
||||
ldr r0, _080FED20 @ =gUnknown_020388D0\n\
|
||||
ldr r0, [r0]\n\
|
||||
adds r0, r2\n\
|
||||
ldrb r0, [r0]\n\
|
||||
lsls r0, 5\n\
|
||||
adds r1, 0x18\n\
|
||||
adds r0, r1\n\
|
||||
ldr r0, [r0]\n\
|
||||
movs r1, 0x30\n\
|
||||
str r1, [sp]\n\
|
||||
movs r1, 0x1\n\
|
||||
str r1, [sp, 0x4]\n\
|
||||
movs r1, 0x80\n\
|
||||
movs r2, 0x68\n\
|
||||
movs r3, 0x68\n\
|
||||
bl sub_8072AB0\n\
|
||||
movs r0, 0x1\n\
|
||||
b _080FED26\n\
|
||||
.align 2, 0\n\
|
||||
80FED18: .4byte gUnknown_020388D5\n\
|
||||
80FED1C: .4byte gDecorations\n\
|
||||
80FED20: .4byte gUnknown_020388D0\n\
|
||||
80FED24:\n\
|
||||
movs r0, 0\n\
|
||||
80FED26:\n\
|
||||
add sp, 0x8\n\
|
||||
pop {r1}\n\
|
||||
bx r1\n\
|
||||
.syntax divided\n");
|
||||
}
|
||||
#endif
|
||||
|
||||
void sub_80FED1C(void)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user