Prev: D61E Up: Map Next: D669
D655: Copy a sprite to a working buffer
Used by the routines at D567 and D61E.
Input
DE Co-ordinates of the sprite
HL Address to copy to
D655 CALL $E8D2 Convert the co-ordinates to a screen address.
D658 LD C,$02 2 rows to copy.
D65A PUSH DE Remember DE.
D65B LD B,$03 3 columns to copy.
D65D LD A,(DE) Get the screen data.
D65E LD (HL),A Put it in the buffer.
D65F INC HL Move to the next buffer position.
D660 INC E Move forward a column.
D661 DJNZ $D65D Loop while there are more columns in this row to copy.
D663 POP DE Restore DE.
D664 INC D Move down a row.
D665 DEC C Loop until all rows are done.
D666 JR NZ,$D65A
D668 RET
Prev: D61E Up: Map Next: D669