Flicky built for the SC-3000 and SG-1000 in 1984.!
SUMMARY 02C4 to hack what start level you'd like to practice 02CA to hack how many lives you'd like to have
30/09/2020 http://www.retrogamingpower.co.uk/flicky/flicky.htm
ROM http://www.get-your-rom.com/download/sg1k/flicky-rom/japan
Piopio and Nyannyan https://strategywiki.org/wiki/Flicky
28/09/2020 Today I (finally?) worked out how to reverse engineer Flicky Z80 asm source code and hack the start level for practice and number of lives on start
e.g. original DATA_2C3: .db $01 $01 $00 $00 $0C $80 $00 $02
start level 9 $09 start lives 7 $06 [out by one] DATA_2C3: .db $01 $09 $00 $00 $0C $80 $00 $06
Address: 02C3
SUMMARY 02C4 to hack what start level you'd like to practice 02CA to hack how many lives you'd like to have
Q. How do I work this out?
A. Open Flicky.sg using Emulicious emulator Debugging window | Run menu | Suspend on open Debug | step thru code find "Port_IOPort1" reference e.g. when press "A" to start game LABEL_27D9 set breakpoint all spots here
Run code on and press "A" on title screen to start code should break on "Port_IOPort1" input detection step thru calls | you will see level screen being "built" Drawing the level LABEL_1CFA:
"Guess" level stored in RAM at $C0E8 i.e. LABEL_1CE4: ld a, (RAM_C0E8) ; RAM_C0E8 = $C0E8 just before this code: LABEL_1CE4: ld a, (RAM_C0E8) ; RAM_C0E8 = $C0E8
Launch Memory map right click RAM_C0E8 Toggle watch point | F8 resume Doing this will break into debugging code each time data in RAM_C0E8 changes e.g. setting the level variable
Confirm when code breaks at LABEL_1CE4: ld a, (RAM_C0E8) ; RAM_C0E8 = $C0E8
hover over RAM_C0E8 and will be $01 this $01 is second $01 above in DATA_2C3: as this byte block starts at RAM_C0E7
27/09/2020 Folder "02" Emulicious.asm is the complete build that assembles OK Flicky.asm is the work in progress
Source Emulicious.asm E:\Steven\INSTALLATIONSEGA\ROM_Sega\8-bit\Disassemble\Flicky03_SMS
Binary File Write D:\Steven_NET\VS2017\BinaryFileWrite
27/09/2020 call LABEL_1C populates the first palette with 14x colors DATA_2A: .db $02 $80 $82 $81 $0E $82 $FF $83 $03 $84 $76 $85 $03 $86
LABEL_254D: large method that loads a bunch of tiles into VRAM
LABEL_23FE turn background crimson
LABEL_1D79: draw the top and bottom parts
LABEL_1CE4: big method
LABEL_1D59: Push Start Button SEGA 1984
LABEL_BC: Turn screen on
LABEL_4BA: flast Push start button
LABEL_207B: big method
call LABEL_25F2 load the demo level
LABEL_209: big function does this transition to start game?
LABEL_4BA: LABEL_149: code is here during the flashing title screen
Finally got title screen flashing
LABEL_78A:
LABEL_8B4:
LABEL_1C93:
LABEL_6F22:
LABEL_70F4:
LABEL_7214:
Another bunch of calls LABEL_427:
Game start trap when port1 fire pressed e.g. LABEL_27D9
Game start setup LABEL_207B:
is this the game loop LABEL_2D7:
Drawing the level LABEL_1CFA:
Trying to guess level stored in RAM LABEL_1CE4: ld a, (RAM_C0E8) ; RAM_C0E8 = $C0E8
LEVEL found LABEL_1CE4:
but the code to set the nest must be in a different spot
RAM_C0E8 stores the level and everything is indexed ; Pointer Table from 480C to 485B (40 entries, indexed by RAM_C0E8)
Are all the important variables stored in RAM from C0E7 onwards?? LABEL_2AE:
ld hl, DATA_2C3
DATA_2C3: .db $01 $01 $00 $00 $0C $80 $00 $02
; Data from 2CB to 2D6 (12 bytes) DATA_2CB: .dsb 12, $00
so to start level 9 and have 7 lives DATA_2C3: .db $01 $09 $00 $00 $0C $80 $00 $06