diff options
author | Littleboy | 2012-08-01 02:58:55 -0400 |
---|---|---|
committer | Littleboy | 2012-08-01 02:58:55 -0400 |
commit | 7f05e1413c8b7b3913f64ddb29622dcdf40b2c65 (patch) | |
tree | 78d3c5997a58d8eb126ea1a612eb82fc8b1a3919 /engines/lastexpress/entities/entity.cpp | |
parent | eb6c60cec034a7758b8d25e29f501b10fc06c1a4 (diff) | |
download | scummvm-rg350-7f05e1413c8b7b3913f64ddb29622dcdf40b2c65.tar.gz scummvm-rg350-7f05e1413c8b7b3913f64ddb29622dcdf40b2c65.tar.bz2 scummvm-rg350-7f05e1413c8b7b3913f64ddb29622dcdf40b2c65.zip |
LASTEXPRESS: Remove use of skip from savegame functions when loading
We cannot accurately skip over compressed data as it is not know before decoding how much data will be used
Diffstat (limited to 'engines/lastexpress/entities/entity.cpp')
-rw-r--r-- | engines/lastexpress/entities/entity.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/engines/lastexpress/entities/entity.cpp b/engines/lastexpress/entities/entity.cpp index 4b1fda9c12..2deca291f6 100644 --- a/engines/lastexpress/entities/entity.cpp +++ b/engines/lastexpress/entities/entity.cpp @@ -88,7 +88,13 @@ void EntityData::EntityCallData::saveLoadWithSerializer(Common::Serializer &s) { syncString(s, sequenceNameCopy, 13); // Skip pointers to frame & sequences - s.skip(5 * 4); + // (we are using a compressed stream, so we cannot seek on load) + if (s.isLoading()) { + byte empty[5 * 4]; + s.syncBytes(empty, 5 * 4); + } else { + s.skip(5 * 4); + } } ////////////////////////////////////////////////////////////////////////// |