![]() |
Routines |
H | Character number of teacher (163-166) |
32178 | LD A,(32756) | Pick up the lesson descriptor from 32756 |
32181 | AND 240 | Keep only the "teacher" bits (4-7) |
32183 | RLCA | A=character number of the teacher (163-166) that is teaching ERIC and EINSTEIN this period |
32184 | RLCA | |
32185 | RLCA | |
32186 | RLCA | |
32187 | ADD A,163 | |
32189 | CP H | Set the zero flag if this teacher is teaching ERIC |
32190 | LD L,99 | |
32192 | JR Z,32199 | Jump if we're dealing with ERIC's teacher |
32194 | LD (HL),48 | Replace the address of this routine in bytes 99 and 100 of the teacher's buffer with that of 32048, and jump there now to start the lesson |
32196 | JP 32048 |
32199 | LD (HL),0 | Replace the address of this routine in bytes 99 and 100 of the teacher's buffer with that of 62208 |
32201 | INC L | |
32202 | LD (HL),243 | |
32204 | LD A,0 | Clear all the lesson status flags at 32712 |
32206 | LD (32712),A | |
32209 | JP 62208 | Start the lesson |