Prev: 36946 Up: Map Next: 37078
37062: Highlight Selected Option
Used by the routine at Select_Game_Options.
Flashes the menu line of the chosen control method and stops the other lines from flashing. It does this by setting or resetting bit 7 (FLASH) of each of the line attributes that start at HL.
The two small routines at Clear_Flash_Attribute and Set_Flash_Attribute reset or set the bit for one line and move on to the next one. The loop is entered again at 37064 with the zero flag set by the A decrease at Highlight_Selected_Option_Loop.
Input
A Control method
B Number of control methods (4)
HL Address of the attribute of the first line
Highlight_Selected_Option 37062 AND %00000011 Keep only the control method bits (bits 0 and 1).
37064 JR Z,Highlight_Selected_Option_Flash_Line Jump to Highlight_Selected_Option_Flash_Line if this is the line of the chosen method.
37066 CALL Clear_Flash_Attribute Clear the flash bit of this line and move on to the next line.
Highlight_Selected_Option_Loop 37069 DEC A Decrease the line count in A (it is zero when the chosen line is reached).
37070 DJNZ Highlight_Selected_Option Repeat for each of the four lines.
37072 RET Return.
Highlight_Selected_Option_Flash_Line 37073 CALL Set_Flash_Attribute Set the flash bit of this line and move on to the next line.
37076 JR Highlight_Selected_Option_Loop Jump back to Highlight_Selected_Option_Loop.
Prev: 36946 Up: Map Next: 37078