AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
WorldPackets::Guild::GuildBankQueryResults Class Referencefinal

#include "GuildPackets.h"

Inheritance diagram for WorldPackets::Guild::GuildBankQueryResults:
WorldPackets::ServerPacket WorldPackets::Packet

Public Member Functions

 GuildBankQueryResults ()
 
WorldPacket const * Write () override
 
void SetWithdrawalsRemaining (int32 withdrawalsRemaining)
 
- Public Member Functions inherited from WorldPackets::ServerPacket
 ServerPacket (OpcodeServer opcode, std::size_t initialSize=200)
 
void Read () final
 
void Clear ()
 
WorldPacket && Move ()
 
void ShrinkToFit ()
 
OpcodeServer GetOpcode () const
 
- Public Member Functions inherited from WorldPackets::Packet
 Packet (WorldPacket &&worldPacket)
 
virtual ~Packet ()=default
 
 Packet (Packet const &right)=delete
 
Packetoperator= (Packet const &right)=delete
 
virtual WorldPacket const * Write ()=0
 
virtual void Read ()=0
 
WorldPacket const * GetRawPacket () const
 
std::size_t GetSize () const
 

Public Attributes

std::vector< GuildBankItemInfoItemInfo
 
std::vector< GuildBankTabInfoTabInfo
 
int32 WithdrawalsRemaining = 0
 
uint8 Tab = 0
 
uint64 Money = 0
 
bool FullUpdate = false
 

Private Attributes

std::size_t _withdrawalsRemainingPos = 0
 

Additional Inherited Members

- Protected Attributes inherited from WorldPackets::Packet
WorldPacket _worldPacket
 

Detailed Description

Constructor & Destructor Documentation

◆ GuildBankQueryResults()

WorldPackets::Guild::GuildBankQueryResults::GuildBankQueryResults ( )
inline
@ SMSG_GUILD_BANK_LIST
Definition: Opcodes.h:1030
ServerPacket(OpcodeServer opcode, std::size_t initialSize=200)
Definition: Packet.cpp:25

Member Function Documentation

◆ SetWithdrawalsRemaining()

void WorldPackets::Guild::GuildBankQueryResults::SetWithdrawalsRemaining ( int32  withdrawalsRemaining)
332{
333 WithdrawalsRemaining = withdrawalsRemaining;
334 _worldPacket.put<int32>(_withdrawalsRemainingPos, withdrawalsRemaining);
335}
std::int32_t int32
Definition: Define.h:103
WorldPacket _worldPacket
Definition: Packet.h:42
int32 WithdrawalsRemaining
Definition: GuildPackets.h:490
std::size_t _withdrawalsRemainingPos
Definition: GuildPackets.h:498
void put(std::size_t pos, T value)
Definition: ByteBuffer.h:137

Referenced by Guild::_SendBankList().

◆ Write()

WorldPacket const * WorldPackets::Guild::GuildBankQueryResults::Write ( )
overridevirtual

Implements WorldPackets::Packet.

286{
292
293 if (!Tab && FullUpdate)
294 {
295 _worldPacket << uint8(TabInfo.size());
296 for (GuildBankTabInfo const& tab : TabInfo)
297 {
298 _worldPacket << tab.Name;
299 _worldPacket << tab.Icon;
300 }
301 }
302
303 _worldPacket << uint8(ItemInfo.size());
304 for (GuildBankItemInfo const& item : ItemInfo)
305 {
306 _worldPacket << uint8(item.Slot);
307 _worldPacket << uint32(item.ItemID);
308 if (item.ItemID)
309 {
310 _worldPacket << int32(item.Flags);
311 _worldPacket << int32(item.RandomPropertiesID);
312 if (item.RandomPropertiesID)
313 _worldPacket << int32(item.RandomPropertiesSeed);
314
315 _worldPacket << int32(item.Count);
316 _worldPacket << int32(item.EnchantmentID);
317 _worldPacket << uint8(item.Charges);
318 _worldPacket << uint8(item.SocketEnchant.size());
319
320 for (GuildBankSocketEnchant const& socketEnchant : item.SocketEnchant)
321 {
322 _worldPacket << uint8(socketEnchant.SocketIndex);
323 _worldPacket << int32(socketEnchant.SocketEnchantID);
324 }
325 }
326 }
327
328 return &_worldPacket;
329}
std::uint8_t uint8
Definition: Define.h:109
std::uint32_t uint32
Definition: Define.h:107
std::uint64_t uint64
Definition: Define.h:106
bool FullUpdate
Definition: GuildPackets.h:493
uint8 Tab
Definition: GuildPackets.h:491
std::vector< GuildBankTabInfo > TabInfo
Definition: GuildPackets.h:489
uint64 Money
Definition: GuildPackets.h:492
std::vector< GuildBankItemInfo > ItemInfo
Definition: GuildPackets.h:488
std::size_t wpos() const
Definition: ByteBuffer.h:330

References WorldPackets::Guild::GuildBankSocketEnchant::SocketEnchantID, and WorldPackets::Guild::GuildBankSocketEnchant::SocketIndex.

Referenced by Guild::_SendBankList().

Member Data Documentation

◆ _withdrawalsRemainingPos

std::size_t WorldPackets::Guild::GuildBankQueryResults::_withdrawalsRemainingPos = 0
private

◆ FullUpdate

bool WorldPackets::Guild::GuildBankQueryResults::FullUpdate = false

Referenced by Guild::_SendBankList().

◆ ItemInfo

std::vector<GuildBankItemInfo> WorldPackets::Guild::GuildBankQueryResults::ItemInfo

Referenced by Guild::_SendBankList().

◆ Money

uint64 WorldPackets::Guild::GuildBankQueryResults::Money = 0

Referenced by Guild::_SendBankList().

◆ Tab

uint8 WorldPackets::Guild::GuildBankQueryResults::Tab = 0

Referenced by Guild::_SendBankList().

◆ TabInfo

std::vector<GuildBankTabInfo> WorldPackets::Guild::GuildBankQueryResults::TabInfo

Referenced by Guild::_SendBankList().

◆ WithdrawalsRemaining

int32 WorldPackets::Guild::GuildBankQueryResults::WithdrawalsRemaining = 0

Referenced by Guild::_SendBankList().