Try putting the change code in love.keyreleased()
Something like this in main.lua
local changeMenu =false
function love.draw()
if changeMenu then
-- do what you need to do
changeMenu = false
end
end
function love.keyreleased(key)
if key=="return" or key=="kpenter" then
changeMenu = true
end
end