Prev: A311 Up: Map Next: A3A8
A379: Determine Line Slope
Used by the routine at DrawRoomFrame.
A379 LD L,H
A37A LD H,$00
A37C EXX
A37D LD HL,$0000
A380 LD B,$08
A382 EXX
A383 SLA L
A385 RL H
A387 PUSH HL
A388 AND A
A389 SBC HL,DE
A38B JR C,$A399
A38D POP AF
A38E EXX
A38F ADD HL,HL
A390 INC HL
A391 DJNZ $A382
A393 PUSH HL
A394 EXX
A395 LD E,L
A396 LD D,H
A397 POP HL
A398 RET
A399 POP HL
A39A EXX
A39B ADD HL,HL
A39C JR $A391
This entry point is used by the routine at DrawRoomFrame.
A39E PUSH DE
A39F EX DE,HL
A3A0 LD HL,$0000
A3A3 AND A
A3A4 SBC HL,DE
A3A6 POP DE
A3A7 RET
Prev: A311 Up: Map Next: A3A8