summaryrefslogtreecommitdiff
path: root/src/savegame.cpp
diff options
context:
space:
mode:
authorTannin <devnull@localhost>2014-07-15 20:37:10 +0200
committerTannin <devnull@localhost>2014-07-15 20:37:10 +0200
commit80b10107d9deeaf8b1aa9d306ea506aafcb99bd1 (patch)
tree3db705018950f19c2e71c0ef42d94172d1522b78 /src/savegame.cpp
parent1707941f6ec256e1bc48edec01ea41be9526fb81 (diff)
- Disabled compilation of loot_cli as the current loot version can't be compiled or linked against with vs 2010
- bugfix: some incompatibilities with non-skyrim games - bugfix: incorrect handling of plurals in translateable strings
Diffstat (limited to 'src/savegame.cpp')
-rw-r--r--src/savegame.cpp14
1 files changed, 9 insertions, 5 deletions
diff --git a/src/savegame.cpp b/src/savegame.cpp
index d09f291c..06e028e2 100644
--- a/src/savegame.cpp
+++ b/src/savegame.cpp
@@ -21,10 +21,11 @@ along with Mod Organizer. If not, see <http://www.gnu.org/licenses/>.
#include <QFile>
#include <QBuffer>
#include <set>
-#include "gameinfo.h"
#include <QFileInfo>
#include <QDateTime>
+#include <utility.h>
#include <limits>
+#include "gameinfo.h"
SaveGame::SaveGame(QObject *parent)
@@ -68,11 +69,14 @@ SaveGame::~SaveGame()
QStringList SaveGame::attachedFiles() const
{
QStringList result;
- QString seFileFile = fileName().mid(0).replace(".ess", ".skse");
- QFileInfo seFile(seFileFile);
- if (seFile.exists()) {
- result.append(seFile.absoluteFilePath());
+ foreach (const std::wstring &ext, MOShared::GameInfo::instance().getSavegameAttachmentExtensions()) {
+ QFileInfo fi(fileName());
+ fi.setFile(fi.canonicalPath() + "/" + fi.completeBaseName() + "." + MOBase::ToQString(ext));
+ if (fi.exists()) {
+ result.append(fi.filePath());
+ }
}
+
return result;
}