diff options
author | athrxx | 2019-03-25 23:13:57 +0100 |
---|---|---|
committer | athrxx | 2019-04-13 18:54:59 +0200 |
commit | 82b288a5107e9f15ed2d25dac017e54e915323b8 (patch) | |
tree | b60fc820110a5a9cd3c871fadf223bf9f9a195e6 /engines/kyra/engine/scene_eob.cpp | |
parent | 5462d42363bf6f0e84aa0ecbb12b0dc8941acadb (diff) | |
download | scummvm-rg350-82b288a5107e9f15ed2d25dac017e54e915323b8.tar.gz scummvm-rg350-82b288a5107e9f15ed2d25dac017e54e915323b8.tar.bz2 scummvm-rg350-82b288a5107e9f15ed2d25dac017e54e915323b8.zip |
KYRA: (EOB2/Amiga) - fix vcn block drawing
Diffstat (limited to 'engines/kyra/engine/scene_eob.cpp')
-rw-r--r-- | engines/kyra/engine/scene_eob.cpp | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/engines/kyra/engine/scene_eob.cpp b/engines/kyra/engine/scene_eob.cpp index 80d3e7d99e..f47e0d2a0d 100644 --- a/engines/kyra/engine/scene_eob.cpp +++ b/engines/kyra/engine/scene_eob.cpp @@ -159,8 +159,13 @@ Common::String EoBCoreEngine::initLevelData(int sub) { uint16 size = (_flags.platform == Common::kPlatformFMTowns) ? 2916 : s->readUint16(); delete[] _vmpPtr; _vmpPtr = new uint16[size]; - for (int i = 0; i < size; i++) - _vmpPtr[i] = s->readUint16(); + if (_flags.gameID == GI_EOB1) { + for (int i = 0; i < size; i++) + _vmpPtr[i] = s->readUint16(); + } else { + for (int i = 0; i < size; i++) + _vmpPtr[i] = s->readUint16LE(); + } delete s; const char *paletteFilePattern = (_flags.gameID == GI_EOB2 && _configRenderMode == Common::kRenderEGA) ? "%s.EGA" : "%s.PAL"; @@ -315,7 +320,7 @@ void EoBCoreEngine::loadVcnData(const char *file, const uint8 *cgaMapping) { const char *filePattern = ((_flags.gameID == GI_EOB1 && (_configRenderMode == Common::kRenderEGA || _configRenderMode == Common::kRenderCGA)) ? "%s.ECN" : "%s.VCN"); Common::String fn = Common::String::format(filePattern, _lastBlockDataFile); - if (_flags.platform == Common::kPlatformAmiga) { + if (_flags.gameID == GI_EOB1 && _flags.platform == Common::kPlatformAmiga) { Common::SeekableReadStream *in = _res->createReadStream(fn); vcnSize = in->readUint16LE() * (_vcnSrcBitsPerPixel << 3); _vcnBlocks = new uint8[vcnSize]; |