Prev: 9DBB Up: Map Next: 9DEE
9DD8: Test two boxes' line ranges
Used by the routine at boxes_overlap.
A box spans its height upwards from its bottom line. They overlap when the other's bottom line is within the box's height above the box's, or the box's within E above the other's. scratch_count is 1 if so.
y_overlap 9DD8 XOR A
9DD9 LD (scratch_count),A
9DDC LD A,(IX+$01)
9DDF SUB H
9DE0 CP (IX+$03)
9DE3 JR C,overlap_found
9DE5 LD A,H
9DE6 SUB (IX+$01)
9DE9 CP E
9DEA RET NC
9DEB JP overlap_found
Prev: 9DBB Up: Map Next: 9DEE