I had some trouble getting the asm from krt17 to work properly with EmuZWin, it was due to the 0x before the hex, so they were stripped out and replaced with dec for those of us without a working hex head. The colour variable was moved to the start to allow for different borders to be set by the user. It is a magnificent bit of code, that works the screen backwards (bung some HALTs in there to see it in action) and in less bytes too.
Code: Select all
Frame LD C,10 ; colour
ld hl,23295
xor a
ld a,23
L2
ld b,30
ld (hl), c
dec hl
L1
jr nz,skip
ld (hl), c
skip dec hl
djnz L1
ld (hl), c
dec hl
dec a
ret m
jr L2
Asking for snippets of code from forum members shows us that we all write things in a different way, upper/lower case, hex/dec mixtures
The result is that we learn from each other, new ways of improving the code and hopefully squeezing an extra graphic or something into the end game.
Dave, you have 6 extra bytes so far... use them wisely!