diff options
author | Gregory Montoir | 2007-09-27 20:38:23 +0000 |
---|---|---|
committer | Gregory Montoir | 2007-09-27 20:38:23 +0000 |
commit | d8831b44da24c16eef5fcc368d8d54953f0c60b5 (patch) | |
tree | a7f860ac63e73565fa0cf4628da0f6417afba230 /engines/touche/saveload.cpp | |
parent | c1eacc03571b9afbedd188fbf26ff115dbf8e393 (diff) | |
download | scummvm-rg350-d8831b44da24c16eef5fcc368d8d54953f0c60b5.tar.gz scummvm-rg350-d8831b44da24c16eef5fcc368d8d54953f0c60b5.tar.bz2 scummvm-rg350-d8831b44da24c16eef5fcc368d8d54953f0c60b5.zip |
simplified touche savegame listing
svn-id: r29112
Diffstat (limited to 'engines/touche/saveload.cpp')
-rw-r--r-- | engines/touche/saveload.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/engines/touche/saveload.cpp b/engines/touche/saveload.cpp index 7901e5c31f..46e3194644 100644 --- a/engines/touche/saveload.cpp +++ b/engines/touche/saveload.cpp @@ -407,4 +407,13 @@ void ToucheEngine::generateGameStateFileName(int num, char *dst, int len, bool p dst[len] = 0; } +int ToucheEngine::getGameStateFileSlot(const char *filename) const { + int i = -1; + const char *slot = strrchr(filename, '.'); + if (slot) { + i = atoi(slot + 1); + } + return i; +} + } // namespace Touche |