mirror of
https://github.com/darksaid98/AntiCheatReloaded.git
synced 2026-12-03 14:38:46 +00:00
Send help message on command not found
This commit is contained in:
1 parent
9154ef3370
commit
bef1c8de6e
2 files changed
+4
-1
No files matched your search
@@ -373,7 +373,7 @@ public class Backend {
|
|||||||
if (isInWater.contains(player.getName())) {
|
if (isInWater.contains(player.getName())) {
|
||||||
if (isInWaterCache.contains(player.getName())) {
|
if (isInWaterCache.contains(player.getName())) {
|
||||||
if (player.getNearbyEntities(1, 1, 1).isEmpty()) {
|
if (player.getNearbyEntities(1, 1, 1).isEmpty()) {
|
||||||
boolean b = false;
|
boolean b;
|
||||||
if (!Utilities.sprintFly(player)) {
|
if (!Utilities.sprintFly(player)) {
|
||||||
b = x > magic.XZ_SPEED_MAX_WATER || z > magic.XZ_SPEED_MAX_WATER;
|
b = x > magic.XZ_SPEED_MAX_WATER || z > magic.XZ_SPEED_MAX_WATER;
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
@@ -57,8 +57,11 @@ public class CommandHandler implements CommandExecutor {
|
|||||||
for (CommandBase base : commands) {
|
for (CommandBase base : commands) {
|
||||||
if (base.getCommand().equalsIgnoreCase(command)) {
|
if (base.getCommand().equalsIgnoreCase(command)) {
|
||||||
base.run(cs, newArgs);
|
base.run(cs, newArgs);
|
||||||
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// Command not found, send help
|
||||||
|
commands.get(0).run(cs, null);
|
||||||
} else {
|
} else {
|
||||||
// Send help
|
// Send help
|
||||||
commands.get(0).run(cs, null);
|
commands.get(0).run(cs, null);
|
||||||
|
|||||||
Reference in new issue
Block a user