summaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorYohann Ferreira <bertram@cegetel.net>2006-01-04 21:06:07 +0000
committerYohann Ferreira <bertram@cegetel.net>2006-01-04 21:06:07 +0000
commit0417f123f1975202900ed0b3ec1bb8362f9f1567 (patch)
tree5d51c3478b0921184a950ae5847627b3f96b05ab /src/main.cpp
parent65c5f32f9622583bd158d3baa52056cb3b7be4f6 (diff)
downloadmanaserv-0417f123f1975202900ed0b3ec1bb8362f9f1567.tar.gz
manaserv-0417f123f1975202900ed0b3ec1bb8362f9f1567.tar.bz2
manaserv-0417f123f1975202900ed0b3ec1bb8362f9f1567.tar.xz
manaserv-0417f123f1975202900ed0b3ec1bb8362f9f1567.zip
Implemented server response handling to the test client. Fixed a bug that made the Email change not possible. Changed some protocol value to have a litte neater client code. Added FreeBSD fix idea from icy to server code.
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/main.cpp b/src/main.cpp
index b6b0659b..d39b04c5 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -28,7 +28,7 @@
#include <SDL.h>
#include <SDL_net.h>
-#ifdef __USE_UNIX98
+#if (defined __USE_UNIX98 || defined __FreeBSD__)
#include "../config.h"
#endif
@@ -131,7 +131,7 @@ void initialize()
std::string configPath = CONFIG_FILE;
#else
-#ifdef __USE_UNIX98
+#if (defined __USE_UNIX98 || defined __FreeBSD__)
std::string configPath = getenv("HOME");
configPath += "/.";
configPath += DEFAULT_CONFIG_FILE;
@@ -146,7 +146,7 @@ void initialize()
std::string logPath = LOG_FILE;
#else
-#ifdef __USE_UNIX98
+#if (defined __USE_UNIX98 || defined __FreeBSD__)
std::string logPath = getenv("HOME");
logPath += "/.";
logPath += DEFAULT_LOG_FILE;
@@ -343,7 +343,7 @@ void parseOptions(int argc, char *argv[])
*/
int main(int argc, char *argv[])
{
-#ifdef __USE_UNIX98
+#if (defined __USE_UNIX98 || defined __FreeBSD__)
LOG_INFO("The Mana World Server v" << PACKAGE_VERSION, 0)
#endif
@@ -370,6 +370,9 @@ int main(int argc, char *argv[])
connectionHandler->registerHandler(CMSG_CHAR_SELECT, accountHandler);
connectionHandler->registerHandler(CMSG_CHAR_DELETE, accountHandler);
connectionHandler->registerHandler(CMSG_CHAR_LIST, accountHandler);
+ connectionHandler->registerHandler(CMSG_EMAIL_GET, accountHandler);
+ connectionHandler->registerHandler(CMSG_PASSWORD_CHANGE, accountHandler);
+ connectionHandler->registerHandler(CMSG_EMAIL_CHANGE, accountHandler);
connectionHandler->registerHandler(CMSG_SAY, chatHandler);
connectionHandler->registerHandler(CMSG_ANNOUNCE, chatHandler);