Extended Keyboard Handler

0
0
Published 2024-08-06


Perhaps this is going to be useful for someone. This is a little keyboard handler I'm using in my code. It extends the functionality of the standard btn(k) function with detection of the onset of the key and its release. Sometimes it's useful to have those two and avoid btnp(k) repetition.

You need to call these in your _init() and _update() functions: