From ef9064c91ea9814348e6a9234bdfaaf540b5ece4 Mon Sep 17 00:00:00 2001 From: ReinforceZwei <39955851+ReinforceZwei@users.noreply.github.com> Date: Tue, 31 Mar 2020 20:36:45 +0800 Subject: [PATCH] Fix EntityHandling not disabled when version unsupported --- MinecraftClient/Protocol/Handlers/Protocol18.cs | 2 +- MinecraftClient/Protocol/IMinecraftComHandler.cs | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/MinecraftClient/Protocol/Handlers/Protocol18.cs b/MinecraftClient/Protocol/Handlers/Protocol18.cs index ba48921b..29ee3fe4 100644 --- a/MinecraftClient/Protocol/Handlers/Protocol18.cs +++ b/MinecraftClient/Protocol/Handlers/Protocol18.cs @@ -79,7 +79,7 @@ namespace MinecraftClient.Protocol.Handlers if(handler.GetEntityHandlingEnabled() && protocolversion < MC1122Version) { ConsoleIO.WriteLineFormatted("ยง8Entities are currently not handled for that MC version."); - handler.SetInventoryEnabled(false); + handler.SetEntityHandlingEnabled(false); } if (protocolversion >= MC113Version) diff --git a/MinecraftClient/Protocol/IMinecraftComHandler.cs b/MinecraftClient/Protocol/IMinecraftComHandler.cs index ecf87e7a..db7f5a02 100644 --- a/MinecraftClient/Protocol/IMinecraftComHandler.cs +++ b/MinecraftClient/Protocol/IMinecraftComHandler.cs @@ -32,6 +32,7 @@ namespace MinecraftClient.Protocol bool GetInventoryEnabled(); bool SetInventoryEnabled(bool enabled); bool GetEntityHandlingEnabled(); + bool SetEntityHandlingEnabled(bool enabled); /// /// Called when a server was successfully joined