summaryrefslogtreecommitdiff
path: root/src/server.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/server.cpp')
-rw-r--r--src/server.cpp13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/server.cpp b/src/server.cpp
index 399c41b70..2d84ad032 100644
--- a/src/server.cpp
+++ b/src/server.cpp
@@ -244,9 +244,6 @@ Server::Server(
std::string ban_path = m_path_world + DIR_DELIM "ipban.txt";
m_banmanager = new BanManager(ban_path);
- // Create rollback manager
- m_rollback = new RollbackManager(m_path_world, this);
-
ModConfiguration modconf(m_path_world);
m_mods = modconf.getMods();
std::vector<ModSpec> unsatisfied_mods = modconf.getUnsatisfiedMods();
@@ -354,6 +351,12 @@ Server::Server(
// Initialize mapgens
m_emerge->initMapgens();
+ m_enable_rollback_recording = g_settings->getBool("enable_rollback_recording");
+ if (m_enable_rollback_recording) {
+ // Create rollback manager
+ m_rollback = new RollbackManager(m_path_world, this);
+ }
+
// Give environment reference to scripting api
m_script->initializeEnvironment(m_env);
@@ -1108,10 +1111,6 @@ void Server::AsyncRunStep(bool initial_step)
counter = 0.0;
m_emerge->startThreads();
-
- // Update m_enable_rollback_recording here too
- m_enable_rollback_recording =
- g_settings->getBool("enable_rollback_recording");
}
}