summaryrefslogtreecommitdiffstats
path: root/source/Root.cpp
diff options
context:
space:
mode:
authormadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-10-31 20:54:42 +0100
committermadmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6>2012-10-31 20:54:42 +0100
commit08a20492efe581acc1129e940c730c1ea1715674 (patch)
treeb0c24665762aa81f202964aa51ca5c13c9cf7010 /source/Root.cpp
parentFixed gcc compilation (diff)
downloadcuberite-08a20492efe581acc1129e940c730c1ea1715674.tar
cuberite-08a20492efe581acc1129e940c730c1ea1715674.tar.gz
cuberite-08a20492efe581acc1129e940c730c1ea1715674.tar.bz2
cuberite-08a20492efe581acc1129e940c730c1ea1715674.tar.lz
cuberite-08a20492efe581acc1129e940c730c1ea1715674.tar.xz
cuberite-08a20492efe581acc1129e940c730c1ea1715674.tar.zst
cuberite-08a20492efe581acc1129e940c730c1ea1715674.zip
Diffstat (limited to '')
-rw-r--r--source/Root.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/source/Root.cpp b/source/Root.cpp
index 750478c10..d8b929102 100644
--- a/source/Root.cpp
+++ b/source/Root.cpp
@@ -14,6 +14,7 @@
#include "Blocks/BlockHandler.h"
#include "Items/ItemHandler.h"
#include "Chunk.h"
+#include "Protocol/ProtocolRecognizer.h" // for protocol version constants
#ifdef USE_SQUIRREL
#include "squirrelbindings/SquirrelFunctions.h"
@@ -98,8 +99,10 @@ void cRoot::Start()
LOG("Starting server...");
cIniFile IniFile("settings.ini");
IniFile.ReadFile();
+ m_PrimaryServerVersion = IniFile.GetValueSetI("Server", "PrimaryServerVersion", cProtocolRecognizer::PROTO_VERSION_1_4_2);
+
int Port = IniFile.GetValueSetI("Server", "Port", 25565 );
- if(!m_Server->InitServer( Port ))
+ if (!m_Server->InitServer(Port))
{
LOG("Failed to start server, shutting down.");
return;