![]() |
Routines |
| Prev: A19C | Up: Map | Next: A1D3 |
|
Used by the routine at DrawSidePanel.
Prints the score, as six digits, in the side panel.
|
||||||||
| Score_1UP | A1AE | LD HL,$BFCC | Write MainFont_Zero to FontPointer. | |||||
| A1B1 | LD ($5E01),HL | |||||||
| A1B4 | LD HL,$50C8 | HL=50C8 (the Y position is 50 and the X position is C8). | ||||||
|
This entry point is used by the routine at GameStats.
|
||||||||
| PrintScore | A1B7 | CALL ScreenAddress | Call ScreenAddress to get the screen address of the position. | |||||
| A1BA | LD DE,$5E2A | Point DE at the first byte of the score at Score_1. | ||||||
| A1BD | LD B,$03 | B=03 (the number of bytes). | ||||||
| PrintScore_Loop | A1BF | LD A,(DE) | Fetch the next byte of the score. | |||||
| A1C0 | RRCA | Rotate right four times, which moves the high digit into the low nibble. | ||||||
| A1C1 | RRCA | |||||||
| A1C2 | RRCA | |||||||
| A1C3 | RRCA | |||||||
| A1C4 | AND %00001111 | Keep only bits 0-3. | ||||||
| A1C6 | CALL PrintScreen | Call PrintScreen to print the digit. | ||||||
|
This entry point is used by the routine at ClockTick.
|
||||||||
| PrintScore_LowDigit | A1C9 | LD A,(DE) | Fetch the byte of the score again. | |||||
| A1CA | AND %00001111 | Keep only bits 0-3. | ||||||
| A1CC | CALL PrintScreen | Call PrintScreen to print the digit. | ||||||
| A1CF | INC DE | Move on to the next byte of the score. | ||||||
| A1D0 | DJNZ PrintScore_Loop | Decrease the byte counter by one and loop back to PrintScore_Loop until all the bytes of the score have been printed. | ||||||
| A1D2 | RET | Return. | ||||||
|
View the equivalent code in;
|
||||||||
| Prev: A19C | Up: Map | Next: A1D3 |