diff options
author | Filippos Karapetis | 2011-01-30 21:00:23 +0000 |
---|---|---|
committer | Filippos Karapetis | 2011-01-30 21:00:23 +0000 |
commit | b7362876dd72ba5889cb5c6e12e1ff4e6e8f9c28 (patch) | |
tree | 4db6475284d6ba8a63048eed672547399ab6a6e7 /engines | |
parent | d4e1260b7e8363fba9e920ba2f3e301a26b86239 (diff) | |
download | scummvm-rg350-b7362876dd72ba5889cb5c6e12e1ff4e6e8f9c28.tar.gz scummvm-rg350-b7362876dd72ba5889cb5c6e12e1ff4e6e8f9c28.tar.bz2 scummvm-rg350-b7362876dd72ba5889cb5c6e12e1ff4e6e8f9c28.zip |
SWORD25: Disabled the video save/load code, and made it error out instead.
Videos are never saved or loaded, thus when this happens, it probably indicates a game bug
or a corrupted saved game
svn-id: r55667
Diffstat (limited to 'engines')
-rw-r--r-- | engines/sword25/gfx/dynamicbitmap.cpp | 10 | ||||
-rw-r--r-- | engines/sword25/gfx/renderobject.cpp | 4 |
2 files changed, 13 insertions, 1 deletions
diff --git a/engines/sword25/gfx/dynamicbitmap.cpp b/engines/sword25/gfx/dynamicbitmap.cpp index 49dacc069e..46c2af55d7 100644 --- a/engines/sword25/gfx/dynamicbitmap.cpp +++ b/engines/sword25/gfx/dynamicbitmap.cpp @@ -133,6 +133,7 @@ bool DynamicBitmap::isSetContentAllowed() const { } bool DynamicBitmap::persist(OutputPersistenceBlock &writer) { +#if 0 bool result = true; result &= Bitmap::persist(writer); @@ -144,9 +145,15 @@ bool DynamicBitmap::persist(OutputPersistenceBlock &writer) { result &= RenderObject::persistChildren(writer); return result; +#endif + + error("Request to persist a dynamic bitmap (video) - probably a bug"); + + return true; } bool DynamicBitmap::unpersist(InputPersistenceBlock &reader) { +#if 0 bool result = true; result &= Bitmap::unpersist(reader); @@ -162,6 +169,9 @@ bool DynamicBitmap::unpersist(InputPersistenceBlock &reader) { result &= RenderObject::unpersistChildren(reader); return reader.isGood() && result; +#endif + + error("Request to unpersist a dynamic bitmap (video) - probably a corrupted saved game or a bug"); } } // End of namespace Sword25 diff --git a/engines/sword25/gfx/renderobject.cpp b/engines/sword25/gfx/renderobject.cpp index 4b9555731d..b044d906f3 100644 --- a/engines/sword25/gfx/renderobject.cpp +++ b/engines/sword25/gfx/renderobject.cpp @@ -486,7 +486,9 @@ RenderObjectPtr<RenderObject> RenderObject::recreatePersistedRenderObject(InputP break; case TYPE_DYNAMICBITMAP: - result = (new DynamicBitmap(reader, this->getHandle(), handle))->getHandle(); + // Videos are not normally saved: this probably indicates a bug, thus die here. + //result = (new DynamicBitmap(reader, this->getHandle(), handle))->getHandle(); + error("Request to recreate a video. This is either a corrupted saved game, or a bug"); break; case TYPE_TEXT: |