What are you trying to do exactly?TheP3 wrote:I want to see what key is being pressed. Without having to check isDown("a" || "b"...). Does love have some kind of function for that? Thx
You can remember keys pressed/released in a table, and just check that table, like this:
Code: Select all
function love.load()
PRESSED={}
end
function love.draw()
local n=0
for k,v in pairs(PRESSED) do
love.graphics.print(k..'=>'..v, 0, n*15)
n=n+1
end
end
function love.keypressed(k, u)
PRESSED[k]=u
end
function love.keyreleased(k)
PRESSED[k]=nil
end