Is it possible to detect the key pressed in Lua?

3

Working in terminal mode, I have control over the screen coordinates where the text will be displayed, however I need to detect if a key has been pressed , without it echoing > on the screen.

Is there a function or library that allows me to detect this?

    
asked by anonymous 29.10.2014 / 02:57

1 answer

2

Directly, promptly, as far as I know, no. It is possible to do this in C and expose to Moon access. In fact there are some libraries that have already done this. Example NTLua .

I found this another example but I do not know if it works as you wish.

Here is another attempt.

    
29.10.2014 / 03:14