Prev: 61791 Up: Map Next: 61823
61809: Copy two bytes from a command list into a character's buffer
Used by the routines at 31338, 31944, 61948 and 63304. Copies two bytes from a character's current command list into his buffer. Returns with HL pointing at the second byte of the pair in the character's buffer.
Input
H Character number (215-229)
L Destination for the copied bytes
61809 LD A,2 Two bytes will be copied
61811 PUSH AF Save the byte counter
61812 CALL 61791 Collect one byte from the character's command list
61815 LD (HL),A Copy it to the character's buffer
61816 POP AF Restore the byte counter to A
61817 INC L Point HL at the destination for the second byte
61818 DEC A Have we copied both bytes yet?
61819 JR NZ,61811 Jump back to copy the second one if not
61821 DEC L Point HL at the second byte that was copied
61822 RET
Prev: 61791 Up: Map Next: 61823