Skip to content
Permalink
Browse files

Merge pull request #11525 from LunaMoo/cheatdbImport

Fix cheat.db comments ending the cheat import.
  • Loading branch information...
hrydgard committed Nov 3, 2018
2 parents 85d9896 + 9929eed commit 2704ab3ffa99bdfc10945612de8a15a9f819a0bb
Showing with 3 additions and 3 deletions.
  1. +3 −3 UI/CwCheatScreen.cpp
@@ -223,13 +223,13 @@ UI::EventReturn CwCheatScreen::OnImportCheat(UI::EventParams &params) {
do {
newList.push_back(line);
getline(fs, line);
} while (line[0] == '_' && line[1] == 'L');
} while ((line[0] == '_' && line[1] == 'L') || line[0] == '/' || line[0] == '#');
finished = true;
} else {
continue;
}
loop:;
} while (fs.good() && line[0] == '_' && line[1] != 'S');
} while (fs.good() && (line[0] == '_' && line[1] != 'S') || line[0] == '/' || line[0] == '#');
finished = true;
}
if (finished == true)
@@ -243,7 +243,7 @@ UI::EventReturn CwCheatScreen::OnImportCheat(UI::EventParams &params) {
File::OpenCPPFile(fs, activeCheatFile, std::ios::out | std::ios::app);

auto it = title.begin();
if (title2[0] == '_' && title2[1] != 'S' && it != title.end() && (++it) != title.end()) {
if ((title2[0] == '_' && title2[1] != 'S') || title2[0] == '/' || title2[0] == '#' && it != title.end() && (++it) != title.end()) {
fs << title[0] << "\n" << title[1];
}

0 comments on commit 2704ab3

Please sign in to comment.
You can’t perform that action at this time.