| Alien (BUGFIX 1.7) | Routines |
| Prev: 31241 | Up: Map | Next: 31393 |
|
Draws one 8-pixel-tall column of a sprite tile onto the screen. Reads a tile index byte from (DE), multiplies by 8 to get an offset into the 8-byte-per-row character bitmap table at $68F5 (26869 + index×8), then writes all 8 bytes vertically downward from the current draw pointer at 31257 (INC H steps through ZX Spectrum display rows within the same character cell column).
Input: (DE) = tile/character index; (31257) = screen destination address Output: screen updated; DE advanced; H incremented 8 times
|
||||
| 31369 | LD A,(DE) | read tile index from source pointer | ||
|
This entry point is used by the routines at 32143, 32536, 32670, 33479, 37322 and 40149.
|
||||
| 31370 | LD L,A | L = tile index | ||
| 31371 | LD H,0 | |||
| 31373 | ADD HL,HL | HL = index × 2 | ||
| 31374 | ADD HL,HL | HL = index × 4 | ||
| 31375 | ADD HL,HL | HL = index × 8 | ||
| 31376 | LD BC,26869 | BC = $68F5 (character bitmap base) | ||
| 31379 | ADD HL,BC | HL = address of first row of tile bitmap | ||
| 31380 | EX DE,HL | DE = bitmap source; HL = old DE (tile index ptr) | ||
| 31381 | LD HL,(31257) | HL = screen destination (DrawScreenPtr) | ||
| 31384 | LD B,8 | 8 pixel rows per character | ||
| 31386 | LD A,(DE) | read bitmap byte for this pixel row | ||
| 31387 | LD (HL),A | write to display file | ||
| 31388 | INC H | next display row (INC H steps within 8-row band) | ||
| 31389 | INC DE | next bitmap byte | ||
| 31390 | DJNZ 31386 | repeat for all 8 rows | ||
| 31392 | RET | |||
| Prev: 31241 | Up: Map | Next: 31393 |