Prev: 0A52 Up: Map Next: 0AD4
0AB8: translate_colour: Translate an alphanumeric colour code to spectrum attribute colour.
Used by the routines at alpha_colour_code and mosaics_colour_code.
translate_colour 0AB8 CALL set_attrs Set the screen attributes for this cell.
0ABB LD A,(character_code) Add character_code as offset to address of colour_translation_table.
0ABE LD C,A
0ABF LD B,$00
0AC1 LD HL,colour_translation_table
0AC4 ADD HL,BC
0AC5 LD A,(temp_attr) Clear low three bits of temp_attr and add byte from offset in colour_translation_table.
0AC8 AND $F8
0ACA ADD A,(HL)
0ACB LD (temp_attr),A
0ACE LD A,$20 Set character_code to $20 (space character) and return.
0AD0 LD (character_code),A
0AD3 RET
Prev: 0A52 Up: Map Next: 0AD4