2012-02-07 15:49:52 -05:00
|
|
|
|
2011-11-02 16:40:39 -04:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "cPacket.h"
|
2012-01-27 09:04:28 -05:00
|
|
|
|
2011-11-02 16:40:39 -04:00
|
|
|
|
|
|
|
|
2012-02-07 15:49:52 -05:00
|
|
|
|
|
|
|
|
2011-11-02 16:40:39 -04:00
|
|
|
class cPacket_NewInvalidState : public cPacket
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
cPacket_NewInvalidState()
|
|
|
|
: m_Reason( 0 )
|
|
|
|
, m_GameMode( 0 )
|
|
|
|
{ m_PacketID = E_NEW_INVALID_STATE;}
|
|
|
|
cPacket_NewInvalidState( const cPacket_NewInvalidState & a_Copy );
|
|
|
|
virtual cPacket* Clone() const { return new cPacket_NewInvalidState(*this); }
|
|
|
|
|
2012-08-17 06:18:07 -04:00
|
|
|
virtual int Parse(cByteBuffer & a_Buffer) override;
|
2012-02-07 15:49:52 -05:00
|
|
|
virtual void Serialize(AString & a_Data) const override;
|
2011-11-02 16:40:39 -04:00
|
|
|
|
|
|
|
char m_Reason; // 0 = Invalid Bed, 1 = Begin Raining, 2 End Raining, 3 = Change Gamemode
|
|
|
|
char m_GameMode; // Used only when reason = 3. 0 is survival, 1 is creative.
|
|
|
|
|
|
|
|
static const unsigned int c_Size = 1 + 1 + 1;
|
|
|
|
};
|
2012-02-07 15:49:52 -05:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|