summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2017-12-27 04:00:36 +0300
committerAndrei Karas <akaras@inbox.ru>2017-12-27 04:00:36 +0300
commit1614644f5367a7a17fb5bc754b1ee47561d5905b (patch)
tree22ddb02f9927d03ebb515561559ccbfbf97fde1f /src
parent003043714367009efaf07015cc63a901ae2ee47c (diff)
downloadmanaverse-1614644f5367a7a17fb5bc754b1ee47561d5905b.tar.gz
manaverse-1614644f5367a7a17fb5bc754b1ee47561d5905b.tar.bz2
manaverse-1614644f5367a7a17fb5bc754b1ee47561d5905b.tar.xz
manaverse-1614644f5367a7a17fb5bc754b1ee47561d5905b.zip
Remove default parameters from configuration.
Diffstat (limited to 'src')
-rw-r--r--src/configmanager.cpp8
-rw-r--r--src/configuration.h4
-rw-r--r--src/dirs.cpp8
-rw-r--r--src/progs/dyecmd/client.cpp10
-rw-r--r--src/progs/manaplus/client.cpp10
-rw-r--r--src/test/testmain.cpp8
6 files changed, 36 insertions, 12 deletions
diff --git a/src/configmanager.cpp b/src/configmanager.cpp
index 13f917d1e..0de200d00 100644
--- a/src/configmanager.cpp
+++ b/src/configmanager.cpp
@@ -78,7 +78,9 @@ void ConfigManager::initServerConfig(const std::string &serverName)
if (configFile != nullptr)
{
fclose(configFile);
- serverConfig.init(configPath);
+ serverConfig.init(configPath,
+ UseVirtFs_false,
+ SkipError_false);
setConfigDefaults(serverConfig);
logger->log("serverConfigPath: " + configPath);
}
@@ -163,7 +165,9 @@ void ConfigManager::initConfiguration()
else
{
fclose(configFile);
- config.init(configPath);
+ config.init(configPath,
+ UseVirtFs_false,
+ SkipError_false);
logger->log1("init 3");
setConfigDefaults(config);
setConfigDefaults(serverConfig);
diff --git a/src/configuration.h b/src/configuration.h
index dae353143..6d8eccf42 100644
--- a/src/configuration.h
+++ b/src/configuration.h
@@ -248,8 +248,8 @@ class Configuration final : public ConfigurationObject
* @param useResManager Make use of the resource manager.
*/
void init(const std::string &filename,
- const UseVirtFs useResManager = UseVirtFs_false,
- const SkipError skipError = SkipError_false);
+ const UseVirtFs useResManager,
+ const SkipError skipError);
void reInit();
diff --git a/src/dirs.cpp b/src/dirs.cpp
index 54f28aed1..96cf24063 100644
--- a/src/dirs.cpp
+++ b/src/dirs.cpp
@@ -273,11 +273,15 @@ void Dirs::initRootDir()
{
std::string dir;
Configuration portable;
- portable.init(portableName);
+ portable.init(portableName,
+ UseVirtFs_false,
+ SkipError_false);
if (settings.options.brandingPath.empty())
{
- branding.init(portableName);
+ branding.init(portableName,
+ UseVirtFs_false,
+ SkipError_false);
setBrandingDefaults(branding);
}
diff --git a/src/progs/dyecmd/client.cpp b/src/progs/dyecmd/client.cpp
index 7046be25d..199f91ecd 100644
--- a/src/progs/dyecmd/client.cpp
+++ b/src/progs/dyecmd/client.cpp
@@ -163,7 +163,11 @@ void Client::gameInit()
// Load branding information
if (!settings.options.brandingPath.empty())
- branding.init(settings.options.brandingPath);
+ {
+ branding.init(settings.options.brandingPath,
+ UseVirtFs_false,
+ SkipError_false);
+ }
setBrandingDefaults(branding);
Dirs::initRootDir();
@@ -683,7 +687,9 @@ int Client::gameExec()
}
logger->log("Init paths");
- paths.init("paths.xml", UseVirtFs_true);
+ paths.init("paths.xml",
+ UseVirtFs_true,
+ SkipError_false);
setPathsDefaults(paths);
initPaths();
TranslationManager::loadCurrentLang();
diff --git a/src/progs/manaplus/client.cpp b/src/progs/manaplus/client.cpp
index 380453c19..89de4cb5b 100644
--- a/src/progs/manaplus/client.cpp
+++ b/src/progs/manaplus/client.cpp
@@ -282,7 +282,11 @@ void Client::gameInit()
assertListener = new AssertListener;
// Load branding information
if (!settings.options.brandingPath.empty())
- branding.init(settings.options.brandingPath);
+ {
+ branding.init(settings.options.brandingPath,
+ UseVirtFs_false,
+ SkipError_false);
+ }
setBrandingDefaults(branding);
Dirs::initRootDir();
@@ -1907,7 +1911,9 @@ void Client::loadData()
}
logger->log("Init paths");
- paths.init("paths.xml", UseVirtFs_true);
+ paths.init("paths.xml",
+ UseVirtFs_true,
+ SkipError_false);
setPathsDefaults(paths);
initPaths();
if (SpriteReference::Empty == nullptr)
diff --git a/src/test/testmain.cpp b/src/test/testmain.cpp
index 945aec73b..9e17ff8da 100644
--- a/src/test/testmain.cpp
+++ b/src/test/testmain.cpp
@@ -51,7 +51,9 @@ TestMain::~TestMain()
void TestMain::initConfig()
{
- mConfig.init(settings.configDir + "/test.xml");
+ mConfig.init(settings.configDir + "/test.xml",
+ UseVirtFs_false,
+ SkipError_false);
mConfig.clear();
// setConfigDefaults(mConfig);
@@ -277,7 +279,9 @@ void TestMain::writeConfig(const RenderType openGLMode,
const std::string &textureSize,
const int detectMode)
{
- mConfig.init(settings.configDir + "/config.xml");
+ mConfig.init(settings.configDir + "/config.xml",
+ UseVirtFs_false,
+ SkipError_false);
log->log("set mode to %d", CAST_S32(openGLMode));