Prev: 53199 Up: Map Next: 53286
53256: Get Script Pointer From Timetable
Used by the routines at ScriptInterpreter and GetScriptPointer.
Takes the script address from the timetable, or from the matching entry when one exists.
GetScriptPointerFromTimetable 53256 LD L,(IY+4) Call FindCharacterScriptEntry to find character script entry.
53259 LD H,(IY+5)
53262 CALL FindCharacterScriptEntry
53265 LD A,(IY+3) Load the byte at IY+3 and jump to GetScriptPointerFromTimetable_Next if FindCharacterScriptEntry found no script entry.
53268 JR Z,GetScriptPointerFromTimetable_Next
53270 LD L,(IX+3) Read the action flags.
53273 LD H,(IX+4)
53276 LD A,(IX+6) Read the room at IX+6.
GetScriptPointerFromTimetable_Next 53279 LD (40918),A Record the current room.
53282 LD (40919),HL Record the location value.
53285 RET Return.
Prev: 53199 Up: Map Next: 53286