Routines |
Prev: 37090 | Up: Map | Next: 37417 |
Used by the routine at StartGame.
|
||||
37132 | DI | Disable interrupts. | ||
37133 | LD IX,37044 | IX=37044. | ||
37137 | LD HL,47086 | HL=47086. | ||
37140 | LD DE,37090 | DE=37090. | ||
37143 | LD B,3 | B=3. | ||
37145 | LD A,(HL) | A=*HL. | ||
37146 | RRA | RRA. | ||
37147 | RRA | RRA. | ||
37148 | RRA | RRA. | ||
37149 | RRA | RRA. | ||
37150 | AND %00001111 | Keep only bits 0-3. | ||
37152 | LD (DE),A | Write A to *DE. | ||
37153 | INC DE | Increment DE by one. | ||
37154 | LD A,(HL) | A=*HL. | ||
37155 | AND %00001111 | Keep only bits 0-3. | ||
37157 | LD (DE),A | Write A to *DE. | ||
37158 | INC DE | Increment DE by one. | ||
37159 | DEC HL | Decrease HL by one. | ||
37160 | DJNZ 37145 | Decrease counter by one and loop back to 37145 until counter is zero. | ||
37162 | LD IY,37090 | IY=37090. | ||
37166 | LD D,11 | D=11. | ||
37168 | LD B,6 | B=6. | ||
37170 | PUSH IY | Stash IY on the stack. | ||
37172 | PUSH IX | Stash IX on the stack. | ||
37174 | LD A,(IX+0) | A=*IX+0. | ||
37177 | CP (IY+0) | |||
37180 | JR C,37200 | Jump to 37200 if {} is lower. | ||
37182 | JR NZ,37190 | Jump to 37190 if {} is not zero. | ||
37184 | INC IX | Increment IX by one. | ||
37186 | INC IY | Increment IY by one. | ||
37188 | DJNZ 37174 | Decrease counter by one and loop back to 37174 until counter is zero. | ||
37190 | POP IX | Restore IX from the stack. | ||
37192 | POP IY | Restore IY from the stack. | ||
37194 | LD A,D | A=D. | ||
37195 | CP 11 | Return if A equals 11. | ||
37197 | RET Z | |||
37198 | JR 37214 | Jump to 37214. | ||
37200 | DEC D | Decrease D by one. | ||
37201 | POP IX | Restore IX from the stack. | ||
37203 | POP IY | Restore IY from the stack. | ||
37205 | LD BC,65518 | BC=65518. | ||
37208 | ADD IX,BC | IX+=BC. | ||
37210 | LD A,D | A=D. | ||
37211 | DEC A | Decrease A by one. | ||
37212 | JR NZ,37168 | Jump to 37168 if A is not zero. | ||
37214 | LD A,10 | A=10. | ||
37216 | SUB D | A-=D. | ||
37217 | JR Z,37241 | Jump to 37241 if A is zero. | ||
37219 | LD DE,37057 | DE=37057. | ||
37222 | LD HL,37039 | HL=37039. | ||
37225 | LD BC,14 | BC=0014. | ||
37228 | LDDR | LDDR. | ||
37230 | DEC HL | Decrease HL by four. | ||
37231 | DEC HL | |||
37232 | DEC HL | |||
37233 | DEC HL | |||
37234 | DEC DE | Decrease DE by four. | ||
37235 | DEC DE | |||
37236 | DEC DE | |||
37237 | DEC DE | |||
37238 | DEC A | Decrease A by one. | ||
37239 | JR NZ,37225 | Jump to 37225 until A is zero. | ||
37241 | LD DE,18 | DE=0018. | ||
37244 | ADD IX,DE | IX+=DE. | ||
37246 | PUSH IX | Stash IX on the stack. | ||
37248 | POP DE | Restore DE from the stack. | ||
37249 | LD HL,37090 | HL=37090. | ||
37252 | LD BC,6 | BC=0006. | ||
37255 | LDIR | LDIR. | ||
37257 | LD C,38 | C=38. | ||
37259 | LD (IX+9),10 | Write 9 to *IX+9. | ||
37263 | LD (IX+10),C | Write C to *IX+10. | ||
37266 | LD (IX+11),C | Write C to *IX+11. | ||
37269 | LD (IX+12),C | Write C to *IX+12. | ||
37272 | LD (IX+13),C | Write C to *IX+13. | ||
37275 | CALL 38829 | Call 38829. | ||
37278 | CALL 38844 | Call 38844. | ||
37281 | CALL 37483 | Call 37483. | ||
37284 | LD A,(47078) | A=*47078. | ||
37287 | INC A | Increment A by one. | ||
37288 | LD (37109),A | Write A to *37109. | ||
37291 | LD DE,37096 | DE=37096. | ||
37294 | CALL PrintLine | Call PrintLine. | ||
37297 | CALL PrintLine | Call PrintLine. | ||
37300 | PUSH IX | Stash IX on the stack. | ||
37302 | POP HL | Restore HL from the stack. | ||
37303 | DEC HL | Decrease HL by four. | ||
37304 | DEC HL | |||
37305 | DEC HL | |||
37306 | DEC HL | |||
37307 | LD (37417),HL | Write HL to *37417. | ||
37310 | LD B,5 | B=5. | ||
37312 | LD C,10 | C=10. | ||
37314 | PUSH BC | Stash BC on the stack. | ||
37315 | CALL 41435 | Call 41435. | ||
37318 | LD A,(36569) | A=*36569. | ||
37321 | AND %00010011 | Keep only bits 0-1, 4. | ||
37323 | JR Z,37315 | Jump to 37315 if A is zero. | ||
37325 | BIT 4,A | Jump to 37375 if bit 4 of A is set. | ||
37327 | JR NZ,37375 | |||
37329 | CP 3 | Jump to 37315 if A is equal to 3. | ||
37331 | JR Z,37315 | |||
37333 | POP BC | Restore BC from the stack. | ||
37334 | RRA | RRA. | ||
37335 | JR NC,37347 | Jump to 37347 if {} is higher. | ||
37337 | INC C | Increment C by one. | ||
37338 | LD A,C | A=C. | ||
37339 | CP 40 | Jump to 37354 if A is not equal to 40. | ||
37341 | JR NZ,37354 | |||
37343 | LD C,0 | C=0. | ||
37345 | JR 37354 | Jump to 37354. | ||
37347 | DEC C | Decrease C by one. | ||
37348 | BIT 7,C | Jump to 37354 if bit 7 of C is not set. | ||
37350 | JR Z,37354 | |||
37352 | LD C,39 | C=39. | ||
37354 | LD (IX+9),C | Write C to *IX+9. | ||
37357 | PUSH BC | Stash BC on the stack. | ||
37358 | LD DE,(37417) | DE=*37417. | ||
37362 | CALL PrintLine | Call PrintLine. | ||
37365 | CALL 49497 | Call 49497. | ||
37368 | LD D,32 | D=32. | ||
37370 | CALL 38867 | Call 38867. | ||
37373 | JR 37315 | Jump to 37315. | ||
37375 | CALL 49512 | Call 49512. | ||
37378 | POP BC | Restore BC from the stack. | ||
37379 | DEC B | Decrease B by one. | ||
37380 | JR Z,37409 | Jump to 37409 if B is zero. | ||
37382 | INC IX | Increment IX by one. | ||
37384 | LD (IX+9),10 | Write 9 to *IX+9. | ||
37388 | PUSH BC | Stash BC on the stack. | ||
37389 | LD DE,(37417) | DE=*37417. | ||
37393 | CALL PrintLine | Call PrintLine. | ||
37396 | CALL 41435 | Call 41435. | ||
37399 | LD A,(36569) | A=*36569. | ||
37402 | AND %00010000 | Keep only bits 4. | ||
37404 | JR NZ,37396 | Jump to 37396 if A is not zero. | ||
37406 | POP BC | Restore BC from the stack. | ||
37407 | JR 37312 | Jump to 37312. | ||
37409 | CALL 37483 | Call 37483. | ||
37412 | LD B,10 | B=10. | ||
37414 | JP 47068 | Jump to 47068. |
Prev: 37090 | Up: Map | Next: 37417 |