aboutsummaryrefslogtreecommitdiff
path: root/engines/agi/saveload.cpp
diff options
context:
space:
mode:
authorTorbjörn Andersson2010-10-03 18:38:38 +0000
committerTorbjörn Andersson2010-10-03 18:38:38 +0000
commit8d297f065ad67de8c0986ae33ff5e4520e90d4e4 (patch)
treea340dcd72e690147a5c04b23a9b1641baeefcd00 /engines/agi/saveload.cpp
parentc9713bef7c0d6e5e7380491c3b201afa6c1e2677 (diff)
downloadscummvm-rg350-8d297f065ad67de8c0986ae33ff5e4520e90d4e4.tar.gz
scummvm-rg350-8d297f065ad67de8c0986ae33ff5e4520e90d4e4.tar.bz2
scummvm-rg350-8d297f065ad67de8c0986ae33ff5e4520e90d4e4.zip
AGI: Properly detect the autosave slot in the save dialog
Forward-ported from branch. Let's do this the easy way for now, even if I'm not sure why the save dialog shows the autosave slot anyway. svn-id: r52997
Diffstat (limited to 'engines/agi/saveload.cpp')
-rw-r--r--engines/agi/saveload.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/engines/agi/saveload.cpp b/engines/agi/saveload.cpp
index 386a6b1135..1a968816d4 100644
--- a/engines/agi/saveload.cpp
+++ b/engines/agi/saveload.cpp
@@ -809,12 +809,11 @@ int AgiEngine::saveGameDialog() {
printText("Select a slot in which you wish to\nsave the game:",
0, hm + 1, vm + 1, w, MSG_BOX_TEXT, MSG_BOX_COLOUR);
slot = selectSlot();
- if (slot == 0)
+ if (slot + _firstSlot == 0)
messageBox("That slot is for Autosave only.");
else if (slot < 0)
return errOK;
- }
- while (slot == 0);
+ } while (slot + _firstSlot == 0);
drawWindow(hp, vp + 5 * CHAR_LINES, GFX_WIDTH - hp,
GFX_HEIGHT - vp - 9 * CHAR_LINES);