Cuberite
A lightweight, fast and extensible game server for Minecraft
Classes | Macros
Packetizer.h File Reference
#include "Protocol.h"
Include dependency graph for Packetizer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  cPacketizer
 Composes an individual packet in the protocol's m_OutPacketBuffer; sends it just before being destructed. More...
 

Macros

#define HANDLE_PACKET_READ(ByteBuf, Proc, Type, Var)
 
#define HANDLE_READ(ByteBuf, Proc, Type, Var)
 Macros used to read packets more easily. More...
 

Macro Definition Documentation

◆ HANDLE_PACKET_READ

#define HANDLE_PACKET_READ (   ByteBuf,
  Proc,
  Type,
  Var 
)
Value:
Type Var; \
do { \
{ \
if (!ByteBuf.Proc(Var)) \
{ \
ByteBuf.CheckValid(); \
return false; \
} \
ByteBuf.CheckValid(); \
} \
} while (false)

Definition at line 41 of file Packetizer.h.

◆ HANDLE_READ

#define HANDLE_READ (   ByteBuf,
  Proc,
  Type,
  Var 
)
Value:
Type Var; \
do { \
if (!ByteBuf.Proc(Var))\
{\
return;\
} \
} while (false)

Macros used to read packets more easily.

Definition at line 28 of file Packetizer.h.