![]()  | 
Routines | 
| Prev: 44109 | Up: Map | Next: 44164 | 
| 
 
Used by the routine at GameStart.
 
 | 
||||
| Parser_ProcessItem | 44128 | LD HL,41275 | HL=UserInput_Token_1. | |
| 44131 | LD B,10 | Set a counter of 10 in B of the maximum number of tokens available in the user input. | ||
| ProcessItem_Loop | 44133 | LD A,(HL) | Fetch a token byte from the user input pointer. | |
| 44134 | CP 255 | Return if the terminator has been reached (255). | ||
| 44136 | RET Z | |||
| 44137 | PUSH HL | Stash the user input token pointer and max count on the stack. | ||
| 44138 | PUSH BC | |||
| 44139 | LD HL,46238 | Load Table_TokenItemList into HL. | ||
| 44142 | LD BC,(48073) | Load *Count_Objects_2 into BC. | ||
| 44146 | CPIR | Search for matching objects. | ||
| 44148 | JR NZ,ProcessItem_Next | Jump to ProcessItem_Next the current token wasn't found in the table. | ||
| 44150 | CALL Parser_ValidateItem | Call Parser_ValidateItem. | ||
| 44153 | JR NC,ProcessItem_Next | Jump to ProcessItem_Next if the carry flag is not set. | ||
| 44155 | POP BC | Restore the max count and user input token pointer from the stack. | ||
| 44156 | POP HL | |||
| 44157 | RET | Return. | ||
| ProcessItem_Next | 44158 | POP BC | Restore the max count and user input token pointer from the stack. | |
| 44159 | POP HL | |||
| 44160 | INC HL | Increment the user input token pointer by one. | ||
| 44161 | DJNZ ProcessItem_Loop | Decrease the max count by one and loop back to ProcessItem_Loop until all of the user input tokens have been evaluated. | ||
| 44163 | RET | Return. | ||
| 
 
View the equivalent code in;  
  | 
||||
| Prev: 44109 | Up: Map | Next: 44164 |