From 15306581ab27c0ea9605b7d3909262b70226954c Mon Sep 17 00:00:00 2001 From: D G Turner Date: Wed, 17 Oct 2018 23:29:01 +0100 Subject: SHERLOCK: RT: Disable Loading from GMM During Prolog or Credits. Loading from the GMM during the prolog resulted in the mouse cursor getting stuck hidden and possibly other game state issues, so best to disable loading in these cases as already was done for saving. This fixes bug Trac #10746. --- engines/sherlock/tattoo/tattoo.cpp | 5 +++++ engines/sherlock/tattoo/tattoo.h | 5 +++++ 2 files changed, 10 insertions(+) (limited to 'engines/sherlock') diff --git a/engines/sherlock/tattoo/tattoo.cpp b/engines/sherlock/tattoo/tattoo.cpp index 38466a9459..a0f792dea9 100644 --- a/engines/sherlock/tattoo/tattoo.cpp +++ b/engines/sherlock/tattoo/tattoo.cpp @@ -204,6 +204,11 @@ void TattooEngine::saveConfig() { ConfMan.flushToDisk(); } +bool TattooEngine::canLoadGameStateCurrently() { + TattooUserInterface &ui = *(TattooUserInterface *)_ui; + return _canLoadSave && !ui._creditsWidget.active() && !_runningProlog; +} + bool TattooEngine::canSaveGameStateCurrently() { TattooUserInterface &ui = *(TattooUserInterface *)_ui; return _canLoadSave && !ui._creditsWidget.active() && !_runningProlog; diff --git a/engines/sherlock/tattoo/tattoo.h b/engines/sherlock/tattoo/tattoo.h index 71872ab1b9..eff8734d62 100644 --- a/engines/sherlock/tattoo/tattoo.h +++ b/engines/sherlock/tattoo/tattoo.h @@ -102,6 +102,11 @@ public: */ virtual void saveConfig(); + /** + * Returns true if a savegame can be loaded + */ + virtual bool canLoadGameStateCurrently(); + /** * Returns true if the game can be saved */ -- cgit v1.2.3