summaryrefslogtreecommitdiff
path: root/src/net/ea/maphandler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/ea/maphandler.cpp')
-rw-r--r--src/net/ea/maphandler.cpp16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/net/ea/maphandler.cpp b/src/net/ea/maphandler.cpp
index fefeac86..d12106d6 100644
--- a/src/net/ea/maphandler.cpp
+++ b/src/net/ea/maphandler.cpp
@@ -96,9 +96,15 @@ void MapHandler::handleMessage(MessageIn &msg)
}
}
-void MapHandler::connect()
+void MapHandler::connect(LoginData *loginData)
{
- // TODO
+ // Send login infos
+ MessageOut outMsg(CMSG_MAP_SERVER_CONNECT);
+ outMsg.writeInt32(loginData->account_ID);
+ outMsg.writeInt32(player_node->mCharId);
+ outMsg.writeInt32(loginData->session_ID1);
+ outMsg.writeInt32(loginData->session_ID2);
+ outMsg.writeInt8(loginData->sex);
}
void MapHandler::mapLoaded(const std::string &mapName)
@@ -115,3 +121,9 @@ void MapHandler::quit()
{
MessageOut outMsg(CMSG_CLIENT_QUIT);
}
+
+void MapHandler::ping(int tick)
+{
+ MessageOut msg(CMSG_CLIENT_PING);
+ msg.writeInt32(tick);
+}