Merging upstream changes

This commit is contained in:
matt
2019-03-26 13:27:09 -04:00
parent 85bfd16d7c
commit 0d88a6bce2
23 changed files with 1708 additions and 1768 deletions

View File

@ -53,9 +53,9 @@ public class GeneralCommands {
@Command(
aliases = { "/limit" },
usage = "<limit>",
usage = "[limit]",
desc = "Modify block change limit",
min = 1,
min = 0,
max = 1
)
@CommandPermissions("worldedit.limit")
@ -64,7 +64,7 @@ public class GeneralCommands {
LocalConfiguration config = worldEdit.getConfiguration();
boolean mayDisable = player.hasPermission("worldedit.limit.unrestricted");
int limit = Math.max(-1, args.getInteger(0));
int limit = args.argsLength() == 0 ? config.defaultChangeLimit : Math.max(-1, args.getInteger(0));
if (!mayDisable && config.maxChangeLimit > -1) {
if (limit > config.maxChangeLimit) {
player.printError("Your maximum allowable limit is " + config.maxChangeLimit + ".");
@ -164,7 +164,7 @@ public class GeneralCommands {
boolean blocksOnly = args.hasFlag('b');
boolean itemsOnly = args.hasFlag('i');
ItemType type = ItemTypes.parse(query);
ItemType type = ItemTypes.get(query);
if (type != null) {
actor.print(type.getId() + " (" + type.getName() + ")");