Routines
Prev:
D224
Up:
Map
Next:
D249
D237: Fetch Object Data Pointer
Used by the routines at
ActionMoveMrsJones
,
PlaceCharacterBesideMatch
,
SetObjectHeldMark
,
ClearObjectHeldMark
,
CharacterAction_BasilPhipps
,
CheckObjectInCharacterLocation
,
ReadSherlocksDisguise
,
PointToObjectAttributeByte
,
UseObjectDisplayLink
,
InspectActionTakenFlag
,
ReadObjectAttribute_LooksObjectFolds
,
CheckObjectLocationMatch
,
GetObjectLocation
,
CheckObjectMother
,
GetObjectAttribute
,
GetObjectMotherID
,
TestObjectHasSpecialDescription
,
ProcessObjectAttribute_LookObjectRun
,
SetObjectPointers
,
ReadCharacterTimetable
,
ProcessCharacterDisplay_TestDisplayFlagEnd
,
DescribeCurrentRoom
,
LookUpObjectAndTestMovedMarker
,
GetObjectFirstLocation
,
PrintObjectDescription
,
PrintLocationExits
,
StoreMatchedCharacterRoom
,
DescribeObjectIfPresent
,
PrintObjectDescriptionText
,
SpecialCaseObject_LooksBasilPhipps
,
PlaceCharacter
,
ReadSourceDisplayPointer
,
LookUpCurrentObject
,
ScanObjects
and
UpdateObjectLocation
.
Looks up an object in the objects table and returns a pointer to it's data structure.
Input
A
Object ID
Output
IX
Pointer to object data
FetchObjectDataPointer
D237
LD IX,$8B6F
Call
SearchThreeByteTable
to search three-byte length table.
D23B
CALL
SearchThreeByteTable
This will be restored back into
HL
by the end of the routine.
D23E
PUSH HL
Read the moved marker and read the location, saving pointer.
Pretty clever way of using the stack here.
D23F
LD L,(IX+$01)
D242
LD H,(IX+$02)
D245
EX (SP),HL
Swap the *
SP
with the object pointer, restoring
HL
to the original value.
D246
POP IX
Restore the saved character record from the stack.
D248
RET
Return.
View the equivalent code in;
The Hobbit
Prev:
D224
Up:
Map
Next:
D249