mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
Taking screenshots now creates an extra folder for each Game ID.
Fixes Issue 1905 git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4842 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -519,10 +519,17 @@ static inline std::string GenerateScreenshotName()
|
|||||||
{
|
{
|
||||||
int index = 1;
|
int index = 1;
|
||||||
std::string tempname, name;
|
std::string tempname, name;
|
||||||
tempname = FULL_SCREENSHOTS_DIR + GetStartupParameter().GetUniqueID();
|
std::string gameId = GetStartupParameter().GetUniqueID();
|
||||||
|
tempname = FULL_SCREENSHOTS_DIR + gameId + DIR_SEP_CHR;
|
||||||
|
|
||||||
|
if (!File::CreateFullPath(tempname.c_str())) {
|
||||||
|
//fallback to old-style screenshots, without folder.
|
||||||
|
tempname = FULL_SCREENSHOTS_DIR;
|
||||||
|
}
|
||||||
|
//append gameId, tempname only contains the folder here.
|
||||||
|
tempname += gameId;
|
||||||
|
|
||||||
name = StringFromFormat("%s-%d.png", tempname.c_str(), index);
|
name = StringFromFormat("%s-%d.png", tempname.c_str(), index);
|
||||||
|
|
||||||
while(File::Exists(name.c_str()))
|
while(File::Exists(name.c_str()))
|
||||||
name = StringFromFormat("%s-%d.png", tempname.c_str(), ++index);
|
name = StringFromFormat("%s-%d.png", tempname.c_str(), ++index);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user