Prev: C97A Up: Map Next: C9FC
C9EF: Print a string in one colour
Used by the routine at DISPLAY_MENU.
Prints straight onto the screen in the font (FONT), colouring each character's cell as it goes (PRINT_CHAR_COLOURED). The rest is in PRINT_TEXT. The menu's lines are printed with it (DISPLAY_MENU). Unlike Alien 8's printer, which draws into its screen buffer, Nightshade's text goes straight to the display: the play area is the only part of the screen it buffers.
Input
HL the position: L = x, H = y, in pixels, y counting up from the bottom of the screen
DE the string, ASCII with bit 7 set on the last character
A' the colour
Output
DE the byte after the string
PRINT_TEXT_SINGLE_COLOUR C9EF PUSH HL the text font: FONT_BASE 384 bytes below the font, so that a letter's code lands on its character
C9F0 LD HL,$6B5E
C9F3 LD (FONT_BASE),HL
C9F6 POP HL
C9F7 CALL CALC_VRAM_ADDR HL = the screen address of the position (CALC_VRAM_ADDR); print
C9FA JR PRINT_TEXT_CHAR
Prev: C97A Up: Map Next: C9FC