diff options
author | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2008-07-17 22:52:53 +0000 |
---|---|---|
committer | Bjørn Lindeijer <bjorn@lindeijer.nl> | 2008-07-17 22:52:53 +0000 |
commit | ea37ffc6d73bb0de686c29f8e8c6769f2a704ec5 (patch) | |
tree | fcca5b0bdca14ae694702ee4e882ba77a2a9b408 /src/net/loginhandler.cpp | |
parent | 406bac35e4c6e79b0ba8d5fe97f32516c8becb0b (diff) | |
download | mana-client-ea37ffc6d73bb0de686c29f8e8c6769f2a704ec5.tar.gz mana-client-ea37ffc6d73bb0de686c29f8e8c6769f2a704ec5.tar.bz2 mana-client-ea37ffc6d73bb0de686c29f8e8c6769f2a704ec5.tar.xz mana-client-ea37ffc6d73bb0de686c29f8e8c6769f2a704ec5.zip |
Added support for handling the custom eAthena packet that sends the update
host (patch by Sanga).
Diffstat (limited to 'src/net/loginhandler.cpp')
-rw-r--r-- | src/net/loginhandler.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/net/loginhandler.cpp b/src/net/loginhandler.cpp index ab788e41..8b057afd 100644 --- a/src/net/loginhandler.cpp +++ b/src/net/loginhandler.cpp @@ -37,6 +37,7 @@ extern SERVER_INFO **server_info; LoginHandler::LoginHandler() { static const Uint16 _messages[] = { + SMSG_UPDATE_HOST, 0x0069, 0x006a, 0 @@ -48,6 +49,16 @@ void LoginHandler::handleMessage(MessageIn *msg) { switch (msg->getId()) { + case 0x0063: + int len; + + len = msg->readInt16() - 4; + mUpdateHost = msg->readString(len); + + logger->log("Received update host \"%s\" from login server", + mUpdateHost.c_str()); + break; + case 0x0069: // Skip the length word msg->skip(2); @@ -70,6 +81,7 @@ void LoginHandler::handleMessage(MessageIn *msg) server_info[i]->port = msg->readInt16(); server_info[i]->name = msg->readString(20); server_info[i]->online_users = msg->readInt32(); + server_info[i]->updateHost = mUpdateHost; msg->skip(2); // unknown logger->log("Network: Server: %s (%s:%d)", @@ -77,7 +89,7 @@ void LoginHandler::handleMessage(MessageIn *msg) iptostring(server_info[i]->address), server_info[i]->port); } - state = CHAR_SERVER_STATE; + state = CHAR_SERVER_STATE; break; case 0x006a: |