Horizon Official Technical Documentation
Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO Class Reference

Main object for the aegis packet: ZC_NOTIFY_STOREITEM_COUNTINFO. More...

#include <TransmittedPackets.hpp>

+ Inheritance diagram for Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO:
+ Collaboration diagram for Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO:

Public Member Functions

 ZC_NOTIFY_STOREITEM_COUNTINFO (std::shared_ptr< ZoneSession > s)
 
virtual ~ZC_NOTIFY_STOREITEM_COUNTINFO ()
 
void deliver (int16_t current_amount, int16_t max_amount)
 ZC_NOTIFY_STOREITEM_COUNTINFO. More...
 
ByteBufferserialize ()
 
- Public Member Functions inherited from Horizon::Base::NetworkPacket< ZoneSession >
 NetworkPacket (uint16_t packet_id, std::shared_ptr< ZoneSession > s)
 
virtual ~NetworkPacket ()
 
void set_packet_id (uint16_t id)
 
uint16_t get_packet_id ()
 
ByteBufferbuf ()
 
std::shared_ptr< ZoneSession > get_session ()
 Retrieves the session from this handler instance. More...
 
virtual void handle (ByteBuffer &&buf)
 
virtual void deserialize (ByteBuffer &buf)
 
void transmit ()
 Send an Asynchronous packet by queueing a buffer of a particular size to the connected session. More...
 
void transmit (std::size_t size)
 Send an Asynchronous packet by queueing a buffer of a particular size to the connected session. More...
 

Public Attributes

int16_t _current_amount { 0 }
 
int16_t _max_amount { 0 }
 

Additional Inherited Members

- Protected Attributes inherited from Horizon::Base::NetworkPacket< ZoneSession >
ByteBuffer _buffer
 Buffer storage facility for the packet stream. More...
 
uint16_t _packet_id
 ID of the network packet. More...
 

Detailed Description

Main object for the aegis packet: ZC_NOTIFY_STOREITEM_COUNTINFO.

Constructor & Destructor Documentation

◆ ZC_NOTIFY_STOREITEM_COUNTINFO()

Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO::ZC_NOTIFY_STOREITEM_COUNTINFO ( std::shared_ptr< ZoneSession s)
inline
35134 : NetworkPacket<ZoneSession>(ID_ZC_NOTIFY_STOREITEM_COUNTINFO, s)
35135 {}
@ ID_ZC_NOTIFY_STOREITEM_COUNTINFO
Definition: TransmittedPackets.hpp:35107

◆ ~ZC_NOTIFY_STOREITEM_COUNTINFO()

virtual Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO::~ZC_NOTIFY_STOREITEM_COUNTINFO ( )
inlinevirtual
35136{}

Member Function Documentation

◆ deliver()

void ZC_NOTIFY_STOREITEM_COUNTINFO::deliver ( int16_t  current_amount,
int16_t  max_amount 
)

ZC_NOTIFY_STOREITEM_COUNTINFO.

2252{
2253 _current_amount = current_amount;
2254 _max_amount = max_amount;
2255
2256 serialize();
2257 transmit();
2258}
void transmit()
Send an Asynchronous packet by queueing a buffer of a particular size to the connected session.
Definition: NetworkPacket.hpp:94
int16_t _current_amount
Definition: TransmittedPackets.hpp:35142
int16_t _max_amount
Definition: TransmittedPackets.hpp:35143
ByteBuffer & serialize()
Definition: TransmittedPackets.cpp:2259

References _current_amount, _max_amount, serialize(), and Horizon::Base::NetworkPacket< ZoneSession >::transmit().

Referenced by Horizon::Zone::ZoneClientInterface::notify_storage_size().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ serialize()

ByteBuffer & ZC_NOTIFY_STOREITEM_COUNTINFO::serialize ( )
2260{
2261 buf() << _packet_id;
2262 buf() << _current_amount;
2263 buf() << _max_amount;
2264 return buf();
2265}
uint16_t _packet_id
ID of the network packet.
Definition: NetworkPacket.hpp:87
ByteBuffer & buf()
Definition: NetworkPacket.hpp:59

References _current_amount, _max_amount, Horizon::Base::NetworkPacket< ZoneSession >::_packet_id, and Horizon::Base::NetworkPacket< ZoneSession >::buf().

Referenced by deliver().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ _current_amount

int16_t Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO::_current_amount { 0 }

Referenced by deliver(), and serialize().

◆ _max_amount

int16_t Horizon::Zone::ZC_NOTIFY_STOREITEM_COUNTINFO::_max_amount { 0 }

Referenced by deliver(), and serialize().


The documentation for this class was generated from the following files: