Routines |
Prev: 27159 | Up: Map | Next: 27302 |
27175 | LD A,(HL) | A=*HL. | ||
27176 | RLCA | RLCA. | ||
27177 | RLCA | |||
27178 | RLCA | |||
27179 | RLCA | |||
27180 | LD L,A | L=A. | ||
27181 | AND %00001111 | Keep only bits 0-3. | ||
27183 | ADD A,192 | H=192+A. | ||
27185 | LD H,A | |||
27186 | LD A,L | A=L. | ||
27187 | AND %11110000 | Keep only bits 4-7. | ||
27189 | ADD A,C | A+=C. | ||
27190 | LD L,A | L=A. | ||
27191 | LD A,(HL) | A=*HL. | ||
27192 | INC L | Increment L by one. | ||
27193 | LD (30772),A | Write A to *30772. | ||
27196 | LD A,(HL) | A=*HL. | ||
27197 | LD HL,30758 | HL=30758. | ||
27200 | LD (HL),0 | Write 0 to *HL. | ||
27202 | RRCA | RRCA. | ||
27203 | JR NC,27206 | Jump to 27206 if {} is higher. | ||
27205 | INC (HL) | Increment *HL by one. | ||
27206 | RRCA | RRCA. | ||
27207 | LD C,A | C=A. | ||
27208 | JR NC,27245 | Jump to 27245 if {} is higher. | ||
27210 | AND %00000011 | Keep only bits 0-1. | ||
27212 | LD L,51 | L=51. | ||
27214 | JR NZ,27217 | Jump to 27217 if {} is not zero. | ||
27216 | DEC (HL) | Decrease *HL by one. | ||
27217 | DEC A | Decrease A by one. | ||
27218 | JR NZ,27221 | Jump to 27221 if A is not zero. | ||
27220 | INC (HL) | Increment *HL by one. | ||
27221 | LD L,38 | L=38. | ||
27223 | LD B,A | B=A. | ||
27224 | LD A,35 | A=35. | ||
27226 | SUB (HL) | A-=*HL. | ||
27227 | LD L,A | L=A. | ||
27228 | LD A,(HL) | A=*HL. | ||
27229 | DEC B | Decrease B by one. | ||
27230 | JR NZ,27237 | Jump to 27237 if B is not zero. | ||
27232 | CP 105 | Jump to 27237 if A is equal to 105. | ||
27234 | JR Z,27237 | |||
27236 | DEC (HL) | Decrease *HL by one. | ||
27237 | DEC B | Decrease B by one. | ||
27238 | JR NZ,27245 | Jump to 27245 if B is not zero. | ||
27240 | CP 150 | Jump to 27245 if A is equal to 150. | ||
27242 | JR Z,27245 | |||
27244 | INC (HL) | Increment *HL by one. | ||
27245 | LD L,38 | L=38. | ||
27247 | LD A,(HL) | Jump to 27284 if *HL is not zero. | ||
27248 | AND A | |||
27249 | JR NZ,27284 | |||
27251 | LD L,34 | L=34. | ||
27253 | LD A,(HL) | Jump to 27259 if bit 7 of *HL is set. | ||
27254 | BIT 7,A | |||
27256 | JR NZ,27259 | |||
27258 | CPL | Invert the bits in A. | ||
27259 | LD B,A | B=A. | ||
27260 | DEC L | Decrease L by one. | ||
27261 | LD A,(HL) | Jump to 27267 if bit 7 of *HL is set. | ||
27262 | BIT 7,A | |||
27264 | JR NZ,27267 | |||
27266 | CPL | A=0. | ||
27267 | SUB B | A-=B. | ||
27268 | JR NC,27284 | Jump to 27284 if {} is higher. | ||
27270 | CPL | Invert the bits in A. | ||
27271 | SRL A | Shift A right twice. | ||
27273 | SRL A | |||
27275 | LD L,52 | L=52. | ||
27277 | ADD A,(HL) | A+=*HL. | ||
27278 | BIT 4,A | Jump to 27283 if bit 4 of A is not set. | ||
27280 | JR Z,27283 | |||
27282 | DEC A | Decrease A by one. | ||
27283 | LD (HL),A | Write A to *HL. | ||
27284 | LD A,C | A=C. | ||
27285 | RRCA | RRCA. | ||
27286 | RRCA | |||
27287 | RRCA | |||
27288 | RET NC | Return if {} is higher. | ||
There are 7 actions. They are contained in a jump table at: JumpTable_Actions onwards.
|
||||
27289 | AND %00000111 | Keep only bits 0-2. | ||
27291 | ADD A,A | L=220+(A*2). | ||
27292 | ADD A,220 | |||
27294 | LD L,A | |||
27295 | LD H,180 | H=180. | ||
Fetch the related action from the jump table and jump to it.
|
||||
27297 | LD A,(HL) | A=*HL. | ||
27298 | INC L | Increment L by one. | ||
27299 | LD H,(HL) | H=*HL. | ||
27300 | LD L,A | L=A. | ||
27301 | JP (HL) | Jump to *HL. |
Prev: 27159 | Up: Map | Next: 27302 |