Prev: 51398 Up: Map Next: 51497
51439: Set Object Pointers
Chooses a room record or an object record from the picture parameter.
SetObjectPointers 51439 LD A,(41012) Jump to SetObjectPointers_RoomGraphicsParameter if the room display parameter is at least 254.
51442 CP 254
51444 JR NC,SetObjectPointers_RoomGraphicsParameter
51446 LD A,(40975) Compare *DisplayMode with 5.
51449 CP 5
51451 LD A,(41012) Read the room display parameter and jump ahead to SetObjectPointers_Next if the display mode is at least 5.
51454 JR NC,SetObjectPointers_Next
51456 CALL FetchLocationDataPointer Call FetchLocationDataPointer to look up this room.
51459 JR SetObjectPointers_RememberRoomRecord
Record the character record in the current object, then read the room graphics parameter, then check for the other end marker, and return if it reaches the limit.
SetObjectPointers_Next 51461 CALL FetchObjectDataPointer Call FetchObjectDataPointer to look that object up.
SetObjectPointers_RememberRoomRecord 51464 LD (40979),IX Remember the room record and read the room graphics parameter.
SetObjectPointers_RoomGraphicsParameter 51468 LD A,(41013) Return if the room graphics parameter is at least 254.
51471 CP 254
51473 RET NC
51474 LD A,(40976) Compare *40976 with 5.
51477 CP 5
51479 LD A,(41013) Load the room graphics parameter at RoomGraphicsParameter and jump to SetObjectPointers_LookObjectBefore if the display mode is at least 5.
51482 JR NC,SetObjectPointers_LookObjectBefore
51484 CALL FetchLocationDataPointer Call FetchLocationDataPointer to look up this room.
51487 JR SetObjectPointers_0
Look the object up before returning.
SetObjectPointers_LookObjectBefore 51489 CALL FetchObjectDataPointer Call FetchObjectDataPointer to look up that object.
SetObjectPointers_0 51492 LD (40981),IX Remember this character record in the secondary pointer.
51496 RET Return.
Prev: 51398 Up: Map Next: 51497