aboutsummaryrefslogtreecommitdiff
path: root/engines/groovie/script.cpp
diff options
context:
space:
mode:
authorJohannes Schickel2011-07-02 20:25:32 +0200
committerJohannes Schickel2011-07-02 21:07:55 +0200
commit09501be85bee9f686a7815fc0f47a1e16008f38d (patch)
tree5aecb20411d3300a185214f3a6590888f4559b35 /engines/groovie/script.cpp
parenta5b0792295f46ebcf5d30df975bd2056bc4a695f (diff)
downloadscummvm-rg350-09501be85bee9f686a7815fc0f47a1e16008f38d.tar.gz
scummvm-rg350-09501be85bee9f686a7815fc0f47a1e16008f38d.tar.bz2
scummvm-rg350-09501be85bee9f686a7815fc0f47a1e16008f38d.zip
ENGINES: Clean up SaveStateDescriptor.
Now SaveStateDescriptor no longer subclasses HashMap. Instead all possible saved meta data is included directly into SaveStateDescriptor. This is slightly less flexible, but we never needed that flexibility so far. On the other hand it should reduce the memory usage. At least on my system (Linux/amd64) the old SaveStateDescriptor had a size of 928 and the new SaveStateDescriptor has a size of 200.
Diffstat (limited to 'engines/groovie/script.cpp')
-rw-r--r--engines/groovie/script.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/engines/groovie/script.cpp b/engines/groovie/script.cpp
index f87e6bb91b..5a24559e8b 100644
--- a/engines/groovie/script.cpp
+++ b/engines/groovie/script.cpp
@@ -1350,15 +1350,15 @@ void Script::o_checkvalidsaves() {
uint count = 0;
SaveStateList::iterator it = list.begin();
while (it != list.end()) {
- int8 slot = it->getVal("save_slot").lastChar() - '0';
+ int8 slot = it->getSaveSlot();
if (SaveLoad::isSlotValid(slot)) {
- debugScript(2, true, " Found valid savegame: %s", it->getVal("description").c_str());
+ debugScript(2, true, " Found valid savegame: %s", it->getDescription().c_str());
// Mark this slot as used
setVariable(slot, 1);
// Cache this slot's description
- _saveNames[slot] = it->getVal("description");
+ _saveNames[slot] = it->getDescription();
count++;
}
it++;