Skip to content
This repository has been archived by the owner on Mar 29, 2020. It is now read-only.

Commit

Permalink
Put saves in the correct places
Browse files Browse the repository at this point in the history
  • Loading branch information
Idhrendur committed Sep 28, 2013
1 parent 24ee86a commit 34effc0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
3 changes: 2 additions & 1 deletion Data Files/Changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -519,4 +519,5 @@ Revision Log Message
494 Update test scripts
495 Give cores on absorbed vassals
496 Update converter mod
497 Merge minor to main
497 Merge minor to main
498 Put saves in the correct places
12 changes: 7 additions & 5 deletions Source/Convert.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,12 +100,13 @@ int main(int argc, char * argv[])


//Copy mod folder
string modFolderName;
if (Configuration::getUseConverterMod() == "yes")
{
string modFolderName;
if (argc >= 2)
{
modFolderName = inputFilename.substr(0, inputFilename.find_last_of('.'));
modFolderName = modFolderName.substr(modFolderName.find_last_of('\\') + 1, modFolderName.length());
}
else
{
Expand Down Expand Up @@ -642,11 +643,11 @@ int main(int argc, char * argv[])
string outputFilename = "";
if (Configuration::getUseConverterMod() == "yes")
{
outputFilename += Configuration::getModPath() + "\\Converter\\save games\\";
outputFilename = modFolderName + "\\Converter\\save games\\";
if (argc >= 2)
{
string filename = inputFilename.substr(0, inputFilename.find_last_of('.'));
filename = filename.substr(filename.find_last_of('\\'), filename.length());
filename = filename.substr(filename.find_last_of('\\') + 1, filename.length());
outputFilename += filename + ".eu3";
}
else
Expand All @@ -658,8 +659,9 @@ int main(int argc, char * argv[])
{
if (argc >= 2)
{
outputFilename += inputFilename.substr(0, inputFilename.find_last_of('.'));
outputFilename += ".eu3";
string filename = inputFilename.substr(0, inputFilename.find_last_of('.'));
filename = filename.substr(filename.find_last_of('\\') + 1, filename.length());
outputFilename += filename + ".eu3";
}
else
{
Expand Down

0 comments on commit 34effc0

Please sign in to comment.