Prev: 83E7 Up: Map Next: 843C
8411: Draw a number of rows of a bitmap.
Used by the routine at Wally_EnergyIncBy.
Input
B Number of rows.
IX Row Address of DF_lookup, pointing to where bitmap to drawn to on the screen.
HL Start address of bitmap to draw. Normally start of the row required.
Output
Bmp_DrawRows 8411 PUSH HL
8412 LD DE,$000B
8415 LD L,(IX+$00) Get DF address.
8418 LD H,(IX+$01)
841B INC IX Next row.
841D INC IX
841F ADD HL,DE Offset for column position of milk bitmap on screen.
8420 EX DE,HL
8421 POP HL
8422 LDI Blit one bitmap row.
8424 LDI
8426 LDI
8428 LD A,(MilkLevel) Shift milk level down one row.
842B INC A
842C LD (MilkLevel),A
842F CP $20 Make sure glass isn't empty.
8431 JR NZ,Bmp_DrawRows_0
8433 LD A,$01 No more milk, trigger death.
8435 LD (DeathFlag),A
8438 RET
Bmp_DrawRows_0 8439 DJNZ Bmp_DrawRows Do again.
843B RET
Prev: 83E7 Up: Map Next: 843C