From 1cd903e3d491e20fd81a6cd976c1c144600c5a66 Mon Sep 17 00:00:00 2001 From: Allink Date: Mon, 10 Apr 2023 20:47:10 +0100 Subject: [PATCH] Make distance selector stricter --- .../java/pw/kaboom/extras/modules/server/ServerCommand.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/pw/kaboom/extras/modules/server/ServerCommand.java b/src/main/java/pw/kaboom/extras/modules/server/ServerCommand.java index 328cd29..7c9f3d0 100644 --- a/src/main/java/pw/kaboom/extras/modules/server/ServerCommand.java +++ b/src/main/java/pw/kaboom/extras/modules/server/ServerCommand.java @@ -20,7 +20,7 @@ public final class ServerCommand implements Listener { private static final Pattern AS_AT_PATTERN = Pattern.compile( "\\b(as|at|facing entity) @[ae]\\b"); private static final Pattern DISTANCE_SELECTOR_PATTERN = Pattern.compile( - "[\"']?distance[\"']?\\s*=\\s*"); + "@[aeprs]\\[[\"']?distance[\"']?\\s*=\\s*"); private static final Logger LOGGER = JavaPlugin.getPlugin(Main.class).getLogger(); public static boolean checkExecuteCommand(final String cmd) {