Mineserver
A rewrite of Minecraft 1.8.9 in C++ !
Loading...
Searching...
No Matches
disconnect.h
Go to the documentation of this file.
1
12#ifndef MINESERVER_DISCONNECT_H
13#define MINESERVER_DISCONNECT_H
14
15#include <net/packet.h>
16
24class DisconnectPlay : public IPacket
25{
26private:
27 void write(IMCStream *stream) override;
28
29public:
36
42
49 void read(IMCStream *stream) override;
50
57 static void loadLua(lua_State *state, const char *baseNamespaceName);
58};
59
68{
69private:
70 void write(IMCStream *stream) override;
71
72public:
79
85
92 void read(IMCStream *stream) override;
93
100 static void loadLua(lua_State *state, const char *baseNamespaceName);
101};
102
103#endif // MINESERVER_DISCONNECT_H
Minecraft Chat Message implementation.
Definition chatmessage.h:28
Disconnect Packet for Login state.
Definition disconnect.h:68
void read(IMCStream *stream) override
Reads the packet from the stream.
Definition disconnect.cpp:19
ChatMessage reason
the reason for the disconnection
Definition disconnect.h:84
DisconnectLogin(const ChatMessage &reason)
Construct a new Disconnect Login object.
Definition disconnect.h:78
static void loadLua(lua_State *state, const char *baseNamespaceName)
Loads packet as lua class.
Definition disconnect.cpp:26
Disconnect Packet for Play state.
Definition disconnect.h:25
static void loadLua(lua_State *state, const char *baseNamespaceName)
Loads packet as lua class.
Definition disconnect.cpp:49
void read(IMCStream *stream) override
Reads the packet from the stream.
Definition disconnect.cpp:42
ChatMessage reason
The reason for the disconnection.
Definition disconnect.h:41
DisconnectPlay(const ChatMessage &reason)
Construct a new Disconnect Play object.
Definition disconnect.h:35
Stream interface.
Definition stream.h:32
Interface for all Packets.
Definition packet.h:25
The file containing the packet data.