![]() |
Routines |
| Prev: 43277 | Up: Map | Next: 43335 |
|
Calls the parser check indexed in JumpTable_ParserChecks and succeeds when it returns with the carry clear.
Stores A at ScriptParserResult.
|
||||||||||||
|
The operand selects a parser check from JumpTable_ParserChecks.
|
||||||||||||
| Condition_ParserSucceeds | 43300 | LD E,(IX+1) | Fetch the check number (the operand) from *IX+1 into E. | |||||||||
| 43303 | PUSH IX | Stash IX on the stack. | ||||||||||
| 43305 | LD IX,42873 | Point IX at the parser-check jump table at JumpTable_ParserChecks. | ||||||||||
|
Resolve the check routine address from that table.
|
||||||||||||
| 43309 | CALL GetTableEntry | Call GetTableEntry. | ||||||||||
|
Jump to that check, returning here at ParserSucceeds_Return.
|
||||||||||||
| 43312 | LD DE,43317 | Push the return address ParserSucceeds_Return onto the stack. | ||||||||||
| 43315 | PUSH DE | |||||||||||
| 43316 | JP (HL) | Jump to the check routine held in HL. | ||||||||||
|
The check returns here with its result in A and the carry flag.
|
||||||||||||
| ParserSucceeds_Return | 43317 | POP IX | Restore the script pointer from the stack. | |||||||||
| 43319 | LD (43014),A | Store the check's result at ScriptParserResult. | ||||||||||
| 43322 | JR C,ParserSucceeds_Failed | Jump to ParserSucceeds_Failed if the check failed (carry set). | ||||||||||
| 43324 | XOR A | Clear A and set the zero flag; the parser check passed. | ||||||||||
| 43325 | JP RunScript_SkipCondition_TwoBytes | Jump to RunScript_SkipCondition_TwoBytes. | ||||||||||
|
The check failed, so force the condition to fail.
|
||||||||||||
| ParserSucceeds_Failed | 43328 | XOR A | Clear A ready for RunScript_InvertConditionResult. | |||||||||
| 43329 | CALL RunScript_InvertConditionResult | Call RunScript_InvertConditionResult so the condition fails when the check failed. | ||||||||||
| 43332 | JP RunScript_SkipCondition_TwoBytes | Jump to RunScript_SkipCondition_TwoBytes. | ||||||||||
| Prev: 43277 | Up: Map | Next: 43335 |