Prev: 5E00 Up: Map Next: 5F28
5EFE: Check for movement controls
Used by the routines at 663D, 69E3 and 6AC2.
5EFE LD HL,$5E25 Change this to modify what trees are drawn
5F01 LD IX,$66DF
5F05 LD A,($5DC9) Are we using joystick?
5F08 BIT 0,A
5F0A JR Z,$5F18 Jump forward if using keyboard
5F0C IN A,($1F) Read Kempston port
5F0E BIT 0,A Check for RIGHT
5F10 JR NZ,$5F28 Jump if moving right
5F12 BIT 1,A Check for LEFT
5F14 JR NZ,$5F47 Jump if moving left
5F16 JR $5F66 No movement - straighten up
5F18 LD A,$F7 Read 1 - 5
5F1A IN A,($FE)
5F1C BIT 0,A Was 1 pressed?
5F1E JR Z,$5F47 Jump if moving left
5F20 LD A,$EF Read 0 - 6
5F22 IN A,($FE)
5F24 BIT 0,A Was 0 pressed?
5F26 JR NZ,$5F66 Jump if not - straighten up
Prev: 5E00 Up: Map Next: 5F28