![]() |
Routines |
| Prev: 27927 | Up: Map | Next: 28070 |
|
Used by the routine at 24576.
|
||||||||||||
| 27982 | PUSH BC | Save the tile counter. | ||||||||||
| 27983 | LD A,(HL) | Pick up a data byte. | ||||||||||
| 27984 | AND 48 | Keep only bits 4 and 5. | ||||||||||
| 27986 | CP 0 | Are bits 4 and 5 both reset? | ||||||||||
| 27988 | JR Z,28010 | Jump if so. | ||||||||||
| 27990 | CP 16 | Is bit 4 set and bit 5 reset? | ||||||||||
| 27992 | JR Z,28006 | Jump if so. | ||||||||||
| 27994 | CP 32 | Is bit 4 reset and bit 5 set? | ||||||||||
| 27996 | JR Z,28002 | Jump if so. | ||||||||||
| 27998 | LD C,%11111111 | Bits 5 and 4 of A are both set. | ||||||||||
| 28000 | JR 28012 | |||||||||||
| 28002 | LD C,%00001111 | Bit 5 of A is reset and bit 4 is set. | ||||||||||
| 28004 | JR 28012 | |||||||||||
| 28006 | LD C,%11110000 | Bit 5 of A is set and bit 4 is reset. | ||||||||||
| 28008 | JR 28012 | |||||||||||
| 28010 | LD C,%00000000 | Bits 5 and 4 of A are both reset. | ||||||||||
| 28012 | LD B,4 | Draw the top four pixel rows of the character cell using the bit pattern in C. | ||||||||||
| 28014 | LD A,C | |||||||||||
| 28015 | LD (DE),A | |||||||||||
| 28016 | INC D | |||||||||||
| 28017 | DJNZ 28015 | |||||||||||
| 28019 | LD A,(HL) | Pick up the data byte again. | ||||||||||
| 28020 | AND 3 | Keep only bits 0 and 1. | ||||||||||
| 28022 | CP 0 | Are bits 0 and 1 both reset? | ||||||||||
| 28024 | JR Z,28046 | Jump if so. | ||||||||||
| 28026 | CP 1 | Is bit 0 set and bit 1 reset? | ||||||||||
| 28028 | JR Z,28042 | Jump if so. | ||||||||||
| 28030 | CP 2 | Is bit 0 reset and bit 1 set? | ||||||||||
| 28032 | JR Z,28038 | Jump if so. | ||||||||||
| 28034 | LD C,%11111111 | Bits 1 and 0 of A are both set. | ||||||||||
| 28036 | JR 28048 | |||||||||||
| 28038 | LD C,%00001111 | Bit 1 of A is reset and bit 0 is set. | ||||||||||
| 28040 | JR 28048 | |||||||||||
| 28042 | LD C,%11110000 | Bit 1 of A is set and bit 0 is reset. | ||||||||||
| 28044 | JR 28048 | |||||||||||
| 28046 | LD C,%00000000 | Bits 1 and 0 of A are both reset. | ||||||||||
| 28048 | LD B,4 | Draw the bottom four pixel rows of the character cell using the bit pattern in C. | ||||||||||
| 28050 | LD A,C | |||||||||||
| 28051 | LD (DE),A | |||||||||||
| 28052 | INC D | |||||||||||
| 28053 | DJNZ 28051 | |||||||||||
| 28055 | INC E | Set DE to the display file address of the next cell to the right. | ||||||||||
| 28056 | JR Z,28062 | |||||||||||
| 28058 | LD A,D | |||||||||||
| 28059 | SUB 8 | |||||||||||
| 28061 | LD D,A | |||||||||||
| 28062 | INC HL | Point HL at the next data byte. | ||||||||||
| 28063 | POP BC | Restore the tile counter to BC. | ||||||||||
| 28064 | DEC BC | Decrement the tile counter. | ||||||||||
| 28065 | LD A,B | Is it zero now? | ||||||||||
| 28066 | OR C | |||||||||||
| 28067 | JR NZ,27982 | Jump back if not. | ||||||||||
| 28069 | RET | |||||||||||
| Prev: 27927 | Up: Map | Next: 28070 |