Skool Daze Routines
45800: Print a character's title and name, and walk him onto the screen (3)
Continues from 45544. Determines the animatory state of the character to be walked on screen.
A 1-8 (corresponding to one of the eight main characters)
HL 39008 (96, 152)
45800 SUB 5 Are we dealing with one of the teachers?
45802 JR C,45811 Jump if so
45804 ADD A,9 A=9-12
45806 AND 11 A=9, 10, 11, 8
45808 ADD A,A A=18, 20, 22, 16
45809 JR 45817
45811 CPL A=0-3
45812 INC A A=1-4
45813 AND 3 A=1, 2, 3, 0
45815 ADD A,25 A=26, 27, 28, 25
45817 RLCA
45818 RLCA
45819 RLCA A=144, 160, 176, 128 (boys) or 208, 216, 224, 200 (teachers)
45820 JP 46056