summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/Protocol/Protocol17x.h2
-rw-r--r--src/Protocol/Protocol18x.cpp17
-rw-r--r--src/Protocol/Protocol18x.h3
3 files changed, 20 insertions, 2 deletions
diff --git a/src/Protocol/Protocol17x.h b/src/Protocol/Protocol17x.h
index 1e716a761..f056f262a 100644
--- a/src/Protocol/Protocol17x.h
+++ b/src/Protocol/Protocol17x.h
@@ -289,7 +289,7 @@ protected:
virtual void HandlePacketPluginMessage (cByteBuffer & a_ByteBuffer);
void HandlePacketSlotSelect (cByteBuffer & a_ByteBuffer);
virtual void HandlePacketSteerVehicle (cByteBuffer & a_ByteBuffer);
- void HandlePacketTabComplete (cByteBuffer & a_ByteBuffer);
+ virtual void HandlePacketTabComplete (cByteBuffer & a_ByteBuffer);
void HandlePacketUpdateSign (cByteBuffer & a_ByteBuffer);
virtual void HandlePacketUseEntity (cByteBuffer & a_ByteBuffer);
void HandlePacketEnchantItem (cByteBuffer & a_ByteBuffer);
diff --git a/src/Protocol/Protocol18x.cpp b/src/Protocol/Protocol18x.cpp
index ffa8d5ecb..eebac7a05 100644
--- a/src/Protocol/Protocol18x.cpp
+++ b/src/Protocol/Protocol18x.cpp
@@ -1132,3 +1132,20 @@ void cProtocol180::HandlePacketBlockDig(cByteBuffer & a_ByteBuffer)
+
+void cProtocol180::HandlePacketTabComplete(cByteBuffer & a_ByteBuffer)
+{
+ HANDLE_READ(a_ByteBuffer, ReadVarUTF8String, AString, Text);
+ HANDLE_READ(a_ByteBuffer, ReadBool, bool, HasPosition);
+
+ if (HasPosition)
+ {
+ HANDLE_READ(a_ByteBuffer, ReadBEInt64, Int64, Position);
+ }
+
+ m_Client->HandleTabCompletion(Text);
+}
+
+
+
+
diff --git a/src/Protocol/Protocol18x.h b/src/Protocol/Protocol18x.h
index dc3739369..a3478e674 100644
--- a/src/Protocol/Protocol18x.h
+++ b/src/Protocol/Protocol18x.h
@@ -112,7 +112,8 @@ protected:
virtual void HandlePacketPlayerPosLook(cByteBuffer & a_ByteBuffer) override;
virtual void HandlePacketClientSettings(cByteBuffer & a_ByteBuffer) override;
virtual void HandlePacketBlockPlace(cByteBuffer & a_ByteBuffer) override;
- virtual void HandlePacketBlockDig(cByteBuffer & a_ByteBuffer);
+ virtual void HandlePacketBlockDig(cByteBuffer & a_ByteBuffer)override;
+ virtual void HandlePacketTabComplete(cByteBuffer & a_ByteBuffer) override;
} ;