summaryrefslogtreecommitdiff
path: root/src/net/charserverhandler.cpp
diff options
context:
space:
mode:
authorBjörn Steinbrink <B.Steinbrink@gmx.de>2006-11-02 12:43:49 +0000
committerBjörn Steinbrink <B.Steinbrink@gmx.de>2006-11-02 12:43:49 +0000
commit5f0ebee0d4d75fa91d417f4f352abdbc7502c2f0 (patch)
treeb030f9ff00fceb9f90fab2c9fd56bdc16cd4126c /src/net/charserverhandler.cpp
parentfa035c2fd70945a0b12143ce9b81284d8d24d13b (diff)
downloadmana-5f0ebee0d4d75fa91d417f4f352abdbc7502c2f0.tar.gz
mana-5f0ebee0d4d75fa91d417f4f352abdbc7502c2f0.tar.bz2
mana-5f0ebee0d4d75fa91d417f4f352abdbc7502c2f0.tar.xz
mana-5f0ebee0d4d75fa91d417f4f352abdbc7502c2f0.zip
Network layer refactoring.
Diffstat (limited to 'src/net/charserverhandler.cpp')
-rw-r--r--src/net/charserverhandler.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/net/charserverhandler.cpp b/src/net/charserverhandler.cpp
index 4e251524..f715b434 100644
--- a/src/net/charserverhandler.cpp
+++ b/src/net/charserverhandler.cpp
@@ -23,9 +23,9 @@
#include "charserverhandler.h"
-#include "messagein.h"
-#include "network.h"
+#include "connection.h"
#include "protocol.h"
+#include "messagein.h"
#include "../game.h"
#include "../localplayer.h"
@@ -35,6 +35,9 @@
#include "../gui/ok_dialog.h"
+extern Net::Connection *gameServerConnection;
+extern Net::Connection *chatServerConnection;
+
CharServerHandler::CharServerHandler()
{
static const Uint16 _messages[] = {
@@ -174,8 +177,8 @@ CharServerHandler::handleCharSelectResponse(MessageIn &msg)
logger->log("Game server: %s:%d", gameServer.c_str(), gameServerPort);
logger->log("Chat server: %s:%d", chatServer.c_str(), chatServerPort);
- Network::connect(Network::GAME, gameServer, gameServerPort);
- Network::connect(Network::CHAT, chatServer, chatServerPort);
+ gameServerConnection->connect(gameServer, gameServerPort);
+ chatServerConnection->connect(chatServer, chatServerPort);
// Keep the selected character and delete the others
player_node = mCharInfo->getEntry();