![]() |
Routines |
| Prev: 34695 | Up: Map | Next: 34823 |
|
XOR one graphic row from DE onto the screen at HL.
|
||||||||||
|
XOR one graphic row from DE onto the screen at HL.
|
||||||||||
| WriteSpriteRow | 34745 | LD A,C | Jump to ContinueSpriteWrite if the row counter is zero. | |||||||
| 34746 | AND A | |||||||||
| 34747 | JR Z,ContinueSpriteWrite | |||||||||
| 34749 | DEC C | Decrease the row counter by one. | ||||||||
| 34750 | PUSH BC | Stash the counters and screen address. | ||||||||
| 34751 | PUSH HL | |||||||||
| WriteSpriteRow_Loop | 34752 | LD A,(DE) | XOR the next graphic byte onto the screen. | |||||||
| 34753 | INC DE | |||||||||
| 34754 | XOR (HL) | |||||||||
| 34755 | LD (HL),A | |||||||||
| 34756 | INC L | Move to the next column and loop back to WriteSpriteRow_Loop. | ||||||||
| 34757 | DJNZ WriteSpriteRow_Loop | |||||||||
|
Skip the unused graphic bytes, then step up one pixel line.
|
||||||||||
| WriteSpriteRow_SkipRest | 34759 | JR WriteSpriteRow_SkipRest | Self-modifying skip. The operand is written by 35064. | |||||||
| 34761 | INC DE | Skip the remaining bytes of this graphic row. | ||||||||
| 34762 | INC DE | |||||||||
| 34763 | INC DE | |||||||||
| 34764 | INC DE | |||||||||
| 34765 | INC DE | |||||||||
| 34766 | INC DE | |||||||||
| 34767 | INC DE | |||||||||
| 34768 | INC DE | |||||||||
| 34769 | INC DE | |||||||||
| 34770 | INC DE | |||||||||
| 34771 | INC DE | |||||||||
| 34772 | INC DE | |||||||||
| 34773 | INC DE | |||||||||
| 34774 | INC DE | |||||||||
| 34775 | INC DE | |||||||||
| 34776 | INC DE | |||||||||
| 34777 | POP HL | Restore the screen address from the stack. | ||||||||
| 34778 | CALL ScreenPosition1PixelAbove | Call ScreenPosition1PixelAbove. | ||||||||
| 34781 | POP BC | Restore the counters from the stack. | ||||||||
|
Switch to the other sprite and write its next row if it has rows left.
|
||||||||||
| 34782 | EXX | Jump to WriteSpriteRow_NextSide if the shadow row counter is zero. | ||||||||
| 34783 | LD A,C | |||||||||
| 34784 | AND A | |||||||||
| 34785 | JR Z,WriteSpriteRow_NextSide | |||||||||
|
This entry point is used by the routine at ContinueSpriteWrite.
|
||||||||||
| WriteSpriteRow_DecreaseShadow | 34787 | DEC C | Decrease the shadow row counter. | |||||||
| 34788 | PUSH BC | Stash the counters and the screen address on the stack. | ||||||||
| 34789 | PUSH HL | |||||||||
| WriteSpriteRow_XORByte | 34790 | LD A,(DE) | XOR the next graphic byte onto the screen. | |||||||
| 34791 | INC DE | |||||||||
| 34792 | XOR (HL) | |||||||||
| 34793 | LD (HL),A | |||||||||
| 34794 | INC L | Move to the next column and loop back to WriteSpriteRow_XORByte. | ||||||||
| 34795 | DJNZ WriteSpriteRow_XORByte | |||||||||
|
Skip the unused graphic bytes, then step up one pixel line.
|
||||||||||
| WriteSpriteRow_SkipGraphic | 34797 | JR WriteSpriteRow_SkipGraphic | Self-modifying skip. The operand is written by 34896 and ReadSpriteHeader_Loop. | |||||||
| 34799 | INC DE | Skip the remaining bytes of this graphic row. | ||||||||
| 34800 | INC DE | |||||||||
| 34801 | INC DE | |||||||||
| 34802 | INC DE | |||||||||
| 34803 | INC DE | |||||||||
| 34804 | INC DE | |||||||||
| 34805 | INC DE | |||||||||
| 34806 | INC DE | |||||||||
| 34807 | INC DE | |||||||||
| 34808 | INC DE | |||||||||
| 34809 | INC DE | |||||||||
| 34810 | INC DE | |||||||||
| 34811 | INC DE | |||||||||
| 34812 | INC DE | |||||||||
| 34813 | INC DE | |||||||||
| 34814 | INC DE | |||||||||
| 34815 | POP HL | Restore the screen address from the stack. | ||||||||
| 34816 | CALL ScreenPosition1PixelAbove | Call ScreenPosition1PixelAbove. | ||||||||
| 34819 | POP BC | Restore the counters from the stack. | ||||||||
| WriteSpriteRow_NextSide | 34820 | EXX | Switch back and loop to WriteSpriteRow. | |||||||
| 34821 | JR WriteSpriteRow | |||||||||
| Prev: 34695 | Up: Map | Next: 34823 |