aboutsummaryrefslogtreecommitdiff
path: root/engines/gob/game.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/gob/game.cpp')
-rw-r--r--engines/gob/game.cpp33
1 files changed, 27 insertions, 6 deletions
diff --git a/engines/gob/game.cpp b/engines/gob/game.cpp
index a5993fd1de..e47dc1809f 100644
--- a/engines/gob/game.cpp
+++ b/engines/gob/game.cpp
@@ -672,18 +672,39 @@ byte *Game::loadLocTexts(int32 *dataSize) {
handle = openLocTextFile(locTextFile, _vm->_global->_languageWanted);
if (handle >= 0) {
+
_foundTotLoc = true;
_vm->_global->_language = _vm->_global->_languageWanted;
- }
- else if (!_foundTotLoc) {
- for (i = 0; i < 10; i++) {
- handle = openLocTextFile(locTextFile, i);
+
+ } else if (!_foundTotLoc) {
+ bool found = false;
+
+ if (_vm->_global->_languageWanted == 2) {
+ handle = openLocTextFile(locTextFile, 5);
+ if (handle >= 0) {
+ _vm->_global->_language = 5;
+ found = true;
+ }
+ } else if (_vm->_global->_languageWanted == 5) {
+ handle = openLocTextFile(locTextFile, 2);
if (handle >= 0) {
- _vm->_global->_language = i;
- break;
+ _vm->_global->_language = 2;
+ found = true;
}
}
+
+ if (!found) {
+ for (i = 0; i < 10; i++) {
+ handle = openLocTextFile(locTextFile, i);
+ if (handle >= 0) {
+ _vm->_global->_language = i;
+ break;
+ }
+ }
+ }
+
}
+
debugC(1, kDebugFileIO, "Using language %d for %s",
_vm->_global->_language, _curTotFile);