Changed inventory lookups to always require a username

This commit is contained in:
Intelli 2022-03-21 16:42:30 -06:00
parent aea0c82fd7
commit 703d52bcc7

View File

@ -267,6 +267,11 @@ public class LookupCommand {
}
if (argAction.contains(4) && argAction.contains(11)) { // a:inventory
if (argUsers.size() == 0) {
Chat.sendMessage(player, Color.DARK_AQUA + "CoreProtect " + Color.WHITE + "- " + Phrase.build(Phrase.MISSING_ACTION_USER));
return;
}
argExclude.put(Material.FIRE, false);
argExclude.put(Material.WATER, false);
argExclude.put(Material.FARMLAND, false);
@ -572,6 +577,13 @@ public class LookupCommand {
}
}
c++;
if (argAction.contains(4) && argAction.contains(11)) {
if (ruser.startsWith("#")) {
Chat.sendMessage(player, Color.DARK_AQUA + "CoreProtect " + Color.WHITE + "- " + Phrase.build(Phrase.INVALID_USERNAME, ruser));
return;
}
}
}
long timeStart = -1;