From dbc13a3ad21d1b026eb42ef405e6ab441922de61 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 25 Sep 2017 19:31:40 +0300 Subject: Add support for char server packets for packet version >= 20170830. --- src/net/eathena/charserverrecv.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/net/eathena') diff --git a/src/net/eathena/charserverrecv.cpp b/src/net/eathena/charserverrecv.cpp index 487e148bd..9aea7602e 100644 --- a/src/net/eathena/charserverrecv.cpp +++ b/src/net/eathena/charserverrecv.cpp @@ -86,10 +86,16 @@ void CharServerRecv::readPlayerData(Net::MessageIn &msg, tempPlayer->setGender(token.sex); PlayerInfoBackend &data = character->data; - data.mAttributes[Attributes::PLAYER_EXP] = msg.readInt32("exp"); + if (packetVersion >= 20170830) + data.mAttributes[Attributes::PLAYER_EXP] = msg.readInt64("exp"); + else + data.mAttributes[Attributes::PLAYER_EXP] = msg.readInt32("exp"); data.mAttributes[Attributes::MONEY] = msg.readInt32("money"); Stat &jobStat = data.mStats[Attributes::PLAYER_JOB]; - jobStat.exp = msg.readInt32("job"); + if (packetVersion >= 20170830) + jobStat.exp = msg.readInt64("job exp"); + else + jobStat.exp = msg.readInt32("job exp"); const int temp = msg.readInt32("job level"); jobStat.base = temp; -- cgit v1.2.3-70-g09d2