From 37791c4bd3b33aa042fc966d4ed2b1f5369b0939 Mon Sep 17 00:00:00 2001 From: David Fioramonti Date: Sat, 19 May 2018 12:46:36 -0700 Subject: MOHAWK: RIVEN: Add Autosave Support The game will autosave to slot 0 using the save period given in the scummvm config file. Or when the user quits. Autosaves are only allowed when an autosave is in slot 0, there is no save in slot 0, or there is a save, but it is corrupt. This will not override any saves the player has previously put in save slot 0. If there is a save in slot 0 that is not an autosave then there will be no autosaving. --- engines/mohawk/riven.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'engines/mohawk/riven.h') diff --git a/engines/mohawk/riven.h b/engines/mohawk/riven.h index 6ad1208cf3..3dc19c7ee4 100644 --- a/engines/mohawk/riven.h +++ b/engines/mohawk/riven.h @@ -121,6 +121,7 @@ private: RivenStack *_stack; bool _gameEnded; + uint32 _lastSaveTime; // Variables void initVars(); @@ -152,6 +153,7 @@ public: // Save / Load void runLoadDialog(); void runSaveDialog(); + void tryAutoSaving(); void loadGameStateAndDisplayError(int slot); void saveGameStateAndDisplayError(int slot, const Common::String &desc); -- cgit v1.2.3