aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/tinsel/sound.cpp18
-rw-r--r--engines/tinsel/strres.cpp10
2 files changed, 25 insertions, 3 deletions
diff --git a/engines/tinsel/sound.cpp b/engines/tinsel/sound.cpp
index fef9a0f858..3a03fea6ef 100644
--- a/engines/tinsel/sound.cpp
+++ b/engines/tinsel/sound.cpp
@@ -41,6 +41,8 @@
#include "sound/mixer.h"
#include "sound/adpcm.h"
+#include "gui/message.h"
+
namespace Tinsel {
extern LANGUAGE sampleLanguage;
@@ -439,12 +441,24 @@ void SoundManager::openSampleFiles(void) {
// convert file size to size in DWORDs
_sampleIndexLen /= sizeof(uint32);
- } else
+ } else {
+ char buf[50];
+ sprintf(buf, CANNOT_FIND_FILE, _vm->getSampleIndex(sampleLanguage));
+ GUI::MessageDialog dialog(buf, "OK");
+ dialog.runModal();
+
error(CANNOT_FIND_FILE, _vm->getSampleIndex(sampleLanguage));
+ }
// open sample file in binary mode
- if (!_sampleStream.open(_vm->getSampleFile(sampleLanguage)))
+ if (!_sampleStream.open(_vm->getSampleFile(sampleLanguage))) {
+ char buf[50];
+ sprintf(buf, CANNOT_FIND_FILE, _vm->getSampleFile(sampleLanguage));
+ GUI::MessageDialog dialog(buf, "OK");
+ dialog.runModal();
+
error(CANNOT_FIND_FILE, _vm->getSampleFile(sampleLanguage));
+ }
/*
// gen length of the largest sample
diff --git a/engines/tinsel/strres.cpp b/engines/tinsel/strres.cpp
index 2d963ae8bb..60ac8cdb2a 100644
--- a/engines/tinsel/strres.cpp
+++ b/engines/tinsel/strres.cpp
@@ -30,6 +30,8 @@
#include "common/file.h"
#include "common/endian.h"
+#include "gui/message.h"
+
namespace Tinsel {
#ifdef DEBUG
@@ -94,8 +96,14 @@ void ChangeLanguage(LANGUAGE newLang) {
// isn't English, try falling back on opening 'english.txt' - some foreign
// language versions reused it rather than their proper filename
if (!f.open(_vm->getTextFile(newLang))) {
- if ((newLang == TXT_ENGLISH) || !f.open(_vm->getTextFile(TXT_ENGLISH)))
+ if ((newLang == TXT_ENGLISH) || !f.open(_vm->getTextFile(TXT_ENGLISH))) {
+ char buf[50];
+ sprintf(buf, CANNOT_FIND_FILE, _vm->getTextFile(newLang));
+ GUI::MessageDialog dialog(buf, "OK");
+ dialog.runModal();
+
error(CANNOT_FIND_FILE, _vm->getTextFile(newLang));
+ }
}
// Check whether the file is compressed or not - for compressed files the