diff options
author | Andrei Karas <akaras@inbox.ru> | 2018-04-06 22:29:22 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2018-04-06 22:29:22 +0300 |
commit | 8ad5521d3bbb57040c746de4af2c82d0a8477936 (patch) | |
tree | aa3780d612cd6fedfb9fc93f1d6b46ce187fe4eb /src/net/eathena | |
parent | e34a496ae3b6fbb98115b9fe524cd202ddc8f795 (diff) | |
download | plus-8ad5521d3bbb57040c746de4af2c82d0a8477936.tar.gz plus-8ad5521d3bbb57040c746de4af2c82d0a8477936.tar.bz2 plus-8ad5521d3bbb57040c746de4af2c82d0a8477936.tar.xz plus-8ad5521d3bbb57040c746de4af2c82d0a8477936.zip |
Add variables with packet versions for each packet types (main, re, zero).
Diffstat (limited to 'src/net/eathena')
-rw-r--r-- | src/net/eathena/updateprotocol.cpp | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/net/eathena/updateprotocol.cpp b/src/net/eathena/updateprotocol.cpp index b1848f576..15050d099 100644 --- a/src/net/eathena/updateprotocol.cpp +++ b/src/net/eathena/updateprotocol.cpp @@ -28,9 +28,13 @@ #include "debug.h" extern int packetVersion; +extern int packetVersionMain; +extern int packetVersionRe; +extern int packetVersionZero; extern int serverVersion; extern int evolPacketOffset; extern bool packets_main; +extern bool packets_re; extern bool packets_zero; namespace EAthena @@ -39,6 +43,27 @@ namespace EAthena void updateProtocol() { logger->log("packet version: %d", packetVersion); + if (packets_main == true) + { + logger->log("packets version type: main"); + packetVersionMain = packetVersion; + packetVersionRe = 0; + packetVersionZero = 0; + } + else if (packets_re == true) + { + logger->log("packets version type: re"); + packetVersionRe = packetVersion; + packetVersionMain = 0; + packetVersionZero = 0; + } + else if (packets_zero == true) + { + logger->log("packets version type: zero"); + packetVersionZero = packetVersion; + packetVersionMain = 0; + packetVersionRe = 0; + } #define PACKETS_UPDATE #include "net/protocoloutupdate.h" #include "net/eathena/packetsout.inc" |