Prev: 9358 Up: Map Next: 9398
938B: Read Pickup Key
Used by the routine at DrawRoom.
Reads the key to pick up an item, which is CAPS SHIFT or SPACE, and Z or SYMBOL SHIFT. The result is stored in PickupPressed.
ReadPickupKey 938B LD A,$7E Read from the keyboard;
Port Number Bit
0 1 2 3 4
7E CAPS SHIFT / SPACE Z / SYMBOL SHIFT X / M C / N V / B
938D OUT ($FD),A
938F IN A,($FE)
9391 CPL Flip the bits, so that a set bit is a key which is pressed.
9392 AND %00000010 Keep only bit 1.
9394 LD ($5E20),A Update the pickup pressed flag in PickupPressed.
9397 RET Return.
Prev: 9358 Up: Map Next: 9398