aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra
diff options
context:
space:
mode:
authorJohannes Schickel2007-05-08 11:46:27 +0000
committerJohannes Schickel2007-05-08 11:46:27 +0000
commit2103678d93358bb13615c07f2a75238a8bbaa813 (patch)
tree9b8481664e18db525be89b913437614b1096cd2e /engines/kyra
parentf21a7648aafb3f94b88273f0a4ef8bf9f4d904f6 (diff)
downloadscummvm-rg350-2103678d93358bb13615c07f2a75238a8bbaa813.tar.gz
scummvm-rg350-2103678d93358bb13615c07f2a75238a8bbaa813.tar.bz2
scummvm-rg350-2103678d93358bb13615c07f2a75238a8bbaa813.zip
Fixed WSA playing regression, introduced while cleaning up. (should fix Floppy and Amiga version)
svn-id: r26786
Diffstat (limited to 'engines/kyra')
-rw-r--r--engines/kyra/wsamovie.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/engines/kyra/wsamovie.cpp b/engines/kyra/wsamovie.cpp
index 40023f169c..b2b43b86aa 100644
--- a/engines/kyra/wsamovie.cpp
+++ b/engines/kyra/wsamovie.cpp
@@ -50,8 +50,10 @@ int WSAMovieV1::open(const char *filename, int offscreenDecode, uint8 *palBuf) {
_deltaBufferSize = READ_LE_UINT16(wsaData); wsaData += 2;
_offscreenBuffer = NULL;
_flags = 0;
- if (_vm->gameFlags().useAltShapeHeader)
- flags = READ_LE_UINT16(wsaData); wsaData += 2;
+ if (_vm->gameFlags().useAltShapeHeader) {
+ flags = READ_LE_UINT16(wsaData);
+ wsaData += 2;
+ }
uint32 offsPal = 0;
if (flags & 1) {
@@ -86,11 +88,13 @@ int WSAMovieV1::open(const char *filename, int offscreenDecode, uint8 *palBuf) {
_frameOffsTable[0] = 0;
uint32 frameDataOffs = READ_LE_UINT32(wsaData); wsaData += 4;
bool firstFrame = true;
+
if (frameDataOffs == 0) {
firstFrame = false;
frameDataOffs = READ_LE_UINT32(wsaData);
_flags |= WF_NO_FIRST_FRAME;
}
+
for (int i = 1; i < _numFrames + 2; ++i) {
_frameOffsTable[i] = READ_LE_UINT32(wsaData) - frameDataOffs;
wsaData += 4;