From cedb261313d4534ffebb940513129f6620df2020 Mon Sep 17 00:00:00 2001 From: Jesse Boyd Date: Wed, 17 Jul 2019 15:43:18 +1000 Subject: [PATCH] fix some Command annotations --- worldedit-core/build.gradle | 4 +- .../boydti/fawe/command/AnvilCommands.java | 114 +++---- .../com/boydti/fawe/command/CFICommands.java | 64 ++-- .../fawe/regions/general/plot/FaweTrim.java | 1 - .../worldedit/command/BrushCommands.java | 148 +++++---- .../command/BrushOptionsCommands.java | 136 ++++----- .../worldedit/command/ClipboardCommands.java | 8 +- .../worldedit/command/HistoryCommands.java | 5 +- .../sk89q/worldedit/command/MaskCommands.java | 230 ++++++-------- .../worldedit/command/OptionsCommands.java | 78 ++--- .../worldedit/command/PatternCommands.java | 287 +++++++----------- .../worldedit/command/RegionCommands.java | 81 ++--- .../worldedit/command/SchematicCommands.java | 6 +- .../command/SuperPickaxeCommands.java | 26 +- .../worldedit/command/TransformCommands.java | 68 ++--- .../worldedit/command/UtilityCommands.java | 7 +- 16 files changed, 524 insertions(+), 739 deletions(-) diff --git a/worldedit-core/build.gradle b/worldedit-core/build.gradle index a06223774..66072f1ee 100644 --- a/worldedit-core/build.gradle +++ b/worldedit-core/build.gradle @@ -65,8 +65,8 @@ processResources { version: "${project.parent.version}", name: project.parent.name, commit: "${git.head().abbreviatedId}", - date: "${git.head().getDate().format("yy.MM.dd")}", - ) + date: "${git.head().getDate().format("yy.MM.dd")}" +) } } diff --git a/worldedit-core/src/main/java/com/boydti/fawe/command/AnvilCommands.java b/worldedit-core/src/main/java/com/boydti/fawe/command/AnvilCommands.java index 489538bda..ee5a57d05 100644 --- a/worldedit-core/src/main/java/com/boydti/fawe/command/AnvilCommands.java +++ b/worldedit-core/src/main/java/com/boydti/fawe/command/AnvilCommands.java @@ -141,13 +141,11 @@ public class AnvilCommands { } @Command( - aliases = {"replaceall", "rea", "repall"}, - usage = " [from-block] ", + name = "replaceall", + aliases = {"rea", "repall"}, desc = "Replace all blocks in the selection with another", - help = "Replace all blocks in the selection with another\n" + - "The -d flag disabled wildcard data matching\n", - flags = "df" - ) + descFooter = "The -d flag disabled wildcard data matching\n" +) @CommandPermissions("worldedit.anvil.replaceall") public void replaceAll(Player player, String folder, @Optional String from, String to, @Switch('d') boolean useData) throws WorldEditException { // final FaweBlockMatcher matchFrom; @@ -166,9 +164,8 @@ public class AnvilCommands { } @Command( - aliases = {"remapall"}, - usage = "", - help = "Remap the world between MCPE/PC values", + name = "remapall", + descFooter = "Remap the world between MCPE/PC values", desc = "Remap the world between MCPE/PC values" ) @CommandPermissions("worldedit.anvil.remapall") @@ -185,10 +182,10 @@ public class AnvilCommands { @Command( - aliases = {"deleteallunvisited", "delunvisited" }, - usage = " [file-age=60000]", + name = "deleteallunvisited", + aliases = {"delunvisited" }, desc = "Delete all chunks which haven't been occupied", - help = "Delete all chunks which haven't been occupied for `age-ticks` (20t = 1s) and \n" + + descFooter = "occupied for `age-ticks` (20t = 1s) and \n" + "Have not been accessed since `file-duration` (ms) after creation and\n" + "Have not been used in the past `chunk-inactivity` (ms)" + "The auto-save interval is the recommended value for `file-duration` and `chunk-inactivity`" @@ -201,16 +198,15 @@ public class AnvilCommands { } @Command( - aliases = {"deleteallunclaimed", "delallunclaimed" }, - usage = " [file-age=60000]", - desc = "(Supports: WG, P2, GP) Delete all chunks which haven't been occupied AND claimed", - help = "(Supports: WG, P2, GP) Delete all chunks which aren't claimed AND haven't been occupied for `age-ticks` (20t = 1s) and \n" + + name = "deleteallunclaimed", + aliases = {"delallunclaimed" }, + desc = "Delete all chunks which haven't been occupied", + descFooter = "Supports: WG, P2, GP:\n" + + "Delete all chunks which aren't claimed AND haven't been occupied for `age-ticks` (20t = 1s) and \n" + "Have not been accessed since `file-duration` (ms) after creation and\n" + "Have not been used in the past `chunk-inactivity` (ms)" + - "The auto-save interval is the recommended value for `file-duration` and `chunk-inactivity`", - min = 1, - max = 3 - ) + "The auto-save interval is the recommended value for `file-duration` and `chunk-inactivity`" +) @CommandPermissions("worldedit.anvil.deleteallunclaimed") public void deleteAllUnclaimed(Player player, int inhabitedTicks, @Optional("60000") int fileDurationMillis, @Switch('d') boolean debug) throws WorldEditException { String folder = player.getWorld().getName(); @@ -222,15 +218,14 @@ public class AnvilCommands { @Command( name = "deleteunclaimed", - usage = " [file-age=60000]", - desc = "(Supports: WG, P2, GP) Delete all chunks which haven't been occupied AND claimed", - help = "(Supports: WG, P2, GP) Delete all chunks which aren't claimed AND haven't been occupied for `age-ticks` (20t = 1s) and \n" + + desc = "Delete all chunks which haven't been occupied", + descFooter = "(Supports: WG, P2, GP):\n" + + "Is not claimed\n" + + "Has not been occupied for `age-ticks` (20t = 1s) and \n" + "Have not been accessed since `file-duration` (ms) after creation and\n" + "Have not been used in the past `chunk-inactivity` (ms)" + - "The auto-save interval is the recommended value for `file-duration` and `chunk-inactivity`", - min = 1, - max = 3 - ) + "The auto-save interval is the recommended value for `file-duration` and `chunk-inactivity`" +) @CommandPermissions("worldedit.anvil.deleteunclaimed") public void deleteUnclaimed(Player player, EditSession editSession, @Selection Region selection, int inhabitedTicks, @Optional("60000") int fileDurationMillis, @Switch('d') boolean debug) throws WorldEditException { DeleteUnclaimedFilter filter = new DeleteUnclaimedFilter(player.getWorld(), fileDurationMillis, inhabitedTicks, fileDurationMillis); @@ -240,11 +235,10 @@ public class AnvilCommands { } @Command( - aliases = {"deletealloldregions", "deloldreg" }, - usage = "