Prev: 92E2 Up: Map Next: 933F
9305: Main Menu: Print Dart Pointer
Used by the routine at MainMenu.
Input
DE The co-ordinates of the dart
MainMenu_PrintDartPointer 9305 LD A,E Return if E is greater than 20.
9306 CP $20
9308 RET NC
9309 PUSH DE Stash DE on the stack.
930A CALL CalculateScreenBuffer Call CalculateScreenBuffer.
930D POP DE Restore DE from the stack.
930E LD A,$20 A=20.
9310 SUB E A-=E.
9311 CP $06 Jump to MainMenu_PrintDartPointer_0 if A is greater than or equal to 06.
9313 JR NC,MainMenu_PrintDartPointer_0
9315 JR MainMenu_PrintDartPointer_1 Jump to MainMenu_PrintDartPointer_1.
MainMenu_PrintDartPointer_0 9317 LD A,$06 A=06.
MainMenu_PrintDartPointer_1 9319 LD DE,$AF73 DE=Graphics_DartPointer.
931C LD B,$0B B=0B.
MainMenu_PrintDartPointer_2 931E PUSH BC Stash BC and HL on the stack.
931F PUSH HL
9320 EX DE,HL Exchange the DE and HL registers.
9321 LD B,$00 B=00.
9323 LD C,A C=A.
9324 LDIR LDIR.
9326 CP $06 Jump to MainMenu_PrintDartPointer_3 if A is equal to 06.
9328 JR Z,MainMenu_PrintDartPointer_3
932A PUSH AF Stash AF on the stack.
932B LD C,A C=A.
932C LD A,$06 A=06.
932E SUB C A-=C.
932F LD B,$00 B=00.
9331 LD C,A C=A.
9332 POP AF Restore AF from the stack.
9333 ADD HL,BC HL+=BC.
MainMenu_PrintDartPointer_3 9334 EX DE,HL Exchange the DE and HL registers.
9335 POP HL Restore HL from the stack.
9336 EX AF,AF' Exchange the AF register with the shadow AF register.
9337 CALL NextScreenBufferLine Call NextScreenBufferLine.
933A EX AF,AF' Exchange the shadow AF register with the AF register.
933B POP BC Restore BC from the stack.
933C DJNZ MainMenu_PrintDartPointer_2 Decrease counter by one and loop back to MainMenu_PrintDartPointer_2 until counter is zero.
933E RET Return.
Prev: 92E2 Up: Map Next: 933F