Prev: 47890 Up: Map Next: 48003
47987: Set Flashing Attribute
Used by the routine at GameMenu.
Makes the line of the menu that is selected flash, by setting bit 7 of its attribute. The other lines have it cleared.
Input
A Number of the line to highlight
B Number of lines
HL Address of the attributes of the lines
SetFlashingAttribute 47987 AND A Jump to make the line flash if it is the first one.
47988 JR NZ,HighlightMenuItem_Steady
HighlightMenuItem_Flash 47990 SET 7,(HL) Make the line flash...
47992 JR HighlightMenuItem_NextLine ...and jump to move on to the next line.
HighlightMenuItem_Next 47994 DEC A Count down the lines.
47995 JR Z,HighlightMenuItem_Flash Jump to make the line flash if it is the one that is selected.
HighlightMenuItem_Steady 47997 RES 7,(HL) Make the line steady.
HighlightMenuItem_NextLine 47999 INC HL Move on to the next attribute.
48000 DJNZ HighlightMenuItem_Next Loop back until all of the lines have been done.
48002 RET Return.
View the equivalent code in;
Prev: 47890 Up: Map Next: 48003