From 13dfc7c173550c49ff6070176f8d0c4f3d270c8a Mon Sep 17 00:00:00 2001 From: rtm516 Date: Wed, 31 Jul 2024 01:06:26 +0100 Subject: [PATCH] Allow commands with xbox achievements enabled (#4894) * Allow commands with xbox achievements enabled * Don't enable by default * Add null check to paramData * Update comment --- .../translator/protocol/java/JavaCommandsTranslator.java | 6 +++--- core/src/main/resources/config.yml | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/core/src/main/java/org/geysermc/geyser/translator/protocol/java/JavaCommandsTranslator.java b/core/src/main/java/org/geysermc/geyser/translator/protocol/java/JavaCommandsTranslator.java index ecfb2d220..c0e3f5716 100644 --- a/core/src/main/java/org/geysermc/geyser/translator/protocol/java/JavaCommandsTranslator.java +++ b/core/src/main/java/org/geysermc/geyser/translator/protocol/java/JavaCommandsTranslator.java @@ -169,8 +169,8 @@ public class JavaCommandsTranslator extends PacketTranslator flags = Set.of(); + // The command flags, set to NOT_CHEAT so known commands can be used while achievements are enabled. + Set flags = Set.of(CommandData.Flag.NOT_CHEAT); // Loop through all the found commands for (Map.Entry> entry : commands.entrySet()) { @@ -449,7 +449,7 @@ public class JavaCommandsTranslator extends PacketTranslator