diff options
author | Andrei Karas <akaras@inbox.ru> | 2018-12-27 21:42:14 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2019-01-14 20:18:10 +0300 |
commit | fa1cb492536f2853c59a995dc54aa51ead420546 (patch) | |
tree | b0b3751721d688a4795ca7a8a7b5909dca09191a /src/map/packets_struct.h | |
parent | 93b9a86bed2eb3a54b49557f663e06804985654f (diff) | |
download | hercules-fa1cb492536f2853c59a995dc54aa51ead420546.tar.gz hercules-fa1cb492536f2853c59a995dc54aa51ead420546.tar.bz2 hercules-fa1cb492536f2853c59a995dc54aa51ead420546.tar.xz hercules-fa1cb492536f2853c59a995dc54aa51ead420546.zip |
Add barter type shop and add packet ZC_NPC_BARTER_OPEN
Diffstat (limited to 'src/map/packets_struct.h')
-rw-r--r-- | src/map/packets_struct.h | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/map/packets_struct.h b/src/map/packets_struct.h index 9fd30c0f6..1e11eadd7 100644 --- a/src/map/packets_struct.h +++ b/src/map/packets_struct.h @@ -3056,6 +3056,34 @@ struct PACKET_CZ_PARTY_CONFIG { } __attribute__((packed)); DEFINE_PACKET_HEADER(CZ_PARTY_CONFIG, 0x02c8); +#if PACKETVER_ZERO_NUM >= 20181226 +struct PACKET_ZC_NPC_BARTER_OPEN_sub { +#if PACKETVER_MAIN_NUM >= 20181121 || PACKETVER_RE_NUM >= 20180704 || PACKETVER_ZERO_NUM >= 20181114 + uint32 nameid; +#else + uint16 nameid; +#endif + uint8 type; + uint32 amount; +#if PACKETVER_MAIN_NUM >= 20181121 || PACKETVER_RE_NUM >= 20180704 || PACKETVER_ZERO_NUM >= 20181114 + uint32 currencyNameid; +#else + uint16 currencyNameid; +#endif + uint32 currencyAmount; + uint32 weight; + uint32 index; +} __attribute__((packed)); + +struct PACKET_ZC_NPC_BARTER_OPEN { + int16 packetType; + int16 packetLength; + struct PACKET_ZC_NPC_BARTER_OPEN_sub list[]; +} __attribute__((packed)); + +DEFINE_PACKET_HEADER(ZC_NPC_BARTER_OPEN, 0x0b0e); +#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 |