Prev: 17C5 Up: Map Next: 195F
185A: OELRoutine12
Used by the routine at OELRoutine07.
OELRoutine12 185A LD A,$E0
185C LD (OELVariable01),A
185F XOR A
1860 LD (OELVariable02),A
1863 LD A,$03
1865 LD (OELVariable12),A
1868 LD HL,$1A97
186B LD (OELWord12),HL
186E CALL OELRoutine14_1
1871 LD HL,$1A9A
1874 LD (OELWord12),HL
1877 LD A,$FE
1879 LD (OELVariable01),A
187C CALL OELRoutine14_1
187F LD HL,(lone_table_values)
1882 PUSH HL
1883 LD BC,$03FF
1886 ADD HL,BC
1887 EX DE,HL
1888 POP HL
OELRoutine12_0 1889 LD A,(HL)
188A CP $24
188C JR Z,OELRoutine12_1
188E CP $3C
1890 JR NZ,OELRoutine12_3
1892 INC HL
1893 INC HL
1894 INC HL
1895 JR OELRoutine12_2
OELRoutine12_1 1897 INC HL
1898 RES 7,(HL)
189A INC HL
OELRoutine12_2 189B PUSH HL
189C OR A
189D SBC HL,DE
189F POP HL
18A0 JR C,OELRoutine12_0
OELRoutine12_3 18A2 LD HL,(escape_table_values)
18A5 PUSH HL
18A6 LD BC,$03FF
18A9 ADD HL,BC
18AA EX DE,HL
18AB POP HL
OELRoutine12_4 18AC LD A,(HL)
18AD CP $24
18AF JR Z,OELRoutine12_5
18B1 CP $3C
18B3 JR NZ,OELRoutine12_7
18B5 INC HL
18B6 INC HL
18B7 INC HL
18B8 JR OELRoutine12_6
OELRoutine12_5 18BA INC HL
18BB RES 7,(HL)
18BD INC HL
OELRoutine12_6 18BE PUSH HL
18BF OR A
18C0 SBC HL,DE
18C2 POP HL
18C3 JR C,OELRoutine12_4
OELRoutine12_7 18C5 LD HL,$1A94
18C8 LD (OELWord12),HL
18CB LD A,$03
18CD LD (OELVariable12),A
18D0 LD A,$40
OELRoutine12_8 18D2 PUSH AF
18D3 LD (OELVariable01),A
18D6 CALL OELRoutine14_0
18D9 POP AF
18DA INC A
18DB CP $60
18DD JR NZ,OELRoutine12_8
18DF LD A,$C0
OELRoutine12_9 18E1 PUSH AF
18E2 LD (OELVariable01),A
18E5 CALL OELRoutine14_0
18E8 POP AF
18E9 INC A
18EA CP $E0
18EC JR NZ,OELRoutine12_9
18EE LD HL,OELWord07
18F1 LD (HL),$3C
18F3 INC HL
18F4 LD DE,(OELWord17)
18F8 LD (HL),E
18F9 INC HL
18FA LD (HL),D
18FB LD HL,OELWord09
18FE LD (HL),$3C
1900 INC HL
1901 LD DE,(OELWord23)
1905 LD (HL),E
1906 INC HL
1907 LD (HL),D
1908 LD A,$42
190A LD (OELVariable01),A
190D LD HL,OELWord09
1910 LD (OELWord12),HL
1913 CALL OELRoutine14_0
1916 LD A,$C2
1918 LD (OELVariable01),A
191B CALL OELRoutine14_0
191E LD A,$43
1920 LD HL,OELWord07
1923 LD (OELWord12),HL
1926 LD (OELVariable01),A
1929 CALL OELRoutine14_0
192C LD A,$C3
192E LD (OELVariable01),A
1931 CALL OELRoutine14_0
1934 LD HL,$1A91
1937 LD (OELWord12),HL
193A LD A,$03
193C LD (OELVariable12),A
193F XOR A
OELRoutine12_10 1940 PUSH AF
1941 LD (OELVariable01),A
1944 AND A
1945 JP PO,OELRoutine12_11
1948 CALL OELRoutine14
OELRoutine12_11 194B POP AF
194C INC A
194D JR NZ,OELRoutine12_10
194F LD HL,START
1952 LD (OELWord07),HL
1955 LD (OELWord08),HL
1958 LD (OELWord09),HL
195B LD (OELWord10),HL
195E RET
Prev: 17C5 Up: Map Next: 195F