Routines
| Prev: C491 | Up: Map | Next: C4B2 |
C493: Set the direct object's requirement from the parsed words
|
||||||||||||
| C493 | XOR A | Clear A to zero (and the carry flag) - Requirement 0: no direct object | ||||||||||
| C494 | LD HL,$A01D | Point HL at $A01D in "Game variables" | ||||||||||
| C497 | BIT 3,(HL) | Test bit 3 of the byte at $A01D in "Game variables" - $A01D bit 3 (a direct object) clear: store 0 | ||||||||||
| C499 | JR Z,$C4AE | If bit 3 of the byte at $A01D in "Game variables" is clear, skip ahead to C4AE | ||||||||||
| C49B | LD A,$04 | Requirement 4... | ||||||||||
| C49D | BIT 7,(HL) | Test bit 7 of the byte at $A01D in "Game variables" - ...if bit 7 is set | ||||||||||
| C49F | JR NZ,$C4AE | If bit 7 of the byte at $A01D in "Game variables" is set, skip ahead to C4AE | ||||||||||
| C4A1 | LD A,($A01E) | Read $A01E in "Game variables" into A - Else: both of $A01E's bits 2-3 set (a number)? | ||||||||||
| C4A4 | AND $0C | Keep only bits 2, 3 of A (mask $0C) | ||||||||||
| C4A6 | CP $0C | Compare A with $0C | ||||||||||
| C4A8 | LD A,$05 | Load A with $05 - Yes: requirement 5 | ||||||||||
| C4AA | JR Z,$C4AE | If A equals $0C, skip ahead to C4AE | ||||||||||
| C4AC | LD A,$07 | No: 7, an ordinary thing | ||||||||||
| C4AE | LD ($A00F),A | Store A in $A00F in "Game variables" - Store at $A00F | ||||||||||
| C4B1 | RET | Return to the caller | ||||||||||
| Prev: C491 | Up: Map | Next: C4B2 |