![]() |
Routines |
Prev: 37376 | Up: Map | Next: 37434 |
|
||||||||||||
Calculates the new address for writing a sprite pixel, in a downward direction, taking into consideration the screen memory layout.
|
||||||||||||
ScreenPos1PixelBelow | 37417 | INC H | Increment H by one to move down one pixel on screen. | |||||||||
37418 | LD A,H | Stash H in A temporarily. | ||||||||||
37419 | AND %00000111 | Keep only bits 0-2. | ||||||||||
37421 | JR NZ,ScreenPos1PixelBelow_Return | If a character line has not been crossed then jump to ScreenPos1PixelBelow_Return to return. | ||||||||||
37423 | LD A,32 | L+=32. | ||||||||||
37425 | ADD A,L | |||||||||||
37426 | LD L,A | |||||||||||
37427 | JR C,ScreenPos1PixelBelow_Return | If a new section of the screen has not been crossed, jump to ScreenPos1PixelBelow_Return to return. | ||||||||||
37429 | LD A,H | H-=8. | ||||||||||
37430 | SUB 8 | |||||||||||
37432 | LD H,A | |||||||||||
ScreenPos1PixelBelow_Return | 37433 | RET | Return. |
Prev: 37376 | Up: Map | Next: 37434 |