Prev: 0A4C Up: Map Next: 0AB8
0A52: code_set_at: Display character.
code_set_at 0A52 LD A,(hold_mosaics_flag) If hold_mosaics_flag is clear then jump to display_space.
0A55 AND A
0A56 JR Z,display_space
This entry point is used by the routine at release_mosaics_code.
hold_mosaics 0A58 LD A,(mosaics_flag) If mosaics_flag is clear then jump to display_space.
0A5B AND A
0A5C JR Z,display_space
0A5E LD A,(hold_mosaic_character) Else copy hold_mosaic_character to character_code.
0A61 LD (character_code),A
0A64 JR apply_colours Skip forward to apply_colours.
display_space 0A66 LD A,$20 Set character_code to $20 (space character).
0A68 LD (character_code),A
This entry point is used by the routines at decode_row, separated_code and hold_mosaics_code.
apply_colours 0A6B CALL set_attrs
This entry point is used by the routines at alpha_colour_code, mosaics_colour_code and conceal_code.
code_set_after 0A6E CALL print_character
0A71 LD A,(column_offset) If column_offset is not 0 increment char_addr.
0A74 AND A
0A75 JR Z,char_addr_set
0A77 LD HL,(char_addr)
0A7A INC HL
0A7B LD (char_addr),HL
char_addr_set 0A7E LD HL,(character_pointer) Increment character_pointer.
0A81 INC HL
0A82 LD (character_pointer),HL
0A85 POP AF Pop column counter off the stack and decrement it. Loop back to decode_character for 40 columns.
0A86 DEC A
0A87 JP NZ,decode_character
0A8A LD A,(row_number) Return if row_number is greater than or equal to 23.
0A8D CP $17
0A8F RET NC
0A90 LD A,(row_has_double_flag) Return if row_has_double_flag is clear.
0A93 AND A
0A94 RET Z
set_bottom_row_attrs 0A95 LD HL,(current_attr_address) Else set HL to current_attr_address - 29 (second display attr byte of this row) and DE to current_attr_address + 3 (second display attr byte of next row).
0A98 LD BC,$001D
0A9B OR A
0A9C SBC HL,BC
0A9E EX DE,HL
0A9F LD HL,(current_attr_address)
0AA2 INC HL
0AA3 INC HL
0AA4 INC HL
0AA5 EX DE,HL
0AA6 LD B,$1E Set B to 30 as loop counter.
copy_attrs_down_loop. 0AA8 PUSH BC Preserve loop counter.
0AA9 LD A,(HL) Copy paper colour bits from attr byte into corresponding attr byte in next row.
0AAA AND $38
0AAC LD B,A
0AAD LD A,(DE)
0AAE AND $C7
0AB0 OR B
0AB1 LD (DE),A
0AB2 POP BC Restore loop counter and increment addresses.
0AB3 INC HL
0AB4 INC DE
0AB5 DJNZ copy_attrs_down_loop. Loop through 30 attr bytes and return.
0AB7 RET
Prev: 0A4C Up: Map Next: 0AB8