Prev: 49941 Up: Map Next: 50015
49962: Action: Examine Item
Used by the routine at Parser_ProcessItem.
Input
C Item ID
Output
F Carry flag set when the item isn't present
Action_ExamineItem 49962 INC BC Increment BC by one.
49963 LD A,(48426) E=*Count_Objects-C.
49966 SUB C
49967 LD E,A
49968 PUSH DE Stash DE on the stack.
49969 LD IX,(48410) IX=*Pointer_ItemGroupingTable.
49973 CALL GetTableEntry Call GetTableEntry.
49976 POP DE Restore DE from the stack.
49977 JR ExamineItem Jump to ExamineItem.
ExamineItem_Loop 49979 INC HL Increment HL by one.
ExamineItem 49980 LD A,(HL) Jump to Response_ItemNotHere if *HL is equal to 255.
49981 CP 255
49983 JR Z,Response_ItemNotHere
49985 CALL ValidateItemPresent Call ValidateItemPresent.
49988 JR NZ,ExamineItem_Loop Jump to ExamineItem_Loop if the item wasn't found.
49990 RET Return.
The item being examined isn't in the room or in the players inventory.
Print "I can't see ".
Response_ItemNotHere 49991 LD HL,48669 HL=Messaging_ICantSee.
49994 CALL PrintString Call PrintString.
Print the object name.
49997 LD IX,(48412) IX=*Pointer_ObjectNounPhrases.
50001 CALL GetTableEntry Call GetTableEntry.
50004 CALL PrintString Call PrintString.
Print " here.".
50007 LD HL,48682 HL=Messaging_Here.
50010 CALL PrintStringAndNewline Call PrintStringAndNewline.
50013 SCF Set the carry flag.
50014 RET Return.
Prev: 49941 Up: Map Next: 50015