Routines
| Prev: 9965 | Up: Map | Next: 9A7D |
99FC: Routines run when a statement of the case is proven
|
Each marks the current record done (9A74: IX+3 bit 1 set, bit 0 clear), sometimes sets a flag in another record, and prints a message.
|
||||||||||||
| 99FC | CALL $9A74 | Mark this record done | ||||||||||
| 99FF | LD HL,$7079 | "RIGHT THEN HOLMES WE MUST HURRY IF WE ARE TO CATCH THEM." | ||||||||||
| 9A02 | JP $A59F | ...print it and return | ||||||||||
| 9A05 | LD HL,$99FA | Point HL at $99FA in "The case: statements about the crime, and..." - Set bit 1 of the record at $99FA | ||||||||||
| 9A08 | SET 1,(HL) | Set bit 1 of the byte at $99FA in "The case: statements about the crime, and..." | ||||||||||
| 9A0A | CALL $9A74 | Call 9A74 (inside "Routines run when a statement of the case...") | ||||||||||
| 9A0D | LD HL,$70E3 | |||||||||||
| 9A10 | JP $A59F | Jump on to the routine "Print the message at HL" (A59F) | ||||||||||
| 9A13 | LD A,($9976) | Read $9976 in "The case: statements about the crime, and..." into A - Needs bit 1 of $9976... | ||||||||||
| 9A16 | AND $02 | Isolate bit 1 of A (mask $02) | ||||||||||
| 9A18 | JR Z,$9A2F | If bit 1 of A was clear, skip ahead to 9A2F | ||||||||||
| 9A1A | LD A,($9984) | Read $9984 in "The case: statements about the crime, and..." into A - ...and of $9984 | ||||||||||
| 9A1D | AND $02 | Isolate bit 1 of A (mask $02) | ||||||||||
| 9A1F | JR Z,$9A2F | If bit 1 of A was clear, skip ahead to 9A2F | ||||||||||
| 9A21 | CALL $9A74 | Both: mark done | ||||||||||
| 9A24 | LD HL,$99B2 | Point HL at $99B2 in "The case: statements about the crime, and..." - Set bit 1 of $99B2 | ||||||||||
| 9A27 | SET 1,(HL) | Set bit 1 of the byte at $99B2 in "The case: statements about the crime, and..." | ||||||||||
| 9A29 | LD HL,$7099 | Point HL at the message "VERY GOOD HOLMES, BASIL WILL LIKELY TRY TO SELL... (7099) | ||||||||||
| 9A2C | JP $A59F | Jump on to the routine "Print the message at HL" (A59F) | ||||||||||
| 9A2F | RES 1,(IX+$03) | Clear bit 1 of byte +3 of the record at IX - Otherwise clear both bits | ||||||||||
| 9A33 | RES 0,(IX+$03) | Clear bit 0 of byte +3 of the record at IX | ||||||||||
| 9A37 | LD HL,$7265 | Point HL at the message "YOU SAY" THAT MAY WELL BE, HOLMES, I WILL THINK... (7265) | ||||||||||
| 9A3A | JP $A59F | Jump on to the routine "Print the message at HL" (A59F) | ||||||||||
| 9A3D | CALL $9A74 | Call 9A74 (inside "Routines run when a statement of the case...") | ||||||||||
| 9A40 | LD A,$01 | Load A with $01 - Set $9E88 | ||||||||||
| 9A42 | LD ($9E88),A | Store A in $9E88 in "Game-over record: the Major is arrested" | ||||||||||
| 9A45 | LD HL,$70F0 | Point HL at the message "VERY GOOD HOLMES, I SHALL RETURN TO LEATHER HEAD... (70F0) | ||||||||||
| 9A48 | JP $A59F | Jump on to the routine "Print the message at HL" (A59F) | ||||||||||
| 9A4B | CALL $9A74 | Call 9A74 (inside "Routines run when a statement of the case...") | ||||||||||
| 9A4E | LD HL,$9976 | Point HL at $9976 in "The case: statements about the crime, and..." - Set bit 1 of $9976 | ||||||||||
| 9A51 | SET 1,(HL) | Set bit 1 of the byte at $9976 in "The case: statements about the crime, and..." | ||||||||||
| 9A53 | LD HL,$6FAB | Point HL at the message "SO MRS BROWN KILLED HERSELF, EXCELLENT HOLMES,... (6FAB) | ||||||||||
| 9A56 | JP $A59F | Jump on to the routine "Print the message at HL" (A59F) | ||||||||||
| 9A59 | CALL $9A74 | Call 9A74 (inside "Routines run when a statement of the case...") | ||||||||||
| 9A5C | LD A,$5F | Load A with $5F - Thing $5F (95)... | ||||||||||
| 9A5E | CALL $D237 | Call the routine "Resolve an id (in A) to its full entity record" (D237) | ||||||||||
| 9A61 | LD (IX+$01),$FF | ...is in nothing... | ||||||||||
| 9A65 | LD (IX+$0F),$00 | ...and goes off stage (room 0) | ||||||||||
| 9A69 | LD HL,$9984 | Point HL at $9984 in "The case: statements about the crime, and..." - Set bit 1 of $9984 | ||||||||||
| 9A6C | SET 1,(HL) | Set bit 1 of the byte at $9984 in "The case: statements about the crime, and..." | ||||||||||
| 9A6E | LD HL,$6FCA | (6FCA) | ||||||||||
| 9A71 | JP $A59F | Jump on to the routine "Print the message at HL" (A59F) | ||||||||||
| 9A74 | SET 1,(IX+$03) | Mark the record at IX done: bit 1 set... | ||||||||||
| 9A78 | RES 0,(IX+$03) | Clear bit 0 of byte +3 of the record at IX - ...bit 0 clear | ||||||||||
| 9A7C | RET | Return to the caller | ||||||||||
| Prev: 9965 | Up: Map | Next: 9A7D |