aboutsummaryrefslogtreecommitdiff
path: root/engines/sci
diff options
context:
space:
mode:
authorFilippos Karapetis2016-08-23 11:19:53 +0300
committerFilippos Karapetis2016-08-23 11:36:37 +0300
commitcd00132d230ebf9bf51d3d111ca889fe382e2ddb (patch)
treed8cc935a50346abf5628486938d8befdee525bbd /engines/sci
parentf8483d2dabc080857e71aa135b4e5ba1b0c5f181 (diff)
downloadscummvm-rg350-cd00132d230ebf9bf51d3d111ca889fe382e2ddb.tar.gz
scummvm-rg350-cd00132d230ebf9bf51d3d111ca889fe382e2ddb.tar.bz2
scummvm-rg350-cd00132d230ebf9bf51d3d111ca889fe382e2ddb.zip
SCI32: Also handle game checks for "torinsg.cat" in Torin
This shows the "Open..." button when continuing a game
Diffstat (limited to 'engines/sci')
-rw-r--r--engines/sci/engine/kfile.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/engines/sci/engine/kfile.cpp b/engines/sci/engine/kfile.cpp
index a3a97eb7ee..e5b0aaf47a 100644
--- a/engines/sci/engine/kfile.cpp
+++ b/engines/sci/engine/kfile.cpp
@@ -257,11 +257,14 @@ reg_t kFileIOOpen(EngineState *s, int argc, reg_t *argv) {
// by opening it. Since we don't use .cat files, we instead check
// for autosave.000 or autosave.001.
//
+ // The same logic is being followed for torinsg.cat - this shows
+ // the "Open..." button when continuing a game.
+ //
// This has the added benefit of not detecting an SSCI autosave.cat
// accompanying SSCI autosave files that we wouldn't be able to load.
- if (g_sci->getGameId() == GID_TORIN && name == "autosave.cat") {
- Common::String pattern = g_sci->wrapFilename("autosave.###");
+ if (g_sci->getGameId() == GID_TORIN && (name == "autosave.cat" || name == "torinsg.cat")) {
Common::SaveFileManager *saveFileMan = g_sci->getSaveFileManager();
+ const Common::String pattern = (name == "autosave.cat") ? g_sci->wrapFilename("autosave.###") : g_sci->getSavegamePattern();
bool exists = !saveFileMan->listSavefiles(pattern).empty();
if (exists) {
// Dummy handle. Torin only checks if this is SIGNAL_REG,