Prev: F2D8 Up: Map Next: F38D
F2F9: Draw Score Entry
Used by the routine at Display_High_Score_Screen.
Draws one score entry on the high score screen. Given the screen position in DE and the name data in HL, prints the rank number from C503, a closing parenthesis, the three-character name, then the full score digits via Print_BCD_Score. The alternate entry at Draw_Score_Entry_Compact uses tighter row spacing and a smaller column advance for the All Time Heroes table.
Input
DE Screen position (row in D, column in E)
HL Points to the three-character name for this score entry
Draw_Score_Entry F2F9 LD B,$01 Set the rank digit count and row stride.
F2FB LD C,$06
F2FD PUSH HL Stash the name pointer and screen position on the stack.
F2FE PUSH DE
F2FF LD HL,$C503 Call Print_BCD_Score_Suppress_Loop using C503.
F302 CALL Print_BCD_Score_Suppress_Loop
F305 POP DE Restore the screen position and name pointer from the stack.
F306 POP HL
F307 LD A,$16 Position the cursor and print the closing parenthesis character.
F309 CALL PrintDispatch
F30C LD A,D
F30D ADD A,$0C
F30F CALL PrintDispatch
F312 LD A,E
F313 CALL PrintDispatch
F316 LD A,$29
F318 CALL PrintDispatch
F31B LD A,$16 Position the cursor for the score entry name.
F31D CALL PrintDispatch
F320 LD A,D
F321 ADD A,$13
F323 CALL PrintDispatch
F326 LD A,E
F327 CALL PrintDispatch
F32A LD B,$03 Set the name character loop counter.
Draw_Score_Entry_Name_Loop F32C LD A,(HL) Print the next character of the name.
F32D INC HL
F32E CALL PrintDispatch
F331 DJNZ Draw_Score_Entry_Name_Loop Repeat for the three-character name.
F333 PUSH DE Save the screen position and advance the row for the score digits.
F334 LD A,$2D
F336 ADD A,D
F337 LD D,A
F338 LD C,$06
F33A CALL Print_BCD_Score Print the score digits via Print_BCD_Score.
F33D POP DE Restore the position and advance the column for the next entry.
F33E LD A,$08
F340 ADD A,E
F341 LD E,A
F342 RET Return.
This entry point is used by the routine at Display_High_Score_Screen.
Compact variant for the All Time Heroes table; uses a row stride of 04 and a column advance of 06 for tighter spacing.
Draw_Score_Entry_Compact F343 LD B,$01 Set the rank digit count and row stride.
F345 LD C,$04
F347 PUSH HL Stash the name pointer and screen position on the stack.
F348 PUSH DE
F349 LD HL,$C503 Call Print_BCD_Score_Suppress_Loop using C503.
F34C CALL Print_BCD_Score_Suppress_Loop
F34F POP DE Restore the screen position and name pointer from the stack.
F350 POP HL
F351 LD A,$16 Position the cursor and print the closing parenthesis character.
F353 CALL PrintDispatch
F356 LD A,D
F357 ADD A,$08
F359 CALL PrintDispatch
F35C LD A,E
F35D CALL PrintDispatch
F360 LD A,$29
F362 CALL PrintDispatch
F365 LD A,$16 Position the cursor for the score entry name.
F367 CALL PrintDispatch
F36A LD A,D
F36B ADD A,$0D
F36D CALL PrintDispatch
F370 LD A,E
F371 CALL PrintDispatch
F374 LD B,$03 Set the name character loop counter.
Draw_Score_Entry_Compact_Name_Loop F376 LD A,(HL) Print the next character of the name.
F377 INC HL
F378 CALL PrintDispatch
F37B DJNZ Draw_Score_Entry_Compact_Name_Loop Repeat for the three-character name.
F37D PUSH DE Save the screen position and advance the row for the score digits.
F37E LD A,$1F
F380 ADD A,D
F381 LD D,A
F382 LD C,$04
F384 CALL Print_BCD_Score Print the score digits via Print_BCD_Score.
F387 POP DE Restore the position and advance the column for the next entry.
F388 LD A,$06
F38A ADD A,E
F38B LD E,A
F38C RET Return.
Prev: F2D8 Up: Map Next: F38D