Code: ld d, 0
call fillScreen
ret
fillScreen:
ld hl, vRam
ld bc, 76800
fillScreenLoop:
ld (hl), d
inc hl
dec bc
jp nz, fillScreenLoop
ret
I have this code here, and for some reason it's not working. Are there any problems here? (If it helps, vRam is equal to $0D40000)
Also, when I remove the JP NZ opcode and let it run, the screen filling is very slow compared to other TI-84 PCE games I have seen. Would any optimizations on this be possible? Thanks for all the help.
You should look into the
ldir instruction.
Code: ld hl, vRam
ld (hl), $00
ld de, vRam+1
ld bc, (2*lcdWidth*lcdHeight)-1
ldir
ret
You should look into the code for the graphx fillscreen function.
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.
»
Go to Registration page
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum