H | Character number of teacher (201-204) |
61555 | 3AE47F | LD A,(32740) | Pick up the MSB of the lesson time counter (starts at 16) |
61558 | FE0C | CP 12 | Is it time to tell the kids to sit down yet? |
61560 | 3806 | JR C,61568 | Jump if so |
61562 | 2E1D | LD L,29 | Otherwise signal that the table of A&P is to be repeated |
61564 | CBC6 | SET 0,(HL) | |
61566 | 1817 | JR 61591 | |
61568 | CD7D62 | CALL 25213 | Collect the next byte (event indicator) from the table of A&P |
61571 | 4F | LD C,A | C=event indicator (8, 9, 10, 11, 12) |
61572 | CD8F7C | CALL 31887 | Has this event happened yet? |
61575 | 200E | JR NZ,61591 | Jump if so |
61577 | 79 | LD A,C | Otherwise signal that the event has certainly happened now |
61578 | CD987C | CALL 31896 | |
61581 | 7C | LD A,H | A=character number of teacher |
61582 | D66D | SUB 109 | A=92, 93, 94 or 95 (appropriate SIT DOWN message) |
61584 | 5F | LD E,A | |
61585 | 01086A | LD BC,27144 | Redirect control to the routine at 27144 (make character speak) and then return to 61591 |
61588 | CD9F63 | CALL 25503 | |
61591 | C38C63 | JP 25484 | Move to the next instruction in the table of A&P |