![]() |
Routines |
| Prev: 29717 | Up: Map | Next: 29800 |
|
Used by the routine at CreateWindow.
|
||||
|
Sets up the 1UP score.
|
||||
| Score_1UP | 29752 | LD HL,16417 | Set the screen buffer address for the 1UP score (16417). | |
| 29755 | LD DE,24334 | Point DE at 1UP_Score_1. | ||
| 29758 | JR PrintScore | Jump to PrintScore. | ||
|
This entry point is used by the routines at CreateWindow and AddPointsToScore.
Sets up the 2UP score.
|
||||
| Score_2UP | 29760 | LD HL,16441 | Set the screen buffer address for the 2UP score (16441). | |
| 29763 | LD DE,24337 | Point DE at 2UP_Score_1. | ||
| 29766 | JR PrintScore | Jump to PrintScore. | ||
|
This entry point is used by the routine at CreateWindow.
Sets up the HI score.
|
||||
| Score_HI | 29768 | LD HL,16429 | Set the screen buffer address for the HI score (16429). | |
| 29771 | LD DE,24329 | Point DE at High_Score. | ||
|
Prints the score.
|
||||
| PrintScore | 29774 | LD B,3 | Set the byte counter to 3. | |
|
This entry point is used by the routine at TakeIngredients.
|
||||
| PrintScore_Loop | 29776 | LD A,(DE) | Fetch a byte of the score. | |
| 29777 | RRCA | Shift the tens digit down (divide by 16). | ||
| 29778 | RRCA | |||
| 29779 | RRCA | |||
| 29780 | RRCA | |||
| 29781 | AND %00001111 | Keep only bits 0-3. | ||
| 29783 | ADD A,48 | Convert the digit to ASCII (add 48 which is "0"). | ||
| 29785 | CALL PrintScreen | Print the digit using PrintScreen. | ||
| 29788 | LD A,(DE) | Fetch the byte of the score again. | ||
| 29789 | AND %00001111 | Keep only bits 0-3. | ||
| 29791 | ADD A,48 | Convert the digit to ASCII (add 48 which is "0"). | ||
| 29793 | CALL PrintScreen | Print the digit using PrintScreen. | ||
| 29796 | INC DE | Move on to the next byte of the score. | ||
| 29797 | DJNZ PrintScore_Loop | Decrease the byte counter by one and loop back to PrintScore_Loop until all three bytes have been printed. | ||
| 29799 | RET | Return. | ||
|
View the equivalent code in;
|
||||
| Prev: 29717 | Up: Map | Next: 29800 |