Options redesign; Rumble intensity; Dark fix; Remove OGL patches
This commit is contained in:
@@ -23,12 +23,12 @@ namespace TLAC::FileSystem
|
||||
return found;
|
||||
}
|
||||
|
||||
int ConfigFile::GetIntegerValue(const std::string& key)
|
||||
int ConfigFile::GetIntegerValue(const std::string& key, int defaultval)
|
||||
{
|
||||
auto pair = ConfigMap.find(key);
|
||||
bool found = pair != ConfigMap.end();
|
||||
|
||||
return found ? atoi(pair->second.c_str()) : 0;
|
||||
return found ? atoi(pair->second.c_str()) : defaultval;
|
||||
}
|
||||
|
||||
bool ConfigFile::GetBooleanValue(const std::string& key)
|
||||
|
||||
@@ -14,7 +14,7 @@ namespace TLAC::FileSystem
|
||||
std::unordered_map<std::string, std::string> ConfigMap;
|
||||
|
||||
bool TryGetValue(const std::string &key, std::string **value);
|
||||
int GetIntegerValue(const std::string& key);
|
||||
int GetIntegerValue(const std::string& key, int defaultval = 0);
|
||||
bool GetBooleanValue(const std::string& key);
|
||||
float GetFloatValue(const std::string& key);
|
||||
std::string GetStringValue(const std::string& key);
|
||||
|
||||
Reference in New Issue
Block a user