mirror of
https://github.com/kaboomserver/extras.git
synced 2025-01-08 23:48:14 +00:00
Prevent usage of @ selectors with spreadplayers (#294)
This commit is contained in:
parent
235d2c9788
commit
41b19fe6ea
1 changed files with 3 additions and 1 deletions
|
@ -155,7 +155,9 @@ public final class ServerCommand implements Listener {
|
||||||
break;
|
break;
|
||||||
case "/minecraft:spreadplayers":
|
case "/minecraft:spreadplayers":
|
||||||
case "/spreadplayers":
|
case "/spreadplayers":
|
||||||
if (arr.length >= 5) {
|
if (arr.length == 7 && arr[6].contains("@")) {
|
||||||
|
return "cancel";
|
||||||
|
} else if (arr.length >= 5) {
|
||||||
if (Double.parseDouble(arr[3]) > 0) {
|
if (Double.parseDouble(arr[3]) > 0) {
|
||||||
arr[3] = "0";
|
arr[3] = "0";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue