diff --git a/proxy/src/main/java/com/velocitypowered/proxy/command/builtin/SendCommand.java b/proxy/src/main/java/com/velocitypowered/proxy/command/builtin/SendCommand.java index 85df6a704..c4916c2cd 100644 --- a/proxy/src/main/java/com/velocitypowered/proxy/command/builtin/SendCommand.java +++ b/proxy/src/main/java/com/velocitypowered/proxy/command/builtin/SendCommand.java @@ -84,8 +84,14 @@ public class SendCommand { ArgumentCommandNode serverNode = RequiredArgumentBuilder .argument("server", StringArgumentType.word()) .suggests((context, builder) -> { + String argument = context.getArguments().containsKey(SERVER_ARG) + ? context.getArgument(SERVER_ARG, String.class) + : ""; for (RegisteredServer server : server.registeredServers()) { - builder.suggest(server.serverInfo().name()); + String serverName = server.serverInfo().name(); + if (serverName.regionMatches(true, 0, argument, 0, argument.length())) { + builder.suggest(server.serverInfo().name()); + } } return builder.buildFuture(); })