Prev: 7149 Up: Map Next: 716D
7155: Fetch Sprite
Used by the routine at ActorFindPosDir.
GetDefaultSprite 7155 LD A,($5E22) A=5E22.
GetSprite 7158 DEC A Calculate offset for sprite lookup table.
7159 SLA A
715B AND %01111110 Keep only bits 1-6.
715D LD HL,$7F06 HL=SpritesTable.
7160 LD C,A Create an offset in BC.
7161 LD B,$00
7163 ADD HL,BC HL=SpritesTable + offset.
7164 LD E,(HL) DE=fetch sprite address pointed to by HL.
7165 INC HL
7166 LD D,(HL)
7167 RET Return.
ActorGetSprite 7168 LD A,(IX+$00) Load the sprite ID from the currently active actor.
716B JR GetSprite Jump to GetSprite.
Prev: 7149 Up: Map Next: 716D