Prev: 44375 Up: Map Next: 44650
44633: Copy Display Data If Zero
Used by the routine at MatchWordAgainstEarlierClause.
Copies a display pair only when both of its bytes are still clear.
Input
HL Destination pointer (2-byte display data)
DE Source pointer (2-byte display data)
CopyDisplayDataIfZero 44633 LD A,(HL) Leave this pair unchanged when either byte is already set.
44634 INC HL
44635 OR (HL)
44636 DEC HL
44637 JR NZ,CopyDisplayDataIfZero_Next
44639 LD A,(DE) Copy the first byte of this display pair into the picture.
44640 LD (HL),A
CopyDisplayDataIfZero_Next 44641 INC HL Jump to CopyDisplayDataIfZero_AdvancePointers if either byte of this display pair is already set.
44642 INC DE
44643 JR NZ,CopyDisplayDataIfZero_AdvancePointers
44645 LD A,(DE) Copy the second byte of this display pair into the picture.
44646 LD (HL),A
CopyDisplayDataIfZero_AdvancePointers 44647 INC HL Advance through the display entry.
44648 INC DE Step to the next source byte.
44649 RET Return.
Prev: 44375 Up: Map Next: 44650