Unofficial Name: RunCatalog1Hook
BCALL Address: 505C
Checks the first byte of the block for the Catalog 1 Hook. If the byte is 83, the hook is run; otherwise, the active flag for the hook is set to zero.
- Register values to pass to the catalog 1 hook.
- If the hook is invalid, it is disabled, and all registers are preserved except F.
- In this case, the zero flag is cleared if A = 0Ch, set otherwise.
- If the hook is valid, it is called, and all register values upon exiting the hook are preserved and returned.
- As with all hooks, you must assume everything in RAM may be destroyed, but remember that any side effects are intentional.
This routine does not check that the hook is enabled. You must test this yourself, e.g.
bit catalog1HookActive,(iy+catalog1HookFlag) jr z,SkipHook B_CALL _Catalog1Hook SkipHook:
Credits and Contributions
- Michael Cimino