diff options
author | Björn Steinbrink <B.Steinbrink@gmx.de> | 2005-10-16 21:18:11 +0000 |
---|---|---|
committer | Björn Steinbrink <B.Steinbrink@gmx.de> | 2005-10-16 21:18:11 +0000 |
commit | d3175115354bb2417f01877a96d0068e2f2c875d (patch) | |
tree | 3fe6dde2b7922eb12bc376687ae18a59971d908e /src/gui/login.cpp | |
parent | 43a80fa64acb7f02cf5305b4a3d2ef6040b4b8c9 (diff) | |
download | mana-d3175115354bb2417f01877a96d0068e2f2c875d.tar.gz mana-d3175115354bb2417f01877a96d0068e2f2c875d.tar.bz2 mana-d3175115354bb2417f01877a96d0068e2f2c875d.tar.xz mana-d3175115354bb2417f01877a96d0068e2f2c875d.zip |
Rename {read,write}{Byte,Short,Long} to {read,write}Int{8,16,32}.
Diffstat (limited to 'src/gui/login.cpp')
-rw-r--r-- | src/gui/login.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/gui/login.cpp b/src/gui/login.cpp index 6846059c..4f08216b 100644 --- a/src/gui/login.cpp +++ b/src/gui/login.cpp @@ -342,11 +342,11 @@ LoginDialog::attemptLogin(const std::string& user, const std::string& pass) { // Send login infos MessageOut outMsg; - outMsg.writeShort(0x0064); - outMsg.writeLong(0); // client version + outMsg.writeInt16(0x0064); + outMsg.writeInt32(0); // client version outMsg.writeString(user, 24); outMsg.writeString(pass, 24); - outMsg.writeByte(0); // unknown + outMsg.writeInt8(0); // unknown // Receive reply MessageIn msg = get_next_message(); @@ -365,20 +365,20 @@ LoginDialog::attemptLogin(const std::string& user, const std::string& pass) n_server = (msg.getLength() - 47) / 32; server_info = (SERVER_INFO**)malloc(sizeof(SERVER_INFO*) * n_server); - session_ID1 = msg.readLong(); - account_ID = msg.readLong(); - session_ID2 = msg.readLong(); + session_ID1 = msg.readInt32(); + account_ID = msg.readInt32(); + session_ID2 = msg.readInt32(); msg.skip(30); // unknown - sex = msg.readByte(); + sex = msg.readInt8(); for (int i = 0; i < n_server; i++) { server_info[i] = new SERVER_INFO; - server_info[i]->address = msg.readLong(); - server_info[i]->port = msg.readShort(); + server_info[i]->address = msg.readInt32(); + server_info[i]->port = msg.readInt16(); server_info[i]->name = msg.readString(20); - server_info[i]->online_users = msg.readLong(); + server_info[i]->online_users = msg.readInt32(); msg.skip(2); // unknown logger->log("Network: Server: %s (%s:%d)", @@ -392,7 +392,7 @@ LoginDialog::attemptLogin(const std::string& user, const std::string& pass) } else if (msg.getId() == 0x006a) { - int loginError = msg.readByte(); + int loginError = msg.readInt8(); logger->log("Login::error code: %i", loginError); switch (loginError) { |