mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Change str.substr(x, 1) == "y" to str[x] == 'y'
This commit is contained in:
parent
16057eda39
commit
be18f2c3cc
1 changed files with 3 additions and 3 deletions
|
@ -342,15 +342,15 @@ std::vector<std::string> CWCheatEngine::GetCodesList() {
|
||||||
|
|
||||||
bool validCheatLine = false;
|
bool validCheatLine = false;
|
||||||
// This code is used by cheat menu which doesn't support empty names
|
// This code is used by cheat menu which doesn't support empty names
|
||||||
if (line.length() >= 5 && line.substr(0, 1) == "_") {
|
if (line.length() >= 5 && line[0] == '_') {
|
||||||
for (int i = 4; i < line.length(); i++) {
|
for (int i = 4; i < line.length(); i++) {
|
||||||
if (line.substr(i, 1) != " ") {
|
if (line[i] != ' ') {
|
||||||
validCheatLine = true;
|
validCheatLine = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (validCheatLine || (line.length() >= 2 && line.substr(0, 2) == "//") || (line.length() >= 1 && line.substr(0, 1) == "#")) {
|
if (validCheatLine || (line.length() >= 2 && line[0] == '/' && line[1] == '/') || (line.length() >= 1 && line[0] == '#')) {
|
||||||
codesList.push_back(TrimString(line));
|
codesList.push_back(TrimString(line));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue