![]() |
Routines |
| Prev: A924 | Up: Map | Next: A96A |
|
Calls the parser check indexed in JumpTable_ParserChecks and succeeds when it returns with the carry set.
Stores A at ScriptParserResult.
|
||||||||||||
|
The operand selects a parser check from JumpTable_ParserChecks.
|
||||||||||||
| Condition_ParserFails | A947 | LD E,(IX+$01) | Fetch the check number (the operand) from *IX+01 into E. | |||||||||
| A94A | PUSH IX | Stash IX on the stack. | ||||||||||
| A94C | LD IX,$A779 | Point IX at the parser-check jump table at JumpTable_ParserChecks. | ||||||||||
|
Resolve the check routine address from that table.
|
||||||||||||
| A950 | CALL GetTableEntry | Call GetTableEntry. | ||||||||||
|
Jump to that check, returning here at ParserFails_Return.
|
||||||||||||
| A953 | LD DE,$A958 | Push the return address ParserFails_Return onto the stack. | ||||||||||
| A956 | PUSH DE | |||||||||||
| A957 | JP (HL) | Jump to the check routine held in HL. | ||||||||||
|
The check returns here with its result in A and the carry flag.
|
||||||||||||
| ParserFails_Return | A958 | POP IX | Restore the script pointer from the stack. | |||||||||
| A95A | LD ($A806),A | Store the check's result at ScriptParserResult. | ||||||||||
| A95D | JR NC,ParserFails_Passed | Jump to ParserFails_Passed if the check passed (carry clear). | ||||||||||
| A95F | XOR A | Clear A and set the zero flag; the parser check failed, so this condition succeeds. | ||||||||||
| A960 | JP RunScript_SkipCondition_TwoBytes | Jump to RunScript_SkipCondition_TwoBytes. | ||||||||||
|
The check passed, so force this "fails" condition to fail.
|
||||||||||||
| ParserFails_Passed | A963 | XOR A | Clear A ready for RunScript_InvertConditionResult. | |||||||||
| A964 | CALL RunScript_InvertConditionResult | Call RunScript_InvertConditionResult so the condition fails when the check passed. | ||||||||||
| A967 | JP RunScript_SkipCondition_TwoBytes | Jump to RunScript_SkipCondition_TwoBytes. | ||||||||||
| Prev: A924 | Up: Map | Next: A96A |