From 109af49933e9bfcd8123f3ab2c445ca791e22839 Mon Sep 17 00:00:00 2001 From: Lior Halphon Date: Sat, 6 Aug 2016 19:03:59 +0300 Subject: [PATCH] Updated DMG boot ROM to finish with the same register values as the original boot ROM --- BootROMs/dmg_boot.asm | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/BootROMs/dmg_boot.asm b/BootROMs/dmg_boot.asm index bff23ed..e22dee0 100644 --- a/BootROMs/dmg_boot.asm +++ b/BootROMs/dmg_boot.asm @@ -89,6 +89,15 @@ Start: ; Wait ~2.5 seconds ld b, 150 call WaitBFrames + +; Set registers to match the original DMG boot + ld hl, $01B0 + push hl + pop af + ld hl, $014D + ld bc, $0013 + ld de, $00D8 + ; Boot the game jp BootGame @@ -135,7 +144,6 @@ PlaySound: TrademarkSymbol: db $3c,$42,$b9,$a5,$b9,$a5,$42,$3c -SECTION "BootGame", ROM0[$fc] +SECTION "BootGame", ROM0[$fe] BootGame: - ld a, 1 ldh [$50], a \ No newline at end of file