Merge pull request #2 from Wintiger0222/master

Update hack
This commit is contained in:
ShaffyYoutube 2019-04-15 19:23:01 +02:00 committed by GitHub
commit 1843773d67
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 74 additions and 72 deletions

View File

@ -6,12 +6,14 @@
; Variables ; Variables
; Skip the warning screen (1 = yes, 0 = no) ; Skip the warning screen (1 = yes, 0 = no)
_skipwarningscreen equ 1 _skipwarningscreen equ 0
; Skip the Rhythm Test when creating a new save (1 = yes, 0 = no) ; Skip the Rhythm Test when creating a new save (1 = yes, 0 = no)
_skiprhythmtest equ 0 _skiprhythmtest equ 0
; To-Document later ; To-Document later
_debug equ 0 _debug equ 0
; Have to do with something? ; Have to do with something?
_debugmenu equ 1
;debugmenu mode
_nocashmessages equ 0 _nocashmessages equ 0
; ???? ; ????
_luaconsolemessages equ 0 _luaconsolemessages equ 0

View File

@ -93,12 +93,7 @@ rhcomp.exe Graphics/MusicSelect/CD62EC_musicselect_map.bin
rhcomp.exe Graphics/MusicSelect/CD6434_musicselect_warning_map.bin rhcomp.exe Graphics/MusicSelect/CD6434_musicselect_warning_map.bin
armips.exe compile.asm -sym mysym.sym armips.exe compile.asm -sym mysym.sym
flips.exe --apply "Patch\Font Hack 4 - 1px spacer.ips" "Game\rh-eng.gba" flips.exe --apply "Patch\Font Hack 4 - 1px spacer.ips" "Game\rh-eng.gba"
if %1 == 1 (
echo Debug Menu Activated
flips.exe --apply "Patch\Debug_Menu.ips" "Game\rh-eng.gba"
) else (
echo Debug Menu Not Activated
)
pause pause
compile.bat %1 compile.bat %1
exit exit

View File

@ -17,5 +17,10 @@ bl Debug_99Medals_Hook
nop nop
.endif .endif
.if _debugmenu==1
.org 0x0801CFC0
.dw 0x089ddbcc
.endif
.endif .endif
;eof ;eof

View File

@ -25,65 +25,65 @@ mov r15,r14
.pool .pool
.endif .endif
.if _debug ==1 ; .if _debug ==1
.align 2 ; .align 2
Debug_UnlockAllStages: ; Debug_UnlockAllStages:
push r0-r2,r14 ; push r0-r2,r14
ldr r0,= 0x030046a8 ; ldr r0,= 0x030046a8
ldr r0,[r0] ; ldr r0,[r0]
add r0,0x16 ; add r0,0x16
mov r1,0x37 ; mov r1,0x37
mov r2,4 ; mov r2,4
@@fillstart: ; @@fillstart:
strb r2,[r0,r1] ; strb r2,[r0,r1]
sub r1,1 ; sub r1,1
bge @@fillstart ; bge @@fillstart
pop r0-r2,r15 ; pop r0-r2,r15
.pool ; .pool
Debug_UnlockAllMail: ; Debug_UnlockAllMail:
push r0-r2,r14 ; push r0-r2,r14
ldr r0,=0x030046a8 ; ldr r0,=0x030046a8
ldr r0,[r0] ; ldr r0,[r0]
ldr r1,=0x27B ; ldr r1,=0x27B
add r0,r0,r1 ; add r0,r0,r1
mov r1,0x13 ; mov r1,0x13
mov r2,1 ; mov r2,1
@@fillstart: ; @@fillstart:
strb r2,[r0,r1] ; strb r2,[r0,r1]
sub r1,1 ; sub r1,1
bge @@fillstart ; bge @@fillstart
pop r0-r2,r15 ; pop r0-r2,r15
.pool ; .pool
Debug_99Medals: ; Debug_99Medals:
push r0-r1,r14 ; push r0-r1,r14
ldr r0,=0x030046a8 ; ldr r0,=0x030046a8
ldr r0,[r0] ; ldr r0,[r0]
ldr r1,=0x29E ; ldr r1,=0x29E
add r0,r0,r1 ; add r0,r0,r1
mov r1,0xFF ; mov r1,0xFF
strb r1,[r0] ; strb r1,[r0]
pop r0-r1,r15 ; pop r0-r1,r15
.pool ; .pool
Debug_UnlockAllStages_Hook: ; Debug_UnlockAllStages_Hook:
push r14 ; push r14
bl Debug_UnlockAllStages ; bl Debug_UnlockAllStages
bl 0x080128B8 ; bl 0x080128B8
pop r15 ; pop r15
Debug_UnlockAllMail_Hook: ; Debug_UnlockAllMail_Hook:
push r14 ; push r14
bl 0x0800C3B8 ; bl 0x0800C3B8
bl Debug_UnlockAllMail ; bl Debug_UnlockAllMail
pop r15 ; pop r15
Debug_99Medals_Hook: ; Debug_99Medals_Hook:
push r14 ; push r14
bl Debug_99Medals ; bl Debug_99Medals
bl 0x0801D23C ; bl 0x0801D23C
pop r15 ; pop r15
.endif ; .endif
;eof ;eof

View File

@ -20,18 +20,18 @@ pop r15
LZ77CompressedChecker: LZ77CompressedChecker:
push r5,r14 push r5,r14
.if (_debug ==1)&&(_nocashmessages ==1) .if (_debug ==1);&&(_nocashmessages ==1)
push r0-r7 push r0-r7
ldr r3,[r5,0xC] ldr r3,[r5,0xC]
ldrb r0,[r3,0xC] ldrb r0,[r3,0xC]
ldrb r4,[r3,0x3] ldrb r4,[r3,0x3]
lsr r4,7 lsr r4,7
cmp r4,1 ; cmp r4,1
beq @@NotCompressed ; beq @@NotCompressed
cmp r0,0 ; cmp r0,0
beq @@NotCompressed ; beq @@NotCompressed
ldr r1,[r5,0x10] ldr r1,[r5,0x10]
.msg "%r3% -> %r1%" .msg "Graphic data loaded (0x%r3% -> 0x%r1%)"
@@NotCompressed: @@NotCompressed:
pop r0-r7 pop r0-r7
.endif .endif