Prev: D5C9 Up: Map Next: D5EF
D5D3: Print Object Attribute Description
Input
IX Object pointer
PrintObjectAttributeDescription D5D3 LD HL,$D5C9 HL=Table_ObjectAttributeDescriptionTokens (load the address of the object attribute description text token table).
Extract the attribute type from the object data.
D5D6 LD A,(IX+$04) A=*IX+04 (load the object attribute byte).
D5D9 AND %00000111 Keep only bits 0-2 (extract the attribute type value, 0-7).
D5DB CP $05 Compare the attribute type with 05.
D5DD PUSH AF Stash the comparison result on the stack.
D5DE DEC A Decrease A by one (convert to 0-based index for the table).
D5DF LD E,A Set DE to the index value (E=A, D=00).
D5E0 LD D,$00
D5E2 ADD HL,DE Add the index to the table base address twice (multiply by 02 for 2-byte word entries).
D5E3 ADD HL,DE
D5E4 CALL ExtractTokenFromText Call ExtractTokenFromText to print the text token from the table.
D5E7 POP AF Restore the comparison result from the stack.
D5E8 RET NZ Return if the attribute type was not 05 (original value was not 06).
Print an additional text token for attribute type 06.
D5E9 LD DE,$08DB DE="TO".
D5EC JP PrintTextToken Jump to PrintTextToken to print the text token.
Prev: D5C9 Up: Map Next: D5EF