Prev: 55442 Up: Map Next: 55678
55444: Routine at D894
Used by the routine at 55678.
55444 LD HL,55354 HL=Time.
55447 RES 0,(HL) Reset bit 0 of *HL.
55449 LD HL,55353 HL=55353.
55452 SET 7,(HL) Set bit 7 of *HL.
55454 CALL Colourise_PreviewGrid Call Colourise_PreviewGrid.
55457 LD HL,22565 HL=22565 (attribute buffer location).
55460 LD B,4 B=4.
55462 PUSH BC Stash BC on the stack.
55463 LD B,16 B=16.
55465 LD (HL),0 Write 0 to *HL.
55467 INC HL Increment HL by one.
55468 DJNZ 55465 Decrease counter by one and loop back to 55465 until counter is zero.
55470 LD DE,16 HL+=0016.
55473 ADD HL,DE
55474 POP BC Restore BC from the stack.
55475 DJNZ 55462 Decrease counter by one and loop back to 55462 until counter is zero.
55477 LD BC,250 BC=0250.
55480 DI Disable interrupts.
55481 LD D,14 D=14.
55483 LD A,5 A=5.
55485 OUT (254),A Send to the speaker.
55487 XOR %00010000 Flip bit 4.
55489 LD E,C E=C.
55490 DEC E Decrease E by one.
55491 JR NZ,55490 Jump to 55490 if E is not zero.
55493 DEC D Decrease D by one.
55494 JR NZ,55485 Jump to 55485 if D is not zero.
55496 DEC BC Decrease BC by one.
55497 LD A,B Jump to 55481 if BC is not zero.
55498 OR C
55499 JR NZ,55481
55501 EI Enable interrupts.
55502 CALL 59839 Call 59839.
55505 LD B,100 B=100.
55507 HALT Halt operation (suspend CPU until the next interrupt).
55508 DJNZ 55507 Decrease counter by one and loop back to 55507 until counter is zero.
55510 DI Disable interrupts.
55511 LD HL,55354 HL=Time.
55514 LD (HL),128 Write 128 to *HL.
55516 CALL 64621 Call 64621.
55519 LD A,(55390) A=*55390.
55522 INC A Increment A by one.
55523 LD D,A D=A.
55524 LD E,125 E=125.
55526 LD H,1 H=1.
55528 LD A,(HL) A=*HL.
55529 AND %00011000 Keep only bits 3-4.
55531 OR %00000101 Set bits 0, 2.
55533 OUT (254),A Set border to the colour held by A.
55535 INC HL Increment HL by one.
55536 LD B,D B=D.
55537 DJNZ 55537 Decrease counter by one and loop back to 55537 until counter is zero.
55539 DEC E Decrease E by one.
55540 JP NZ,55528 Jump to 55528 if E is not zero.
55543 LD HL,55354 HL=Time.
55546 BIT 4,(HL) Test bit 4 of *HL.
55548 JR NZ,55576 Jump to 55576 if E is not zero.
55550 LD A,(55360) A=*55360.
55553 AND A Set flags.
55554 INC A Increment A by one.
55555 DAA DAA.
55556 LD (55360),A Write A to *55360.
55559 JR NC,55570 Jump to 55570 if A is higher.
55561 LD A,(55359) A=*55359.
55564 CCF Invert the carry flag.
55565 INC A Increment A by one.
55566 DAA DAA.
55567 LD (55359),A Write A to *55359.
55570 CALL Print_Bonus Call Print_Bonus.
55573 JP 55516 Jump to 55516.
55576 LD HL,55361 HL=55361.
55579 LD A,(55414) A=*Score_Digit_03.
55582 AND A Set flags.
55583 ADD A,(HL) A+=*HL.
55584 DAA DAA.
55585 LD (55414),A Write A to *Score_Digit_03.
55588 LD (HL),0 Write 0 to *HL.
55590 DEC HL Decrease HL by one.
55591 LD A,(55413) A=*Score_Digit_02.
55594 ADC A,(HL) A+=*HL.
55595 DAA DAA.
55596 LD (55413),A Write A to *Score_Digit_02.
55599 LD (HL),0 Write 0 to *HL.
55601 DEC HL Decrease HL by one.
55602 LD A,(55412) A=*Score_Digit_01.
55605 ADC A,(HL) A+=*HL.
55606 DAA DAA.
55607 LD (55412),A Write A to *Score_Digit_01.
55610 LD (HL),0 Write 0 to *HL.
55612 LD HL,61674 HL=61674.
55615 LD B,35 B=35.
55617 CALL 61258 Call 61258.
55620 CALL Print_Bonus Call Print_Bonus.
55623 CALL Print_Score Call Print_Score.
55626 LD A,(55405) Jump to 55658 if *55405 is not equal to 0.
55629 CP 0
55631 JR NZ,55658
55633 LD A,(55412) A=*Score_Digit_01.
55636 AND %11110000 Keep only bits 4-7.
55638 RRCA RRCA.
55639 RRCA
55640 RRCA
55641 RRCA
55642 CP 1 Jump to 55658 if A is lower than 1 (unsigned comparison).
55644 JP M,55658
55647 LD A,1 Write 1 to *55405.
55649 LD (55405),A
55652 CALL 59839 Call 59839.
55655 CALL 59866 Call 59866.
55658 LD A,128 Write 128 to *Bomb.
55660 LD (55352),A
55663 CALL Handler_PlayerInput Call Handler_PlayerInput.
55666 CP 0 Jump back to 55663 until there's any player input.
55668 JR Z,55663
55670 XOR A Write 0 to *Bomb.
55671 LD (55352),A
55674 CALL 61025 Call 61025.
55677 RET Return.
Prev: 55442 Up: Map Next: 55678