Re: LZ: Getkey
[Prev][Next][Index][Thread]
becker wrote:
>
> I tried to find info about this but was unsuccessful, so I figured you
> guys could help me. I found out the hard way that GetKey doesn't work
> for a continuous keypress(or so I think). Anyway, how do I detect a
> continuous keypress? (perhaps using in, out and bit commands? I thought
> I saw that somewhere)
> I'm not on the list so please send me answers direct.
>
> -Chris
Just read from (KEY_1), like this:
ld a,(KEY_1)
That's the key pressed down NOW. (KEY_0) and (LAST_KEY) gets the last key
pressed. Be aware though that if you exit the program with the EXIT button
this way, you will also exit ZShell because you haven't cleaned the key
buffer (if you can call it that). Just type
call GET_KEY
before returning to zshell though and that'll be fixed.
<pre>
--
Real name: Jimmy Mårdell
Email....: mailto:mja@algonet.se
IRC-name.: Yarin
WWW......: http://www.algonet.se/~mja
"Strap me down with disillusion
Tie me up in lifelines
Nothing stops my thoughts from breeding
Nothing's stopping my mind" - Leather Strip
</pre>
References: