Prev: 61512 Up: Map Next: 61554
61533: Make a teacher tell the class what to do
Used by the routine at 61696. Makes the teacher choose between messages 89, 90 and 91 (in a lesson without ERIC and EINSTEIN, or a lesson with no question-and-answer session).
Input
H Teacher's character number (201-204)
61533 CALL 25233 A=random number
61536 CP 240 Set the carry flag if A<240, and set the zero flag if A<128
61538 BIT 7,A
61540 LD E,91
61542 JR NC,61548 Jump if it's essay time (A>=240)
61544 JR Z,61547 Jump if it's book-reading time (A<128)
61546 DEC E It's revision time (128<=A<240)
61547 DEC E
Now E holds the appropriate message number:
E Message
89 START REVISING FOR YOUR EXAMS
90 START READING AT THE NEXT CHAPTER IN YOUR BOOKS
91 WRITE AN ESSAY TITLED 'WHY I LOVE SCHOOL'
61548 LD BC,27144 Redirect control to the routine at 27144 (make character speak), then return control to the calling routine
61551 JP 25503
Prev: 61512 Up: Map Next: 61554