mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-29 17:23:40 +01:00
Compat: Add setting to skip compat flags.
This allows configuring "ALL" to skip all, regardless of if new game IDs are added in a later stable release.
This commit is contained in:
1 parent
21bf41e6dd
commit
0f9f53c1b7
4 files changed
+19
-1
No files matched your search
+13
-1
@@ -18,12 +18,22 @@
|
||||
#include <cstring>
|
||||
|
||||
#include "Common/Data/Format/IniFile.h"
|
||||
#include "Common/StringUtils.h"
|
||||
#include "Core/Compatibility.h"
|
||||
#include "Core/Config.h"
|
||||
#include "Core/System.h"
|
||||
|
||||
void Compatibility::Load(const std::string &gameID) {
|
||||
Clear();
|
||||
|
||||
// Allow ignoring compat settings by name (regardless of game ID.)
|
||||
std::vector<std::string> ignored;
|
||||
SplitString(g_Config.sIgnoreCompatSettings, ',', ignored);
|
||||
ignored_ = std::set<std::string>(ignored.begin(), ignored.end());
|
||||
// If ALL, don't process any compat flags.
|
||||
if (ignored_.find("ALL") != ignored_.end())
|
||||
return;
|
||||
|
||||
{
|
||||
IniFile compat;
|
||||
// This loads from assets.
|
||||
@@ -83,5 +93,7 @@ void Compatibility::CheckSettings(IniFile &iniFile, const std::string &gameID) {
|
||||
}
|
||||
|
||||
void Compatibility::CheckSetting(IniFile &iniFile, const std::string &gameID, const char *option, bool *flag) {
|
||||
iniFile.Get(option, gameID.c_str(), flag, *flag);
|
||||
if (ignored_.find(option) != ignored_.end()) {
|
||||
iniFile.Get(option, gameID.c_str(), flag, *flag);
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user