11-11-2022, 06:55 PM
I love _KEYCLEAR. Anyone who doesn't needs to be put in a paper bag... Well, you all know the drill!
In the QJurASCIIc Period, we had to code ways to clear the key buffer like: WHILE LEN(INKEY$): WEND
So many uses...
SLEEP will store a keystroke. Using _KEYCLEAR after it will get rid of it.
If a user holds down keys, but only one unique response needs to be registered, using _KEYCLEAR clears the rest of the duplicate entries out of the buffer.
Can be used to control the repeat rate as follows:
Anyway, very neat and handy tool for us SCREEN ZERO Heroes. No "Fire up the bag!" rating, here.
Thanks Magic 8-Ball,
Pete
In the QJurASCIIc Period, we had to code ways to clear the key buffer like: WHILE LEN(INKEY$): WEND
So many uses...
SLEEP will store a keystroke. Using _KEYCLEAR after it will get rid of it.
If a user holds down keys, but only one unique response needs to be registered, using _KEYCLEAR clears the rest of the duplicate entries out of the buffer.
Can be used to control the repeat rate as follows:
Code: (Select All)
DO
_LIMIT 120
b$ = INKEY$
IF LEN(b$) THEN
PRINT b$;
_DELAY .1
_KEYCLEAR ' Alternative 'WHILE LEN(INKEY$): WEND
END IF
LOOP
Anyway, very neat and handy tool for us SCREEN ZERO Heroes. No "Fire up the bag!" rating, here.
Thanks Magic 8-Ball,
Pete