diff options
-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: |