diff options
author | Strangerke | 2019-08-19 00:47:34 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2019-09-03 17:17:34 +0200 |
commit | 2178770898938b5b13e5ece25ea8f0b26e0c728c (patch) | |
tree | 0ccc0b00ab2170bfd9978f6d7604041f113ca9e2 /engines/hdb/hdb.cpp | |
parent | 23c7dc8ebd6f6443f476de010129bb01aff210b4 (diff) | |
download | scummvm-rg350-2178770898938b5b13e5ece25ea8f0b26e0c728c.tar.gz scummvm-rg350-2178770898938b5b13e5ece25ea8f0b26e0c728c.tar.bz2 scummvm-rg350-2178770898938b5b13e5ece25ea8f0b26e0c728c.zip |
HDB: Change init functions to handle errors
Diffstat (limited to 'engines/hdb/hdb.cpp')
-rw-r--r-- | engines/hdb/hdb.cpp | 28 |
1 files changed, 7 insertions, 21 deletions
diff --git a/engines/hdb/hdb.cpp b/engines/hdb/hdb.cpp index 488158152e..b1fbb6f5e7 100644 --- a/engines/hdb/hdb.cpp +++ b/engines/hdb/hdb.cpp @@ -137,28 +137,14 @@ bool HDBGame::init() { // Init fileMan - if (!_fileMan->openMPC(getGameFile())) { - error("FileMan::openMPC: Cannot find the %s data file", getGameFile()); - } - if (!_gfx->init()) { - error("Gfx::init: Couldn't initialize Gfx"); - } - if (!_sound->init()) { - error("Window::init: Couldn't initialize Sound"); - } - if (!_ai->init()) { - error("AI::init: Couldn't initialize AI"); - } - if (!_window->init()) { - error("Window::init: Couldn't initialize Window"); - } - if (!_input->init()) { - error("Input::init: Couldn't initialize Input"); - } - if (!_lua->init()) { - error("LuaScript::init: Couldn't load the GLOBAL.LUA code."); - } + _fileMan->openMPC(getGameFile()); + _gfx->init(); + _sound->init(); + _ai->init(); + _window->init(); + _input->init(); + _lua->init(); _menu->init(); _debugLogo = _gfx->loadIcon("icon_debug_logo"); |