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

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

#include <TransmittedPackets.hpp>

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

Public Member Functions

 ZC_NOTIFY_CARTITEM_COUNTINFO (std::shared_ptr< ZoneSession > s)
 
virtual ~ZC_NOTIFY_CARTITEM_COUNTINFO ()
 
void deliver (int unique_items, int max_cart_items, int cart_weight, int cart_weight_max)
 ZC_NOTIFY_CARTITEM_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 _unique_items { 0 }
 
int16_t _max_cart_items { 0 }
 
int32_t _cart_weight { 0 }
 
int32_t _cart_weight_max { 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_CARTITEM_COUNTINFO.

Constructor & Destructor Documentation

◆ ZC_NOTIFY_CARTITEM_COUNTINFO()

Horizon::Zone::ZC_NOTIFY_CARTITEM_COUNTINFO::ZC_NOTIFY_CARTITEM_COUNTINFO ( std::shared_ptr< ZoneSession s)
inline
32310 : NetworkPacket<ZoneSession>(ID_ZC_NOTIFY_CARTITEM_COUNTINFO, s)
32311 {}
@ ID_ZC_NOTIFY_CARTITEM_COUNTINFO
Definition: TransmittedPackets.hpp:32283

◆ ~ZC_NOTIFY_CARTITEM_COUNTINFO()

virtual Horizon::Zone::ZC_NOTIFY_CARTITEM_COUNTINFO::~ZC_NOTIFY_CARTITEM_COUNTINFO ( )
inlinevirtual
32312{}

Member Function Documentation

◆ deliver()

void ZC_NOTIFY_CARTITEM_COUNTINFO::deliver ( int  unique_items,
int  max_cart_items,
int  cart_weight,
int  cart_weight_max 
)

ZC_NOTIFY_CARTITEM_COUNTINFO.

1917{
1918 _unique_items = unique_items;
1919 _max_cart_items = max_cart_items;
1920 _cart_weight = cart_weight;
1921 _cart_weight_max = cart_weight_max;
1922
1923 serialize();
1924 transmit();
1925}
void transmit()
Send an Asynchronous packet by queueing a buffer of a particular size to the connected session.
Definition: NetworkPacket.hpp:94
ByteBuffer & serialize()
Definition: TransmittedPackets.cpp:1926
int16_t _unique_items
Definition: TransmittedPackets.hpp:32318
int16_t _max_cart_items
Definition: TransmittedPackets.hpp:32319
int32_t _cart_weight
Definition: TransmittedPackets.hpp:32320
int32_t _cart_weight_max
Definition: TransmittedPackets.hpp:32321

References _cart_weight, _cart_weight_max, _max_cart_items, _unique_items, serialize(), and Horizon::Base::NetworkPacket< ZoneSession >::transmit().

+ Here is the call graph for this function:

◆ serialize()

ByteBuffer & ZC_NOTIFY_CARTITEM_COUNTINFO::serialize ( )
1927{
1928 buf() << _packet_id;
1929 buf() << _unique_items;
1930 buf() << _max_cart_items;
1931 buf() << _cart_weight;
1932 buf() << _cart_weight_max;
1933 return buf();
1934}
uint16_t _packet_id
ID of the network packet.
Definition: NetworkPacket.hpp:87
ByteBuffer & buf()
Definition: NetworkPacket.hpp:59

References _cart_weight, _cart_weight_max, _max_cart_items, Horizon::Base::NetworkPacket< ZoneSession >::_packet_id, _unique_items, 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

◆ _cart_weight

int32_t Horizon::Zone::ZC_NOTIFY_CARTITEM_COUNTINFO::_cart_weight { 0 }

Referenced by deliver(), and serialize().

◆ _cart_weight_max

int32_t Horizon::Zone::ZC_NOTIFY_CARTITEM_COUNTINFO::_cart_weight_max { 0 }

Referenced by deliver(), and serialize().

◆ _max_cart_items

int16_t Horizon::Zone::ZC_NOTIFY_CARTITEM_COUNTINFO::_max_cart_items { 0 }

Referenced by deliver(), and serialize().

◆ _unique_items

int16_t Horizon::Zone::ZC_NOTIFY_CARTITEM_COUNTINFO::_unique_items { 0 }

Referenced by deliver(), and serialize().


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