Prev: C4B7 Up: Map Next: C4EB
C4C7: Parser: Process Item
Used by the routine at GameLoop.
Parser_ProcessItem C4C7 LD HL,$BD66 HL=UserInput_Token_1.
C4CA LD B,$0A B=0A.
Parser_ProcessItem_0 C4CC LD A,(HL) Return if *HL is equal to FF.
C4CD CP $FF
C4CF RET Z
C4D0 PUSH HL Stash HL and BC on the stack.
C4D1 PUSH BC
C4D2 LD HL,($BD1E) HL=*Pointer_ObjectList.
C4D5 LD BC,($BD2A) BC=*Count_Objects.
C4D9 CPIR CPIR.
C4DB JR NZ,Parser_ProcessItem_1 Jump to Parser_ProcessItem_1 if A is not equal to FF.
C4DD CALL Action_ExamineItem Call Action_ExamineItem.
C4E0 JR NC,Parser_ProcessItem_1 Jump to Parser_ProcessItem_1 if A is greater than or equal to FF.
C4E2 POP BC Restore BC and HL from the stack.
C4E3 POP HL
C4E4 RET Return.
Parser_ProcessItem_1 C4E5 POP BC Restore BC and HL from the stack.
C4E6 POP HL
C4E7 INC HL Increment HL by one.
C4E8 DJNZ Parser_ProcessItem_0 Decrease counter by one and loop back to Parser_ProcessItem_0 until counter is zero.
C4EA RET Return.
Prev: C4B7 Up: Map Next: C4EB