]> git.jsancho.org Git - lugaru.git/commit
Console: Return gracefully when loading missing level
authorRémi Verschelde <rverschelde@gmail.com>
Wed, 4 Jan 2017 17:28:04 +0000 (18:28 +0100)
committerRémi Verschelde <rverschelde@gmail.com>
Wed, 4 Jan 2017 17:39:47 +0000 (18:39 +0100)
commiteae73ddd7a006ee6de9ffb01f3ec5f8e5fdc6d85
treedc1123f7ab7b5ea4cdb47e60fe85ae6a9326c149
parenta3f060d7e5508cd032c4f1c320033a74e5d84009
Console: Return gracefully when loading missing level

For this, implemented Folders::file_exists to check for the existence
of a given file, so that we can exit gracefully before raising a FileNotFound
exception which then closes the game.

The console and stderr both display an error message.
Part of #23.
Source/Devtools/ConsoleCmds.cpp
Source/Game.hpp
Source/GameTick.cpp
Source/Menu/Menu.cpp
Source/Utils/Folders.cpp
Source/Utils/Folders.hpp