diff --git a/engines/sci/detection.cpp b/engines/sci/detection.cpp index 80da7b13756..e26e514b02e 100644 --- a/engines/sci/detection.cpp +++ b/engines/sci/detection.cpp @@ -513,7 +513,7 @@ const ADGameDescription *SciMetaEngine::fallbackDetect(const Common::FSList &fsl ResourceManager *resMan = new ResourceManager(); assert(resMan); resMan->addAppropriateSources(fslist); - resMan->init(); + resMan->init(true); // TODO: Add error handling. #ifndef ENABLE_SCI32 diff --git a/engines/sci/resource.cpp b/engines/sci/resource.cpp index 703dc477602..f08c72a8330 100644 --- a/engines/sci/resource.cpp +++ b/engines/sci/resource.cpp @@ -813,7 +813,7 @@ void ResourceManager::freeResourceSources() { ResourceManager::ResourceManager() { } -void ResourceManager::init() { +void ResourceManager::init(bool initFromFallbackDetector) { _memoryLocked = 0; _memoryLRU = 0; _LRU.clear(); @@ -845,12 +845,12 @@ void ResourceManager::init() { scanNewSources(); - if (!addInternalSources()) { - error("Somehow I can't seem to find the sound files I need (RESOURCE.AUD/RESOURCE.SFX), aborting"); - return; - } + if (!initFromFallbackDetector) { + if (!addInternalSources()) + error("Somehow I can't seem to find the sound files I need (RESOURCE.AUD/RESOURCE.SFX), aborting"); - scanNewSources(); + scanNewSources(); + } detectSciVersion(); diff --git a/engines/sci/resource.h b/engines/sci/resource.h index f46f26620dc..d9b162df313 100644 --- a/engines/sci/resource.h +++ b/engines/sci/resource.h @@ -273,7 +273,7 @@ public: /** * Initializes the resource manager. */ - void init(); + void init(bool initFromFallbackDetector = false); int addAppropriateSources(); int addAppropriateSources(const Common::FSList &fslist); // TODO: Switch from FSList to Common::Archive?