Custom error handler
Posted: Tue Jul 28, 2015 7:48 pm
Is there any way to make a game not stop when there is an error?
What I want to do is to change the game's state inside love.errhand(), kinda like this:
The error state contains an update and a draw function that are called from love.update and love.draw and should restart the game on a keypress, so the solution i'm looking for should not stop love.run.
What I want to do is to change the game's state inside love.errhand(), kinda like this:
Code: Select all
function love.errhand(msg)
setState("error", {msg}) --the {msg} part sends msg to the new state
end