love.keypressed(key) resets when using love.window.setMode inside

Issue #834 invalid
Felix Eklöf
created an issue

When you have a code like the follwoing:

function love.keypressed(key)
if key == "q" then
    love.window.setMode(0, 0, {fullscreen=true})
    love.window.setMode(,, {fullscreen=true})

The code inside the if statement should only runned once if you hold the specified key down, but if you have a code that changes resolution inside the if statement it "resets" and you can hold the key down and the code will run over and over again.

Comments (4)

  1. Log in to comment