Prev: 42868 Up: Map Next: 43000
42917: Print Play Area
Print_PlayArea 42917 LD HL,24576 Copy 6144 bytes of data from *DartBoard to Loading.
42920 LD DE,16384
42923 LD BC,6144
42926 LDIR
42928 LD B,24 B=24.
42930 LD HL,22528 HL=22528 (screen buffer location).
Print_PlayArea_Loop 42933 PUSH BC Stash BC and HL on the stack.
42934 PUSH HL
42935 LD BC,8 BC=0008.
42938 LD D,H D=H.
42939 LD E,L E=L.
42940 INC DE Increment DE by one.
42941 LD (HL),71 Write INK: WHITE, PAPER: BLACK (BRIGHT) to *HL.
42943 LDIR LDIR.
42945 LD BC,23 BC=0023.
42948 LD (HL),112 Write INK: BLACK, PAPER: YELLOW (BRIGHT) to *HL.
42950 LDIR LDIR.
42952 LD DE,32 DE=0032.
42955 POP HL Restore HL from the stack.
42956 ADD HL,DE HL+=DE.
42957 POP BC Restore BC from the stack.
42958 DJNZ Print_PlayArea_Loop Decrease counter by one and loop back to Print_PlayArea_Loop until counter is zero.
42960 LD A,(39607) Return if *39607 is not zero.
42963 AND A
42964 RET NZ
Set the 1UP leg count.
42965 LD A,(39590) A=*Leg_1UP.
42968 ADD A,48 Add 48 (ASCII "0") to A to "convert" it to ASCII and write A to *Messaging_LegCount_1UP.
42970 LD (42993),A
Set the 2UP leg count.
42973 LD A,(39591) A=*Leg_2UP.
42976 ADD A,48 Add 48 (ASCII "0") to A to "convert" it to ASCII and write it to *Messaging_LegCount_2UP.
42978 LD (42997),A
42981 CALL PrintString_Loop Call PrintString_Loop.
42984 DEFB 17,0 PAPER: BLACK.
42986 DEFB 16,6 INK: YELLOW.
42988 DEFB 18,1 FLASH: ON.
42990 DEFB 22,1,1 PRINT AT: 1, 1.
Messaging_LegCount_1UP 42993 DEFM " " " ".
42994 DEFB 22,22,1 PRINT AT: 22, 1.
Messaging_LegCount_2UP 42997 DEFM " " " ".
42998 DEFB 255 Terminator.
42999 RET Return.
Prev: 42868 Up: Map Next: 43000