aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilippos Karapetis2008-09-16 08:10:08 +0000
committerFilippos Karapetis2008-09-16 08:10:08 +0000
commit4fced32082e8e990de30c91856fd430c49f29092 (patch)
tree687e36f6097d61206432002a966e354c737446f3
parentc655d72f5ae191211ca7a5f3a091c6530a67df46 (diff)
downloadscummvm-rg350-4fced32082e8e990de30c91856fd430c49f29092.tar.gz
scummvm-rg350-4fced32082e8e990de30c91856fd430c49f29092.tar.bz2
scummvm-rg350-4fced32082e8e990de30c91856fd430c49f29092.zip
Added a workaround to skip the silence in the beginning and end of file 3.als. Fixes bug #2111815 - "DRASCULA: Voice delayed"
svn-id: r34571
-rw-r--r--engines/drascula/sound.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/engines/drascula/sound.cpp b/engines/drascula/sound.cpp
index f490f1e25d..cacf725fa8 100644
--- a/engines/drascula/sound.cpp
+++ b/engines/drascula/sound.cpp
@@ -150,7 +150,18 @@ void DrasculaEngine::playFile(const char *fname) {
if (_arj.open(fname)) {
int soundSize = _arj.size();
byte *soundData = (byte *)malloc(soundSize);
- _arj.seek(32);
+
+ if (!(!strcmp(fname, "3.als") && soundSize == 145166 && _lang != kSpanish)) {
+ _arj.seek(32);
+ } else {
+ // WORKAROUND: File 3.als with English speech files has a big silence at
+ // its beginning and end. We seek past the silence at the beginning,
+ // and ignore the silence at the end
+ // Fixes bug #2111815 - "DRASCULA: Voice delayed"
+ _arj.seek(73959, SEEK_SET);
+ soundSize = 117158 - 73959;
+ }
+
_arj.read(soundData, soundSize);
_arj.close();