Prev: 35629 Up: Map Next: 35709
35669: Set the throw-enabled flag if carrying a throwable object
Used by the routine at 35495.
35669 LD A,(65532) Reset throw-enabled flag (i.e. false)...
35672 RES 4,A ...
35674 LD (65532),A ...
35677 LD B,5 Set counter to 5 (as Magic Knight can carry 5 objects)
35679 LD IX,25395 Point IX to start of Magic Knight's current inventory
35683 LD A,(IX+0) Load index of object carried by Magic Knight into A
35686 LD E,4 Point HL to property 4 ("use status") of this object (in table at 42242)...
35688 CALL 34160 ...
35691 BIT 1,(HL) ...and if can-be-thrown flag is set...
35693 JR NZ,35700 ...then skip to 35700...
35695 INC IX ...else advance to next inventory slot...
35697 DJNZ 35683 ...and repeat
35699 RET If this was last slot, then return with throw-enabled flag unset
35700 LD A,(65532) Set throw-enabled flag (i.e. true)...
35703 SET 4,A ...
35705 LD (65532),A ...
35708 RET Return
Prev: 35629 Up: Map Next: 35709