diff options
-rw-r--r-- | engines/sword1/detection.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/sword1/detection.cpp b/engines/sword1/detection.cpp index 99c4bda9e9..3eac95cdf2 100644 --- a/engines/sword1/detection.cpp +++ b/engines/sword1/detection.cpp @@ -241,7 +241,6 @@ SaveStateList SwordMetaEngine::listSaves(const char *target) const { char saveName[40]; Common::StringArray filenames = saveFileMan->listSavefiles("sword1.###"); - sort(filenames.begin(), filenames.end()); // Sort (hopefully ensuring we are sorted numerically..) int slotNum = 0; for (Common::StringArray::const_iterator file = filenames.begin(); file != filenames.end(); ++file) { @@ -259,6 +258,8 @@ SaveStateList SwordMetaEngine::listSaves(const char *target) const { } } + // Sort saves based on slot number. + Common::sort(saveList.begin(), saveList.end(), SaveStateDescriptorSlotComparator()); return saveList; } |