| Prev: 64B4 | Up: Map | Next: 64E5 |
64BC: Print current bridge number on status line
|
Used by the routines at play, check_collision, next_bridge_player_2, setup_overview_status_player_2 and overview.
|
||||
|
Displays the current bridge number for the active player on the status line. Sets the appropriate ink color (yellow for Player 1, cyan for Player 2) and prints the bridge counter with leading space padding for single-digit numbers.
Uses ROM routine at $203C to print status line text and $1A1B (OUT_NUM_1) to print the numeric value.
|
||||
| print_bridge | 64BC | LD A,($923D) | If Player 2, jump to print_bridge_player_2. | |
| 64BF | CP $02 | |||
| 64C1 | JP Z,print_bridge_player_2 | |||
| 64C4 | LD A,$10 | INK PLAYER_1 | ||
| 64C6 | RST $10 | |||
| 64C7 | LD A,$06 | |||
| 64C9 | RST $10 | |||
| 64CA | LD DE,$804F | Print status_line_3 (11 bytes) to position cursor. | ||
| 64CD | LD BC,$000B | |||
| 64D0 | CALL $203C | |||
| 64D3 | LD A,($5F6A) | If bridge count < 10, print leading space. | ||
| 64D6 | SUB $0A | |||
| 64D8 | CALL M,print_space | (continued). | ||
| 64DB | LD A,($5F6A) | Print bridge count from state_bridge_player_1. | ||
| 64DE | LD B,$00 | |||
| 64E0 | LD C,A | |||
| 64E1 | CALL $1A1B | |||
| 64E4 | RET | |||
| Prev: 64B4 | Up: Map | Next: 64E5 |