Routines

32433: Print lesson and ring bell


Used by routine at 63309

32433 21DE7F LD HL,32734
32436 7E LD A,(HL) A=255 if in demo mode, 0 otherwise
32437 3C INC A
32438 3E3F LD A,63 Message no. 63: DEMO.MODE
32440 2824 JR Z,32478 Jump if we're in demo mode
32442 2EE0 LD L,224 HL=32736
32444 7E LD A,(HL) A=lesson identifier
32445 E60F AND 15 Keep only the room identifier bits
32447 1E20 LD E,32 E=ASCII code for SPACE
32449 C67E ADD A,126
32451 57 LD D,A
32452 FE83 CP 131 Is it PLAYTIME, ASSEMBLY or DINNER?
32454 380E JR C,32470 Jump if so
32456 1E87 LD E,135 Message no. 135: REVISION (D=131: LIBRARY)
32458 280A JR Z,32470 Jump if it's REVISION LIBRARY
32460 7E LD A,(HL) A=lesson identifier
32461 E6F0 AND 240 Keep only the teacher-identifying bits
32463 07 RLCA
32464 07 RLCA
32465 07 RLCA
32466 07 RLCA
32467 C614 ADD A,20
32469 5F LD E,A E=22, 23 or 24 (teacher)
32470 2E88 LD L,136 Place the teacher message number in 32648
32472 73 LD (HL),E
32473 2E8A LD L,138 Place the room message number in 32650
32475 72 LD (HL),D
32476 3E10 LD A,16 Message no. 16: teacher/room

This entry point is used by the routine at 23907:
32478 11B05A LD DE,23216 DE=appropriate display file address
32481 0E57 LD C,87 INK 7: PAPER 2: BRIGHT 1
32483 CD466B CALL 27462 Print lesson
32486 011080 LD BC,32784 B=128, C=16
32489 51 LD D,C
32490 3E01 LD A,1
32492 C38C74 JP 29836 Ring bell