From f0892cdcbef2dff7a9f072d2bb7df42aa3d44a14 Mon Sep 17 00:00:00 2001 From: Filippos Karapetis Date: Sat, 11 Jul 2009 19:00:56 +0000 Subject: Some work on QFG1VGA (looks like a mix of SCI1 and SCI1.1) svn-id: r42393 --- engines/sci/gfx/gfx_resmgr.cpp | 5 +++++ engines/sci/resource.cpp | 10 ++++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) (limited to 'engines/sci') diff --git a/engines/sci/gfx/gfx_resmgr.cpp b/engines/sci/gfx/gfx_resmgr.cpp index f4c5fdf0dd..4a3c79feef 100644 --- a/engines/sci/gfx/gfx_resmgr.cpp +++ b/engines/sci/gfx/gfx_resmgr.cpp @@ -57,6 +57,11 @@ GfxResManager::GfxResManager(gfx_options_t *options, GfxDriver *driver, Resource _portBounds = Common::Rect(0, 10, 320, 200); // default value, with a titlebar of 10px _version = resManager->_volVersion; + // Workaround for QFG1 VGA (has SCI 1.1 view data with SCI 1 compression) + if (_version == SCI_VERSION_1 && !strcmp(((SciEngine*)g_engine)->getGameID(), "qfg1")) { + _version = SCI_VERSION_1_1; + } + if (!_resManager->isVGA()) { _staticPalette = gfx_sci0_pic_colors->getref(); } else if (_version == SCI_VERSION_1_1) { diff --git a/engines/sci/resource.cpp b/engines/sci/resource.cpp index b425c23876..d99f9f0771 100644 --- a/engines/sci/resource.cpp +++ b/engines/sci/resource.cpp @@ -537,6 +537,12 @@ ResourceManager::ResourceManager(int version, int maxMemory) { } } + // Workaround for QFG1 VGA (has SCI 1.1 view data with SCI 1 compression) + if (version == SCI_VERSION_1 && !strcmp(((SciEngine*)g_engine)->getGameID(), "qfg1")) { + debug("Resmgr: Detected QFG1 VGA"); + _isVGA = true; + } + _sciVersion = version; // temporary version printout - should be reworked later switch (_sciVersion) { @@ -721,7 +727,7 @@ int ResourceManager::detectMapVersion() { } } if (file.isOpen() == false) { - warning("Failed to open resource map file"); + error("Failed to open resource map file"); return SCI_VERSION_AUTODETECT; } // detection @@ -801,7 +807,7 @@ int ResourceManager::detectVolVersion() { } } if (file.isOpen() == false) { - warning("Failed to open volume file"); + error("Failed to open volume file"); return SCI_VERSION_AUTODETECT; } // SCI0 volume format: {wResId wPacked+4 wUnpacked wCompression} = 8 bytes -- cgit v1.2.3