diff --git a/src/data/bigfont.bin b/src/data/bigfont.bin index db21431..464d0b9 100644 Binary files a/src/data/bigfont.bin and b/src/data/bigfont.bin differ diff --git a/src/data/flyover-table.tbl b/src/data/flyover-table.tbl index 2bac261..deb22e9 100644 --- a/src/data/flyover-table.tbl +++ b/src/data/flyover-table.tbl @@ -53,7 +53,7 @@ 8024=D 8025=E 8026=F -8022=G +8027=G 8028=H 8029=I 802A=J diff --git a/src/m2-flyover.asm b/src/m2-flyover.asm index cba4361..7ae0cc2 100644 --- a/src/m2-flyover.asm +++ b/src/m2-flyover.asm @@ -1,3 +1,12 @@ +//============================================================================== +//Makes it so largevwf gets what it expects from the tea routine +wrapper_largevwf_tea: +push {r4,lr} +mov r4,r5 +bl largevwf +mov r5,r4 +pop {r4,pc} + //============================================================================== //Writes the bigfont letters to RAM largevwf: @@ -98,6 +107,44 @@ pop {r5-r7,pc} .pool +//============================================================================== +//Gets in r0 the current height. In r5 DMA channel 3 and in r4 the letter buffer +flyover_scroll_routine: +push {lr} +sub r0,r0,#1 +mov r1,#0x3F +mov r2,r0 +and r2,r1 +cmp r2,r1 +bne @@end +lsr r0,r0,#6 //Get the value beyond the 0x40 +mov r1,#3 +and r0,r1 +add r1,r0,#1 +lsl r0,r0,#0xD //Multiply the value obtained by 0x2000 +lsl r1,r1,#0xD //Get ending address +ldr r2,=#0x06008000 +ldr r3,=#0x84000100 +add r0,r0,r2 +add r1,r1,r2 +mov r2,r5 //DMA Transfer channel 3 +@@cycle: +str r4,[r2,#0] +str r0,[r2,#4] +str r3,[r2,#8] +ldr r5,[r2,#8] +mov r5,#0x80 +lsl r5,r5,#0x3 +add r0,r0,r5 +add r4,r4,r5 +cmp r0,r1 +bne @@cycle +mov r5,r2 +@@end: +pop {pc} + +.pool + //.org 0x80c4c0c //.byte 0x20,0x1C,0x51,0x46,0x2A,0x22 diff --git a/src/m2-hack.asm b/src/m2-hack.asm index 56dcbeb..d4f943a 100644 --- a/src/m2-hack.asm +++ b/src/m2-hack.asm @@ -1296,9 +1296,19 @@ nop .org 0x80B3A80 :: dw flyover_tea .org 0x80B3AA4 :: dw flyover_coffee +//Change line size to 0x20 pixels +//.org 0x80B3ABA :: add r0,#0x20 +//.org 0x80B3B0C :: mov r1,#0x3F :: and r0,r1 :: nop +//.org 0x80B4162 :: bl flyover_scroll_routine :: b 0x80B41B0 +//.org 0x80B3B44 :: dw 0x85000900 + + //Flyover remapping .org 0x80B3482 :: bl largevwf :: b 0x80B348E +//Flyover remapping +.org 0x80B3B5E :: bl wrapper_largevwf_tea :: b 0x80B3A18 + // Weld the odd-numbered flyover letters .org 0x80B3254 :: bl flyoverweld :: nop