diff options
Diffstat (limited to 'src/Protocol/Protocol_1_13.h')
-rw-r--r-- | src/Protocol/Protocol_1_13.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/Protocol/Protocol_1_13.h b/src/Protocol/Protocol_1_13.h index 6eace0567..34827501c 100644 --- a/src/Protocol/Protocol_1_13.h +++ b/src/Protocol/Protocol_1_13.h @@ -20,6 +20,13 @@ Declares the 1.13 protocol classes: +// fwd: +class BlockTypePalette; + + + + + class cProtocol_1_13 : public cProtocol_1_12_2 { @@ -28,8 +35,24 @@ class cProtocol_1_13 : public: cProtocol_1_13(cClientHandle * a_Client, const AString & a_ServerAddress, UInt16 a_ServerPort, UInt32 a_State); + virtual void Initialize(cClientHandle & a_Client) override; + + protected: + /** The palette used to transform internal block type palette into the protocol-specific ID. */ + std::shared_ptr<const BlockTypePalette> m_BlockTypePalette; + + /** Temporary hack for initial 1.13+ support while keeping BLOCKTYPE data: + Map of the BLOCKTYPE#META to the protocol-specific NetBlockID. */ + std::map<UInt32, UInt32> m_BlockTypeMap; + + + /** Returns the string identifying the palettes' version, such as "1.13" or "1.14.4". + The palettes for that version are loaded into m_BlockTypePalette and m_ItemTypePalette. */ + virtual AString GetPaletteVersion() const; + + // Outgoing packet type translation: virtual UInt32 GetPacketID(ePacketType a_PacketType) override; // Packet receiving: |