summaryrefslogtreecommitdiff
path: root/src/map/packets_struct.h
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2020-02-09 20:14:56 +0100
committerGitHub <noreply@github.com>2020-02-09 20:14:56 +0100
commit57a71ed4da680c81a9ef313b80454b15f2c29765 (patch)
tree803ba967a4b5396181de4d1c7a692dd073122bf5 /src/map/packets_struct.h
parentc6859fe3af9165b4187470d92ee39aa1ac684b1b (diff)
parent35cc058ec2a4ccf5c3fbfae4ad4687398e3e7f62 (diff)
downloadhercules-57a71ed4da680c81a9ef313b80454b15f2c29765.tar.gz
hercules-57a71ed4da680c81a9ef313b80454b15f2c29765.tar.bz2
hercules-57a71ed4da680c81a9ef313b80454b15f2c29765.tar.xz
hercules-57a71ed4da680c81a9ef313b80454b15f2c29765.zip
Merge pull request #2625 from 4144/updatepackets
Update packets up to 2020-02-06
Diffstat (limited to 'src/map/packets_struct.h')
-rw-r--r--src/map/packets_struct.h66
1 files changed, 65 insertions, 1 deletions
diff --git a/src/map/packets_struct.h b/src/map/packets_struct.h
index 0fa602ba5..c2c99629a 100644
--- a/src/map/packets_struct.h
+++ b/src/map/packets_struct.h
@@ -3770,7 +3770,7 @@ struct PACKET_CZ_SE_CASHSHOP_LIMITED_REQ {
DEFINE_PACKET_HEADER(CZ_SE_CASHSHOP_LIMITED_REQ, 0x0b4c);
#endif
-#if PACKETVER_ZERO_NUM >= 20191224
+#if PACKETVER_MAIN_NUM >= 20200129 || PACKETVER_RE_NUM >= 20200205 || PACKETVER_ZERO_NUM >= 20191224
struct PACKET_ZC_SE_CASHSHOP_OPEN {
int16 packetType;
uint32 cashPoints;
@@ -3788,6 +3788,70 @@ struct PACKET_ZC_SE_CASHSHOP_OPEN {
DEFINE_PACKET_HEADER(ZC_SE_CASHSHOP_OPEN, 0x0845);
#endif
+#if PACKETVER_MAIN_NUM >= 20190904 || PACKETVER_RE_NUM >= 20190904 || PACKETVER_ZERO_NUM >= 20190828
+struct PACKET_CZ_NPC_EXPANDED_BARTER_CLOSE {
+ int16 packetType;
+} __attribute__((packed));
+DEFINE_PACKET_HEADER(CZ_NPC_EXPANDED_BARTER_CLOSE, 0x0b58);
+#endif
+
+#if PACKETVER_MAIN_NUM >= 20191120 || PACKETVER_RE_NUM >= 20191106 || PACKETVER_ZERO_NUM >= 20191127
+struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub2 {
+#if PACKETVER_MAIN_NUM >= 20181121 || PACKETVER_RE_NUM >= 20180704 || PACKETVER_ZERO_NUM >= 20181114
+ uint32 nameid;
+#else
+ uint16 nameid;
+#endif
+ uint16 refine_level;
+ uint32 amount;
+ uint16 type;
+} __attribute__((packed));
+
+struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub {
+#if PACKETVER_MAIN_NUM >= 20181121 || PACKETVER_RE_NUM >= 20180704 || PACKETVER_ZERO_NUM >= 20181114
+ uint32 nameid;
+#else
+ uint16 nameid;
+#endif
+ uint16 type;
+ uint32 amount;
+ uint32 weight;
+ uint32 index;
+ uint32 zeny;
+ uint32 currency_count;
+ struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub2 currencies[];
+} __attribute__((packed));
+
+struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN {
+ int16 packetType;
+ int16 packetLength;
+ int32 items_count;
+ struct PACKET_ZC_NPC_EXPANDED_BARTER_OPEN_sub items[];
+} __attribute__((packed));
+
+DEFINE_PACKET_HEADER(ZC_NPC_EXPANDED_BARTER_OPEN, 0x0b56);
+#endif
+
+#if PACKETVER_MAIN_NUM >= 20190904 || PACKETVER_RE_NUM >= 20190904 || PACKETVER_ZERO_NUM >= 20190828
+struct PACKET_CZ_NPC_EXPANDED_BARTER_PURCHASE_sub {
+#if PACKETVER_MAIN_NUM >= 20181121 || PACKETVER_RE_NUM >= 20180704 || PACKETVER_ZERO_NUM >= 20181114
+ uint32 itemId;
+#else
+ uint16 itemId;
+#endif
+ uint32 shopIndex;
+ uint32 amount;
+} __attribute__((packed));
+
+struct PACKET_CZ_NPC_EXPANDED_BARTER_PURCHASE {
+ int16 packetType;
+ int16 packetLength;
+ struct PACKET_CZ_NPC_EXPANDED_BARTER_PURCHASE_sub list[];
+} __attribute__((packed));
+DEFINE_PACKET_HEADER(CZ_NPC_EXPANDED_BARTER_PURCHASE, 0x0b57);
+#endif
+
+
#if !defined(sun) && (!defined(__NETBSD__) || __NetBSD_Version__ >= 600000000) // NetBSD 5 and Solaris don't like pragma pack but accept the packed attribute
#pragma pack(pop)
#endif // not NetBSD < 6 / Solaris