Possible hotfix ChatListener

This commit is contained in:
2024-08-06 17:18:34 +02:00
parent b5a4daa483
commit 41c46264b7
@@ -89,8 +89,9 @@ public class ChatListener extends BasicListener {
cmdLogger.log(Level.INFO, "%s -> executed command /%s".formatted(name, command));
} else if (e.getCommandSource() instanceof Player player) {
System.out.println("spoofChatInput " + e);
player.spoofChatInput("/" + command);
e.setResult(CommandExecuteEvent.CommandResult.denied());
// player.spoofChatInput("/" + command);
// e.setResult(CommandExecuteEvent.CommandResult.denied());
e.setResult(CommandExecuteEvent.CommandResult.forwardToServer(e.getCommand()));
}
}