diff options
author | Filippos Karapetis | 2014-12-22 02:58:18 +0200 |
---|---|---|
committer | Filippos Karapetis | 2014-12-22 02:58:18 +0200 |
commit | b51852c641cf4d558d035d7d1dd9309d6d238647 (patch) | |
tree | c45ac738c5eaca287bc51f567be1c4d710f176d0 /engines | |
parent | f364756bcfa952e85c2111270ffda15c9809a4b8 (diff) | |
download | scummvm-rg350-b51852c641cf4d558d035d7d1dd9309d6d238647.tar.gz scummvm-rg350-b51852c641cf4d558d035d7d1dd9309d6d238647.tar.bz2 scummvm-rg350-b51852c641cf4d558d035d7d1dd9309d6d238647.zip |
ZVISION: Error out when the game string file isn't found
Diffstat (limited to 'engines')
-rw-r--r-- | engines/zvision/text/string_manager.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/engines/zvision/text/string_manager.cpp b/engines/zvision/text/string_manager.cpp index ec10b6220c..6b870d0b8d 100644 --- a/engines/zvision/text/string_manager.cpp +++ b/engines/zvision/text/string_manager.cpp @@ -43,21 +43,18 @@ StringManager::~StringManager() { } void StringManager::initialize(ZVisionGameId gameId) { - if (gameId == GID_NEMESIS) { - // TODO: Check this hardcoded filename against all versions of Nemesis + if (gameId == GID_NEMESIS) loadStrFile("nemesis.str"); - } else if (gameId == GID_GRANDINQUISITOR) { - // TODO: Check this hardcoded filename against all versions of Grand Inquisitor + else if (gameId == GID_GRANDINQUISITOR) loadStrFile("inquis.str"); - } } void StringManager::loadStrFile(const Common::String &fileName) { Common::File file; if (!_engine->getSearchManager()->openFile(file, fileName)) { - warning("%s does not exist. String parsing failed", fileName.c_str()); - return; + error("%s does not exist. String parsing failed", fileName.c_str()); } + uint lineNumber = 0; while (!file.eos()) { _lines[lineNumber] = readWideLine(file); |