Sega Master System / Mark III / Game Gear|
SG-1000 / SC-3000 / SF-7000 / OMV
Home - Forums - Games - Scans - Maps - Cheats - Credits
Music - Videos - Development - Hacks - Translations - Homebrew
Flicky tries to write $73A3-$74A2Posted: Fri May 21, 2021 9:01 am
If you let the demo play, and then start the game, flicky for sg-1000 tries to write in the range $73A3-$74A2 (at $040D).
Did anyone ever disassembly it and know what kind of bug/removed feature it is?
||Posted: Sat May 22, 2021 8:04 am|
It's a bug. It's present in both Flicky v0 and v1, but these addresses refer to v1.
After the demo, these game makes these calls:
046a: call 7395
046d: call 0408
0470: call 0173
The function at 7395 silences the PSG by writing $9f, $bf, $df, $ff to it:
silence_psg: ld hl,739Fh
The second call is intended to clear the copy of the Sprite Attribute Table kept in RAM, before the third call uses that table:
clear_sat: ld hl,C0ECh
clear_sat_loop: ld a,b
+: ld (hl),00h
++: inc hl
However, $0408 isn't the address of `clear_sat`, it's the address of `clear_sat_loop`. So the loop runs but without first initializing `hl` and `b`, which retain their values from the end of `silence_psg` - $73a3 and $00 respectively. Therefore instead of clearing $c1a1 - $c220, the loop tries to clear $73a3 - $74a2.
||Posted: Sun May 23, 2021 11:38 pm|
|Thank you so much for this wonderful analysis!|