3
0
Mirror von https://github.com/IntellectualSites/FastAsyncWorldEdit.git synchronisiert 2024-11-09 21:10:05 +01:00
- Fixed a few warnings
- Unified the formatting of the command prologue
- Put down why it was deprecated in the javadoc of a deprecated method.
- Gave //none a better usage line
- Switchcaseified some elseifs
Dieser Commit ist enthalten in:
TomyLobo 2011-09-19 07:14:43 +02:00
Ursprung 43809a705d
Commit 88b4f4de18
20 geänderte Dateien mit 273 neuen und 256 gelöschten Zeilen

Datei anzeigen

@ -22,9 +22,7 @@ package com.sk89q.worldedit;
import java.util.Random; import java.util.Random;
import com.sk89q.worldedit.blocks.BaseBlock; import com.sk89q.worldedit.blocks.BaseBlock;
import com.sk89q.worldedit.blocks.BaseItemStack; import com.sk89q.worldedit.blocks.BaseItemStack;
import com.sk89q.worldedit.blocks.BlockID;
import com.sk89q.worldedit.blocks.BlockType; import com.sk89q.worldedit.blocks.BlockType;
import com.sk89q.worldedit.blocks.ItemType;
import com.sk89q.worldedit.regions.Region; import com.sk89q.worldedit.regions.Region;
/** /**

Datei anzeigen

@ -728,6 +728,7 @@ public enum BlockType {
* *
* @param id * @param id
* @return * @return
* @deprecated This function ignores the data value.
*/ */
@Deprecated @Deprecated
public static int getDroppedBlock(int id) { public static int getDroppedBlock(int id) {

Datei anzeigen

@ -50,14 +50,14 @@ import com.sk89q.worldedit.tools.brushes.SphereBrush;
*/ */
public class BrushCommands { public class BrushCommands {
@Command( @Command(
aliases = {"sphere", "s"}, aliases = { "sphere", "s" },
usage = "<block> [radius]", usage = "<block> [radius]",
flags = "h", flags = "h",
desc = "Choose the sphere brush", desc = "Choose the sphere brush",
min = 1, min = 1,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.brush.sphere"}) @CommandPermissions("worldedit.brush.sphere")
public static void sphereBrush(CommandContext args, WorldEdit we, public static void sphereBrush(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -87,14 +87,14 @@ public class BrushCommands {
} }
@Command( @Command(
aliases = {"cylinder", "cyl", "c"}, aliases = { "cylinder", "cyl", "c" },
usage = "<block> [radius] [height]", usage = "<block> [radius] [height]",
flags = "h", flags = "h",
desc = "Choose the cylinder brush", desc = "Choose the cylinder brush",
min = 1, min = 1,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.brush.cylinder"}) @CommandPermissions("worldedit.brush.cylinder")
public static void cylinderBrush(CommandContext args, WorldEdit we, public static void cylinderBrush(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -131,14 +131,14 @@ public class BrushCommands {
} }
@Command( @Command(
aliases = {"clipboard", "copy"}, aliases = { "clipboard", "copy" },
usage = "", usage = "",
flags = "a", flags = "a",
desc = "Choose the clipboard brush", desc = "Choose the clipboard brush",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.brush.clipboard"}) @CommandPermissions("worldedit.brush.clipboard")
public static void clipboardBrush(CommandContext args, WorldEdit we, public static void clipboardBrush(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -169,14 +169,14 @@ public class BrushCommands {
} }
@Command( @Command(
aliases = {"smooth"}, aliases = { "smooth" },
usage = "[size] [iterations]", usage = "[size] [iterations]",
flags = "n", flags = "n",
desc = "Choose the terrain softener brush", desc = "Choose the terrain softener brush",
min = 0, min = 0,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.brush.smooth"}) @CommandPermissions("worldedit.brush.smooth")
public static void smoothBrush(CommandContext args, WorldEdit we, public static void smoothBrush(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -201,13 +201,13 @@ public class BrushCommands {
} }
@Command( @Command(
aliases = {"ex", "extinguish"}, aliases = { "ex", "extinguish" },
usage = "[radius]", usage = "[radius]",
desc = "Shortcut fire extinguisher brush", desc = "Shortcut fire extinguisher brush",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.brush.ex"}) @CommandPermissions("worldedit.brush.ex")
public static void extinguishBrush(CommandContext args, WorldEdit we, public static void extinguishBrush(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -37,13 +37,13 @@ import com.sk89q.worldedit.data.McRegionChunkStore;
*/ */
public class ChunkCommands { public class ChunkCommands {
@Command( @Command(
aliases = {"chunkinfo"}, aliases = { "chunkinfo" },
usage = "", usage = "",
desc = "Get information about the chunk that you are inside", desc = "Get information about the chunk that you are inside",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.chunkinfo"}) @CommandPermissions("worldedit.chunkinfo")
public static void chunkInfo(CommandContext args, WorldEdit we, public static void chunkInfo(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -64,13 +64,13 @@ public class ChunkCommands {
} }
@Command( @Command(
aliases = {"listchunks"}, aliases = { "listchunks" },
usage = "", usage = "",
desc = "List chunks that your selection includes", desc = "List chunks that your selection includes",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.listchunks"}) @CommandPermissions("worldedit.listchunks")
public static void listChunks(CommandContext args, WorldEdit we, public static void listChunks(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -83,13 +83,13 @@ public class ChunkCommands {
} }
@Command( @Command(
aliases = {"delchunks"}, aliases = { "delchunks" },
usage = "", usage = "",
desc = "Delete chunks that your selection includes", desc = "Delete chunks that your selection includes",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.delchunks"}) @CommandPermissions("worldedit.delchunks")
@Logging(REGION) @Logging(REGION)
public static void deleteChunks(CommandContext args, WorldEdit we, public static void deleteChunks(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)

Datei anzeigen

@ -39,13 +39,13 @@ import com.sk89q.worldedit.regions.Region;
*/ */
public class ClipboardCommands { public class ClipboardCommands {
@Command( @Command(
aliases = {"/copy"}, aliases = { "/copy" },
usage = "", usage = "",
desc = "Copy the selection to the clipboard", desc = "Copy the selection to the clipboard",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.clipboard.copy"}) @CommandPermissions("worldedit.clipboard.copy")
public static void copy(CommandContext args, WorldEdit we, public static void copy(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -65,13 +65,13 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"/cut"}, aliases = { "/cut" },
usage = "[leave-id]", usage = "[leave-id]",
desc = "Cut the selection to the clipboard", desc = "Cut the selection to the clipboard",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.clipboard.cut"}) @CommandPermissions("worldedit.clipboard.cut")
@Logging(REGION) @Logging(REGION)
public static void cut(CommandContext args, WorldEdit we, public static void cut(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -99,14 +99,14 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"/paste"}, aliases = { "/paste" },
usage = "", usage = "",
flags = "ao", flags = "ao",
desc = "Paste the clipboard's contents", desc = "Paste the clipboard's contents",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.clipboard.paste"}) @CommandPermissions("worldedit.clipboard.paste")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void paste(CommandContext args, WorldEdit we, public static void paste(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -129,13 +129,13 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"/rotate"}, aliases = { "/rotate" },
usage = "<angle-in-degrees>", usage = "<angle-in-degrees>",
desc = "Rotate the contents of the clipboard", desc = "Rotate the contents of the clipboard",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.clipboard.rotate"}) @CommandPermissions("worldedit.clipboard.rotate")
public static void rotate(CommandContext args, WorldEdit we, public static void rotate(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -152,14 +152,14 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"/flip"}, aliases = { "/flip" },
usage = "[dir]", usage = "[dir]",
flags = "p", flags = "p",
desc = "Flip the contents of the clipboard.", desc = "Flip the contents of the clipboard.",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.clipboard.flip"}) @CommandPermissions("worldedit.clipboard.flip")
public static void flip(CommandContext args, WorldEdit we, public static void flip(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -173,13 +173,13 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"/load"}, aliases = { "/load" },
usage = "<filename>", usage = "<filename>",
desc = "Load a schematic into your clipboard", desc = "Load a schematic into your clipboard",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.clipboard.load"}) @CommandPermissions("worldedit.clipboard.load")
public static void load(CommandContext args, WorldEdit we, public static void load(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -210,13 +210,13 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"/save"}, aliases = { "/save" },
usage = "<filename>", usage = "<filename>",
desc = "Save a schematic into your clipboard", desc = "Save a schematic into your clipboard",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.clipboard.save"}) @CommandPermissions("worldedit.clipboard.save")
public static void save(CommandContext args, WorldEdit we, public static void save(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -254,13 +254,13 @@ public class ClipboardCommands {
} }
@Command( @Command(
aliases = {"clearclipboard"}, aliases = { "clearclipboard" },
usage = "", usage = "",
desc = "Clear your clipboard", desc = "Clear your clipboard",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.clipboard.clear"}) @CommandPermissions("worldedit.clipboard.clear")
public static void clearClipboard(CommandContext args, WorldEdit we, public static void clearClipboard(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -34,13 +34,13 @@ import com.sk89q.worldedit.masks.Mask;
*/ */
public class GeneralCommands { public class GeneralCommands {
@Command( @Command(
aliases = {"/limit"}, aliases = { "/limit" },
usage = "<limit>", usage = "<limit>",
desc = "Modify block change limit", desc = "Modify block change limit",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.limit"}) @CommandPermissions("worldedit.limit")
public static void limit(CommandContext args, WorldEdit we, public static void limit(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -62,13 +62,13 @@ public class GeneralCommands {
} }
@Command( @Command(
aliases = {"/fast"}, aliases = { "/fast" },
usage = "", usage = "",
desc = "Toggle fast mode", desc = "Toggle fast mode",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.fast"}) @CommandPermissions("worldedit.fast")
public static void fast(CommandContext args, WorldEdit we, public static void fast(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -83,13 +83,13 @@ public class GeneralCommands {
} }
@Command( @Command(
aliases = {"/gmask", "gmask"}, aliases = { "/gmask", "gmask" },
usage = "[mask]", usage = "[mask]",
desc = "Set the global mask", desc = "Set the global mask",
min = 0, min = 0,
max = -1 max = -1
) )
@CommandPermissions({"worldedit.global-mask"}) @CommandPermissions("worldedit.global-mask")
public static void mask(CommandContext args, WorldEdit we, public static void mask(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -104,7 +104,7 @@ public class GeneralCommands {
} }
@Command( @Command(
aliases = {"/toggleplace", "toggleplace"}, aliases = { "/toggleplace", "toggleplace" },
usage = "", usage = "",
desc = "Switch between your position and pos1 for placement", desc = "Switch between your position and pos1 for placement",
min = 0, min = 0,
@ -122,7 +122,7 @@ public class GeneralCommands {
} }
@Command( @Command(
aliases = {"/searchitem", "/l", "/search", "searchitem", "search"}, aliases = { "/searchitem", "/l", "/search", "searchitem", "search" },
usage = "<query>", usage = "<query>",
flags = "bi", flags = "bi",
desc = "Search for an item", desc = "Search for an item",
@ -199,10 +199,10 @@ public class GeneralCommands {
} }
@Command( @Command(
aliases = {"we", "worldedit"}, aliases = { "we", "worldedit" },
desc = "WorldEdit commands" desc = "WorldEdit commands"
) )
@NestedCommand({WorldEditCommands.class}) @NestedCommand(WorldEditCommands.class)
public static void we(CommandContext args, WorldEdit we, public static void we(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -35,13 +35,13 @@ import com.sk89q.worldedit.util.TreeGenerator;
*/ */
public class GenerationCommands { public class GenerationCommands {
@Command( @Command(
aliases = {"/hcyl"}, aliases = { "/hcyl" },
usage = "<block> <radius> [height]", usage = "<block> <radius> [height]",
desc = "Generate a hollow cylinder", desc = "Generate a hollow cylinder",
min = 2, min = 2,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.generation.cylinder"}) @CommandPermissions("worldedit.generation.cylinder")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void hcyl(CommandContext args, WorldEdit we, public static void hcyl(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -57,13 +57,13 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"/cyl"}, aliases = { "/cyl" },
usage = "<block> <radius> [height]", usage = "<block> <radius> [height]",
desc = "Generate a cylinder", desc = "Generate a cylinder",
min = 2, min = 2,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.generation.cylinder"}) @CommandPermissions("worldedit.generation.cylinder")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void cyl(CommandContext args, WorldEdit we, public static void cyl(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -79,14 +79,14 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"/hsphere"}, aliases = { "/hsphere" },
usage = "<block> <radius>[,<radius>,<radius>] [raised?]", usage = "<block> <radius>[,<radius>,<radius>] [raised?]",
desc = "Generate a hollow sphere.", desc = "Generate a hollow sphere.",
flags = "q", flags = "q",
min = 2, min = 2,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.generation.sphere"}) @CommandPermissions("worldedit.generation.sphere")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void hsphere(CommandContext args, WorldEdit we, public static void hsphere(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -151,14 +151,14 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"/sphere"}, aliases = { "/sphere" },
usage = "<block> <radius>[,<radius>,<radius>] [raised?]", usage = "<block> <radius>[,<radius>,<radius>] [raised?]",
desc = "Generate a filled sphere.", desc = "Generate a filled sphere.",
flags = "q", flags = "q",
min = 2, min = 2,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.generation.sphere"}) @CommandPermissions("worldedit.generation.sphere")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void sphere(CommandContext args, WorldEdit we, public static void sphere(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -223,13 +223,13 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"forestgen"}, aliases = { "forestgen" },
usage = "[size] [type] [density]", usage = "[size] [type] [density]",
desc = "Generate a forest", desc = "Generate a forest",
min = 0, min = 0,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.generation.forest"}) @CommandPermissions("worldedit.generation.forest")
@Logging(POSITION) @Logging(POSITION)
public static void forestGen(CommandContext args, WorldEdit we, public static void forestGen(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -252,13 +252,13 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"pumpkins"}, aliases = { "pumpkins" },
usage = "[size]", usage = "[size]",
desc = "Generate pumpkin patches", desc = "Generate pumpkin patches",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.generation.pumpkins"}) @CommandPermissions("worldedit.generation.pumpkins")
@Logging(POSITION) @Logging(POSITION)
public static void pumpkins(CommandContext args, WorldEdit we, public static void pumpkins(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -271,13 +271,13 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"/pyramid"}, aliases = { "/pyramid" },
usage = "<block> <range>", usage = "<block> <range>",
desc = "Generate a filled pyramid", desc = "Generate a filled pyramid",
min = 2, min = 2,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.generation.pyramid"}) @CommandPermissions("worldedit.generation.pyramid")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void pyramid(CommandContext args, WorldEdit we, public static void pyramid(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -294,13 +294,13 @@ public class GenerationCommands {
} }
@Command( @Command(
aliases = {"/hpyramid"}, aliases = { "/hpyramid" },
usage = "<block> <range>", usage = "<block> <range>",
desc = "Generate a hollow pyramid", desc = "Generate a hollow pyramid",
min = 2, min = 2,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.generation.pyramid"}) @CommandPermissions("worldedit.generation.pyramid")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void hpyramid(CommandContext args, WorldEdit we, public static void hpyramid(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)

Datei anzeigen

@ -31,13 +31,13 @@ import com.sk89q.worldedit.*;
*/ */
public class HistoryCommands { public class HistoryCommands {
@Command( @Command(
aliases = {"/undo", "undo"}, aliases = { "/undo", "undo" },
usage = "[times] [player]", usage = "[times] [player]",
desc = "Undoes the last action", desc = "Undoes the last action",
min = 0, min = 0,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.history.undo"}) @CommandPermissions("worldedit.history.undo")
public static void undo(CommandContext args, WorldEdit we, public static void undo(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -67,13 +67,13 @@ public class HistoryCommands {
} }
@Command( @Command(
aliases = {"/redo", "redo"}, aliases = { "/redo", "redo" },
usage = "[times] [player]", usage = "[times] [player]",
desc = "Redoes the last action (from history)", desc = "Redoes the last action (from history)",
min = 0, min = 0,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.history.redo"}) @CommandPermissions("worldedit.history.redo")
public static void redo(CommandContext args, WorldEdit we, public static void redo(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -103,13 +103,13 @@ public class HistoryCommands {
} }
@Command( @Command(
aliases = {"/clearhistory", "clearhistory"}, aliases = { "/clearhistory", "clearhistory" },
usage = "", usage = "",
desc = "Clear your history", desc = "Clear your history",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.history.clear"}) @CommandPermissions("worldedit.history.clear")
public static void clearHistory(CommandContext args, WorldEdit we, public static void clearHistory(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -33,13 +33,13 @@ import com.sk89q.worldedit.*;
*/ */
public class NavigationCommands { public class NavigationCommands {
@Command( @Command(
aliases = {"unstuck", "!"}, aliases = { "unstuck", "!" },
usage = "", usage = "",
desc = "Escape from being stuck inside a block", desc = "Escape from being stuck inside a block",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.navigation.unstuck"}) @CommandPermissions("worldedit.navigation.unstuck")
public static void unstuck(CommandContext args, WorldEdit we, public static void unstuck(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -49,13 +49,13 @@ public class NavigationCommands {
} }
@Command( @Command(
aliases = {"ascend"}, aliases = { "ascend" },
usage = "[# of levels]", usage = "[# of levels]",
desc = "Go up a floor", desc = "Go up a floor",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.navigation.ascend"}) @CommandPermissions("worldedit.navigation.ascend")
public static void ascend(CommandContext args, WorldEdit we, public static void ascend(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -78,13 +78,13 @@ public class NavigationCommands {
} }
@Command( @Command(
aliases = {"descend"}, aliases = { "descend" },
usage = "[# of floors]", usage = "[# of floors]",
desc = "Go down a floor", desc = "Go down a floor",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.navigation.descend"}) @CommandPermissions("worldedit.navigation.descend")
public static void descend(CommandContext args, WorldEdit we, public static void descend(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -107,13 +107,13 @@ public class NavigationCommands {
} }
@Command( @Command(
aliases = {"ceil"}, aliases = { "ceil" },
usage = "[clearance]", usage = "[clearance]",
desc = "Go to the celing", desc = "Go to the celing",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.navigation.ceiling"}) @CommandPermissions("worldedit.navigation.ceiling")
@Logging(POSITION) @Logging(POSITION)
public static void ceiling(CommandContext args, WorldEdit we, public static void ceiling(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -130,13 +130,13 @@ public class NavigationCommands {
} }
@Command( @Command(
aliases = {"thru"}, aliases = { "thru" },
usage = "", usage = "",
desc = "Passthrough walls", desc = "Passthrough walls",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.navigation.thru"}) @CommandPermissions("worldedit.navigation.thru")
public static void thru(CommandContext args, WorldEdit we, public static void thru(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -149,13 +149,13 @@ public class NavigationCommands {
} }
@Command( @Command(
aliases = {"jumpto"}, aliases = { "jumpto" },
usage = "", usage = "",
desc = "Teleport to a location", desc = "Teleport to a location",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.navigation.jumpto"}) @CommandPermissions("worldedit.navigation.jumpto")
public static void jumpTo(CommandContext args, WorldEdit we, public static void jumpTo(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -170,13 +170,13 @@ public class NavigationCommands {
} }
@Command( @Command(
aliases = {"up"}, aliases = { "up" },
usage = "<block>", usage = "<block>",
desc = "Go upwards some distance", desc = "Go upwards some distance",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.navigation.up"}) @CommandPermissions("worldedit.navigation.up")
@Logging(POSITION) @Logging(POSITION)
public static void up(CommandContext args, WorldEdit we, public static void up(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)

Datei anzeigen

@ -43,13 +43,13 @@ import com.sk89q.worldedit.regions.RegionOperationException;
*/ */
public class RegionCommands { public class RegionCommands {
@Command( @Command(
aliases = {"/set"}, aliases = { "/set" },
usage = "<block>", usage = "<block>",
desc = "Set all the blocks inside the selection to a block", desc = "Set all the blocks inside the selection to a block",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.region.set"}) @CommandPermissions("worldedit.region.set")
@Logging(REGION) @Logging(REGION)
public static void set(CommandContext args, WorldEdit we, public static void set(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -70,14 +70,14 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/replace"}, aliases = { "/replace" },
usage = "[from-block] <to-block>", usage = "[from-block] <to-block>",
desc = "Replace all blocks in the selection with another", desc = "Replace all blocks in the selection with another",
flags = "f", flags = "f",
min = 1, min = 1,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.region.replace"}) @CommandPermissions("worldedit.region.replace")
@Logging(REGION) @Logging(REGION)
public static void replace(CommandContext args, WorldEdit we, public static void replace(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -105,13 +105,13 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/overlay"}, aliases = { "/overlay" },
usage = "<block>", usage = "<block>",
desc = "Set a block on top of blocks in the region", desc = "Set a block on top of blocks in the region",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.region.overlay"}) @CommandPermissions("worldedit.region.overlay")
@Logging(REGION) @Logging(REGION)
public static void overlay(CommandContext args, WorldEdit we, public static void overlay(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -131,13 +131,13 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/naturalize"}, aliases = { "/naturalize" },
usage = "", usage = "",
desc = "3 layers of dirt on top then rock below", desc = "3 layers of dirt on top then rock below",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.region.naturalize"}) @CommandPermissions("worldedit.region.naturalize")
@Logging(REGION) @Logging(REGION)
public static void naturalize(CommandContext args, WorldEdit we, public static void naturalize(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -149,13 +149,13 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/walls"}, aliases = { "/walls" },
usage = "<block>", usage = "<block>",
desc = "Build the four sides of the selection", desc = "Build the four sides of the selection",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.region.walls"}) @CommandPermissions("worldedit.region.walls")
@Logging(REGION) @Logging(REGION)
public static void walls(CommandContext args, WorldEdit we, public static void walls(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -173,13 +173,13 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/faces", "/outline"}, aliases = { "/faces", "/outline" },
usage = "<block>", usage = "<block>",
desc = "Build the walls, ceiling, and floor of a selection", desc = "Build the walls, ceiling, and floor of a selection",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.region.faces"}) @CommandPermissions("worldedit.region.faces")
@Logging(REGION) @Logging(REGION)
public static void faces(CommandContext args, WorldEdit we, public static void faces(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -197,14 +197,14 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/smooth"}, aliases = { "/smooth" },
usage = "[iterations]", usage = "[iterations]",
flags = "n", flags = "n",
desc = "Smooth the elevation in the selection", desc = "Smooth the elevation in the selection",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.region.smooth"}) @CommandPermissions("worldedit.region.smooth")
@Logging(REGION) @Logging(REGION)
public static void smooth(CommandContext args, WorldEdit we, public static void smooth(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -223,14 +223,14 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/move"}, aliases = { "/move" },
usage = "[count] [direction] [leave-id]", usage = "[count] [direction] [leave-id]",
flags = "s", flags = "s",
desc = "Move the contents of the selection", desc = "Move the contents of the selection",
min = 0, min = 0,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.region.move"}) @CommandPermissions("worldedit.region.move")
@Logging(ORIENTATION_REGION) @Logging(ORIENTATION_REGION)
public static void move(CommandContext args, WorldEdit we, public static void move(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -269,14 +269,14 @@ public class RegionCommands {
@Command( @Command(
aliases = {"/stack"}, aliases = { "/stack" },
usage = "[count] [direction]", usage = "[count] [direction]",
flags = "sa", flags = "sa",
desc = "Repeat the contents of the selection", desc = "Repeat the contents of the selection",
min = 0, min = 0,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.region.stack"}) @CommandPermissions("worldedit.region.stack")
@Logging(ORIENTATION_REGION) @Logging(ORIENTATION_REGION)
public static void stack(CommandContext args, WorldEdit we, public static void stack(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -306,13 +306,13 @@ public class RegionCommands {
} }
@Command( @Command(
aliases = {"/regen"}, aliases = { "/regen" },
usage = "", usage = "",
desc = "Regenerates the contents of the selection", desc = "Regenerates the contents of the selection",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.regen"}) @CommandPermissions("worldedit.regen")
@Logging(REGION) @Logging(REGION)
public static void regenerateChunk(CommandContext args, WorldEdit we, public static void regenerateChunk(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)

Datei anzeigen

@ -34,13 +34,13 @@ import com.sk89q.worldedit.*;
*/ */
public class ScriptingCommands { public class ScriptingCommands {
@Command( @Command(
aliases = {"cs"}, aliases = { "cs" },
usage = "<filename> [args...]", usage = "<filename> [args...]",
desc = "Execute a CraftScript", desc = "Execute a CraftScript",
min = 1, min = 1,
max = -1 max = -1
) )
@CommandPermissions({"worldedit.scripting.execute"}) @CommandPermissions("worldedit.scripting.execute")
@Logging(ALL) @Logging(ALL)
public static void execute(CommandContext args, WorldEdit we, public static void execute(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -59,13 +59,13 @@ public class ScriptingCommands {
} }
@Command( @Command(
aliases = {".s"}, aliases = { ".s" },
usage = "[args...]", usage = "[args...]",
desc = "Execute last CraftScript", desc = "Execute last CraftScript",
min = 0, min = 0,
max = -1 max = -1
) )
@CommandPermissions({"worldedit.scripting.execute"}) @CommandPermissions("worldedit.scripting.execute")
@Logging(ALL) @Logging(ALL)
public static void executeLast(CommandContext args, WorldEdit we, public static void executeLast(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -86,6 +86,5 @@ public class ScriptingCommands {
new String[] {"js"}); new String[] {"js"});
we.runScript(player, f, scriptArgs); we.runScript(player, f, scriptArgs);
} }
} }

Datei anzeigen

@ -40,13 +40,13 @@ import com.sk89q.worldedit.blocks.*;
*/ */
public class SelectionCommands { public class SelectionCommands {
@Command( @Command(
aliases = {"/pos1"}, aliases = { "/pos1" },
usage = "[coordinates]", usage = "[coordinates]",
desc = "Set position 1", desc = "Set position 1",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.selection.pos"}) @CommandPermissions("worldedit.selection.pos")
public static void pos1(CommandContext args, WorldEdit we, public static void pos1(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -75,13 +75,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/pos2"}, aliases = { "/pos2" },
usage = "[coordinates]", usage = "[coordinates]",
desc = "Set position 2", desc = "Set position 2",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.selection.pos"}) @CommandPermissions("worldedit.selection.pos")
public static void pos2(CommandContext args, WorldEdit we, public static void pos2(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -112,13 +112,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/hpos1"}, aliases = { "/hpos1" },
usage = "", usage = "",
desc = "Set position 1 to targeted block", desc = "Set position 1 to targeted block",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.selection.hpos"}) @CommandPermissions("worldedit.selection.hpos")
public static void hpos1(CommandContext args, WorldEdit we, public static void hpos1(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -140,13 +140,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/hpos2"}, aliases = { "/hpos2" },
usage = "", usage = "",
desc = "Set position 2 to targeted block", desc = "Set position 2 to targeted block",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.selection.hpos"}) @CommandPermissions("worldedit.selection.hpos")
public static void hpos2(CommandContext args, WorldEdit we, public static void hpos2(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -168,14 +168,14 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/chunk"}, aliases = { "/chunk" },
usage = "", usage = "",
flags = "s", flags = "s",
desc = "Set the selection to your current chunk.", desc = "Set the selection to your current chunk.",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.selection.chunk"}) @CommandPermissions("worldedit.selection.chunk")
public static void chunk(CommandContext args, WorldEdit we, public static void chunk(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -215,13 +215,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/wand"}, aliases = { "/wand" },
usage = "", usage = "",
desc = "Get the wand object", desc = "Get the wand object",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.wand"}) @CommandPermissions("worldedit.wand")
public static void wand(CommandContext args, WorldEdit we, public static void wand(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -231,13 +231,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"toggleeditwand"}, aliases = { "toggleeditwand" },
usage = "", usage = "",
desc = "Toggle functionality of the edit wand", desc = "Toggle functionality of the edit wand",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.wand.toggle"}) @CommandPermissions("worldedit.wand.toggle")
public static void toggleWand(CommandContext args, WorldEdit we, public static void toggleWand(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -252,13 +252,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/expand"}, aliases = { "/expand" },
usage = "<amount> [reverse-amount] <direction>", usage = "<amount> [reverse-amount] <direction>",
desc = "Expand the selection area", desc = "Expand the selection area",
min = 1, min = 1,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.selection.expand"}) @CommandPermissions("worldedit.selection.expand")
public static void expand(CommandContext args, WorldEdit we, public static void expand(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -289,8 +289,9 @@ public class SelectionCommands {
int change = args.getInteger(0); int change = args.getInteger(0);
int reverseChange = 0; int reverseChange = 0;
// Specifying a direction switch (args.argsLength()) {
if (args.argsLength() == 2) { case 2:
// Either a reverse amount or a direction
try { try {
reverseChange = args.getInteger(1) * -1; reverseChange = args.getInteger(1) * -1;
dir = we.getDirection(player, "me"); dir = we.getDirection(player, "me");
@ -298,12 +299,15 @@ public class SelectionCommands {
dir = we.getDirection(player, dir = we.getDirection(player,
args.getString(1).toLowerCase()); args.getString(1).toLowerCase());
} }
// Specifying a direction and a reverse amount break;
} else if (args.argsLength() == 3) {
case 3:
// Both reverse amount and direction
reverseChange = args.getInteger(1) * -1; reverseChange = args.getInteger(1) * -1;
dir = we.getDirection(player, dir = we.getDirection(player,
args.getString(2).toLowerCase()); args.getString(2).toLowerCase());
} else { break;
default:
dir = we.getDirection(player, "me"); dir = we.getDirection(player, "me");
} }
@ -324,13 +328,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/contract"}, aliases = { "/contract" },
usage = "<amount> [reverse-amount] [direction]", usage = "<amount> [reverse-amount] [direction]",
desc = "Contract the selection area", desc = "Contract the selection area",
min = 1, min = 1,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.selection.contract"}) @CommandPermissions("worldedit.selection.contract")
public static void contract(CommandContext args, WorldEdit we, public static void contract(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -339,8 +343,9 @@ public class SelectionCommands {
int change = args.getInteger(0); int change = args.getInteger(0);
int reverseChange = 0; int reverseChange = 0;
// Either a reverse amount or a direction switch (args.argsLength()) {
if (args.argsLength() == 2) { case 2:
// Either a reverse amount or a direction
try { try {
reverseChange = args.getInteger(1) * -1; reverseChange = args.getInteger(1) * -1;
dir = we.getDirection(player, "me"); dir = we.getDirection(player, "me");
@ -348,12 +353,15 @@ public class SelectionCommands {
dir = we.getDirection(player, dir = we.getDirection(player,
args.getString(1).toLowerCase()); args.getString(1).toLowerCase());
} }
// Both reverse amount and direction break;
} else if (args.argsLength() == 3) {
case 3:
// Both reverse amount and direction
reverseChange = args.getInteger(1) * -1; reverseChange = args.getInteger(1) * -1;
dir = we.getDirection(player, dir = we.getDirection(player,
args.getString(2).toLowerCase()); args.getString(2).toLowerCase());
} else { break;
default:
dir = we.getDirection(player, "me"); dir = we.getDirection(player, "me");
} }
@ -376,13 +384,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/shift"}, aliases = { "/shift" },
usage = "<amount> [direction]", usage = "<amount> [direction]",
desc = "Shift the selection area", desc = "Shift the selection area",
min = 1, min = 1,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.selection.shift"}) @CommandPermissions("worldedit.selection.shift")
public static void shift(CommandContext args, WorldEdit we, public static void shift(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -411,14 +419,14 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/outset"}, aliases = { "/outset" },
usage = "<amount>", usage = "<amount>",
desc = "Outset the selection area", desc = "Outset the selection area",
flags = "hv", flags = "hv",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.selection.outset"}) @CommandPermissions("worldedit.selection.outset")
public static void outset(CommandContext args, WorldEdit we, public static void outset(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -450,14 +458,14 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/inset"}, aliases = { "/inset" },
usage = "<amount>", usage = "<amount>",
desc = "Inset the selection area", desc = "Inset the selection area",
flags = "hv", flags = "hv",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.selection.inset"}) @CommandPermissions("worldedit.selection.inset")
public static void inset(CommandContext args, WorldEdit we, public static void inset(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -485,13 +493,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/size"}, aliases = { "/size" },
usage = "", usage = "",
desc = "Get information about the selection", desc = "Get information about the selection",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.selection.size"}) @CommandPermissions("worldedit.selection.size")
public static void size(CommandContext args, WorldEdit we, public static void size(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -513,13 +521,13 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/count"}, aliases = { "/count" },
usage = "<block>", usage = "<block>",
desc = "Counts the number of a certain type of block", desc = "Counts the number of a certain type of block",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.analysis.count"}) @CommandPermissions("worldedit.analysis.count")
public static void count(CommandContext args, WorldEdit we, public static void count(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -531,14 +539,14 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/distr"}, aliases = { "/distr" },
usage = "", usage = "",
desc = "Get the distribution of blocks in the selection", desc = "Get the distribution of blocks in the selection",
flags = "c", flags = "c",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.analysis.distr"}) @CommandPermissions("worldedit.analysis.distr")
public static void distr(CommandContext args, WorldEdit we, public static void distr(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -575,7 +583,7 @@ public class SelectionCommands {
} }
@Command( @Command(
aliases = {"/sel", ";"}, aliases = { "/sel", ";" },
usage = "[type]", usage = "[type]",
desc = "Choose a region selector", desc = "Choose a region selector",
min = 0, min = 0,

Datei anzeigen

@ -42,12 +42,14 @@ public class SnapshotCommands {
private static Logger logger = Logger.getLogger("Minecraft.WorldEdit"); private static Logger logger = Logger.getLogger("Minecraft.WorldEdit");
private static DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss z"); private static DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss z");
@Command(aliases = {"list"}, @Command(
usage = "[num]", aliases = { "list" },
desc = "List snapshots", usage = "[num]",
min = 0, desc = "List snapshots",
max = 1) min = 0,
@CommandPermissions({"worldedit.snapshots.list"}) max = 1
)
@CommandPermissions("worldedit.snapshots.list")
public static void list(CommandContext args, WorldEdit we, public static void list(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -92,12 +94,14 @@ public class SnapshotCommands {
} }
} }
@Command(aliases = {"use"}, @Command(
usage = "<snapshot>", aliases = { "use" },
desc = "Choose a snapshot to use", usage = "<snapshot>",
min = 1, desc = "Choose a snapshot to use",
max = 1) min = 1,
@CommandPermissions({"worldedit.snapshots.restore"}) max = 1
)
@CommandPermissions("worldedit.snapshots.restore")
public static void use(CommandContext args, WorldEdit we, public static void use(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -135,12 +139,14 @@ public class SnapshotCommands {
} }
} }
@Command(aliases = {"before"}, @Command(
usage = "<date>", aliases = { "before" },
desc = "Choose the nearest snapshot before a date", usage = "<date>",
min = 1, desc = "Choose the nearest snapshot before a date",
max = -1) min = 1,
@CommandPermissions({"worldedit.snapshots.restore"}) max = -1
)
@CommandPermissions("worldedit.snapshots.restore")
public static void before(CommandContext args, WorldEdit we, public static void before(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -174,12 +180,14 @@ public class SnapshotCommands {
} }
} }
@Command(aliases = {"after"}, @Command(
usage = "<date>", aliases = { "after" },
desc = "Choose the nearest snapshot after a date", usage = "<date>",
min = 1, desc = "Choose the nearest snapshot after a date",
max = -1) min = 1,
@CommandPermissions({"worldedit.snapshots.restore"}) max = -1
)
@CommandPermissions("worldedit.snapshots.restore")
public static void after(CommandContext args, WorldEdit we, public static void after(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -44,20 +44,24 @@ public class SnapshotUtilCommands {
private static Logger logger = Logger.getLogger("Minecraft.WorldEdit"); private static Logger logger = Logger.getLogger("Minecraft.WorldEdit");
@Command(aliases = {"snapshot", "snap"}, @Command(
desc = "Snapshot commands") aliases = { "snapshot", "snap" },
@NestedCommand({SnapshotCommands.class}) desc = "Snapshot commands"
)
@NestedCommand(SnapshotCommands.class)
public static void snapshot(CommandContext args, WorldEdit we, public static void snapshot(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
} }
@Command(aliases = {"restore", "/restore"}, @Command(
usage = "[snapshot]", aliases = { "restore", "/restore" },
desc = "Restore the selection from a snapshot", usage = "[snapshot]",
min = 0, desc = "Restore the selection from a snapshot",
max = 1) min = 0,
@CommandPermissions({"worldedit.snapshots.restore"}) max = 1
)
@CommandPermissions("worldedit.snapshots.restore")
public static void restore(CommandContext args, WorldEdit we, public static void restore(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -34,13 +34,13 @@ import com.sk89q.worldedit.tools.SinglePickaxe;
public class SuperPickaxeCommands { public class SuperPickaxeCommands {
@Command( @Command(
aliases = {"single"}, aliases = { "single" },
usage = "", usage = "",
desc = "Enable the single block super pickaxe mode", desc = "Enable the single block super pickaxe mode",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.superpickaxe"}) @CommandPermissions("worldedit.superpickaxe")
public static void single(CommandContext args, WorldEdit we, public static void single(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -51,13 +51,13 @@ public class SuperPickaxeCommands {
} }
@Command( @Command(
aliases = {"area"}, aliases = { "area" },
usage = "<radius>", usage = "<radius>",
desc = "Enable the area super pickaxe pickaxe mode", desc = "Enable the area super pickaxe pickaxe mode",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.superpickaxe.area"}) @CommandPermissions("worldedit.superpickaxe.area")
public static void area(CommandContext args, WorldEdit we, public static void area(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -76,13 +76,13 @@ public class SuperPickaxeCommands {
} }
@Command( @Command(
aliases = {"recur", "recursive"}, aliases = { "recur", "recursive" },
usage = "<radius>", usage = "<radius>",
desc = "Enable the recursive super pickaxe pickaxe mode", desc = "Enable the recursive super pickaxe pickaxe mode",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.superpickaxe.recursive"}) @CommandPermissions("worldedit.superpickaxe.recursive")
public static void recursive(CommandContext args, WorldEdit we, public static void recursive(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -32,9 +32,9 @@ import com.sk89q.worldedit.util.TreeGenerator;
public class ToolCommands { public class ToolCommands {
@Command( @Command(
aliases = {"none"}, aliases = { "none" },
usage = "", usage = "",
desc = "Turn off all superpickaxe alternate modes", desc = "Unbind all bound tools",
min = 0, min = 0,
max = 0 max = 0
) )
@ -47,13 +47,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"info"}, aliases = { "info" },
usage = "", usage = "",
desc = "Block information tool", desc = "Block information tool",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.tool.info"}) @CommandPermissions("worldedit.tool.info")
public static void info(CommandContext args, WorldEdit we, public static void info(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -64,13 +64,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"tree"}, aliases = { "tree" },
usage = "[type]", usage = "[type]",
desc = "Tree generator tool", desc = "Tree generator tool",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.tool.tree"}) @CommandPermissions("worldedit.tool.tree")
public static void tree(CommandContext args, WorldEdit we, public static void tree(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -90,13 +90,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"repl"}, aliases = { "repl" },
usage = "<block>", usage = "<block>",
desc = "Block replacer tool", desc = "Block replacer tool",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.tool.replacer"}) @CommandPermissions("worldedit.tool.replacer")
public static void repl(CommandContext args, WorldEdit we, public static void repl(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -108,13 +108,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"cycler"}, aliases = { "cycler" },
usage = "", usage = "",
desc = "Block data cycler tool", desc = "Block data cycler tool",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.tool.data-cycler"}) @CommandPermissions("worldedit.tool.data-cycler")
public static void cycler(CommandContext args, WorldEdit we, public static void cycler(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -125,13 +125,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"floodfill", "flood"}, aliases = { "floodfill", "flood" },
usage = "<pattern> <range>", usage = "<pattern> <range>",
desc = "Flood fill tool", desc = "Flood fill tool",
min = 2, min = 2,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.tool.flood-fill"}) @CommandPermissions("worldedit.tool.flood-fill")
public static void floodFill(CommandContext args, WorldEdit we, public static void floodFill(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -151,23 +151,23 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"brush", "br"}, aliases = { "brush", "br" },
desc = "Brush tool" desc = "Brush tool"
) )
@NestedCommand({BrushCommands.class}) @NestedCommand(BrushCommands.class)
public static void brush(CommandContext args, WorldEdit we, public static void brush(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
} }
@Command( @Command(
aliases = {"deltree"}, aliases = { "deltree" },
usage = "", usage = "",
desc = "Floating tree remover tool", desc = "Floating tree remover tool",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.tool.deltree"}) @CommandPermissions("worldedit.tool.deltree")
public static void deltree(CommandContext args, WorldEdit we, public static void deltree(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -178,13 +178,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"farwand"}, aliases = { "farwand" },
usage = "", usage = "",
desc = "Wand at a distance tool", desc = "Wand at a distance tool",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.tool.farwand"}) @CommandPermissions("worldedit.tool.farwand")
public static void farwand(CommandContext args, WorldEdit we, public static void farwand(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -194,13 +194,13 @@ public class ToolCommands {
} }
@Command( @Command(
aliases = {"lrbuild", "/lrbuild"}, aliases = { "lrbuild", "/lrbuild" },
usage = "<leftclick block> <rightclick block>", usage = "<leftclick block> <rightclick block>",
desc = "Long-range building tool", desc = "Long-range building tool",
min = 2, min = 2,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.tool.lrbuild"}) @CommandPermissions("worldedit.tool.lrbuild")
public static void longrangebuildtool(CommandContext args, WorldEdit we, public static void longrangebuildtool(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -34,13 +34,13 @@ import com.sk89q.worldedit.patterns.Pattern;
*/ */
public class ToolUtilCommands { public class ToolUtilCommands {
@Command( @Command(
aliases = {"/", ","}, aliases = { "/", "," },
usage = "[on|off]", usage = "[on|off]",
desc = "Toggle the super pickaxe pickaxe function", desc = "Toggle the super pickaxe pickaxe function",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.superpickaxe"}) @CommandPermissions("worldedit.superpickaxe")
public static void togglePickaxe(CommandContext args, WorldEdit we, public static void togglePickaxe(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -67,10 +67,10 @@ public class ToolUtilCommands {
} }
@Command( @Command(
aliases = {"superpickaxe", "pickaxe", "sp"}, aliases = { "superpickaxe", "pickaxe", "sp" },
desc = "Select super pickaxe mode" desc = "Select super pickaxe mode"
) )
@NestedCommand({SuperPickaxeCommands.class}) @NestedCommand(SuperPickaxeCommands.class)
public static void pickaxe(CommandContext args, WorldEdit we, public static void pickaxe(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -80,20 +80,20 @@ public class ToolUtilCommands {
aliases = {"tool"}, aliases = {"tool"},
desc = "Select a tool to bind" desc = "Select a tool to bind"
) )
@NestedCommand({ToolCommands.class}) @NestedCommand(ToolCommands.class)
public static void tool(CommandContext args, WorldEdit we, public static void tool(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
} }
@Command( @Command(
aliases = {"mask"}, aliases = { "mask" },
usage = "[mask]", usage = "[mask]",
desc = "Set the brush mask", desc = "Set the brush mask",
min = 0, min = 0,
max = -1 max = -1
) )
@CommandPermissions({"worldedit.brush.options.mask"}) @CommandPermissions("worldedit.brush.options.mask")
public static void mask(CommandContext args, WorldEdit we, public static void mask(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -108,13 +108,13 @@ public class ToolUtilCommands {
} }
@Command( @Command(
aliases = {"mat", "material", "fill"}, aliases = { "mat", "material", "fill" },
usage = "[pattern]", usage = "[pattern]",
desc = "Set the brush material", desc = "Set the brush material",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.brush.options.material"}) @CommandPermissions("worldedit.brush.options.material")
public static void material(CommandContext args, WorldEdit we, public static void material(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -124,13 +124,13 @@ public class ToolUtilCommands {
} }
@Command( @Command(
aliases = {"range"}, aliases = { "range" },
usage = "[pattern]", usage = "[pattern]",
desc = "Set the brush range", desc = "Set the brush range",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.brush.options.range"}) @CommandPermissions("worldedit.brush.options.range")
public static void range(CommandContext args, WorldEdit we, public static void range(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -140,13 +140,13 @@ public class ToolUtilCommands {
} }
@Command( @Command(
aliases = {"size"}, aliases = { "size" },
usage = "[pattern]", usage = "[pattern]",
desc = "Set the brush size", desc = "Set the brush size",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.brush.options.size"}) @CommandPermissions("worldedit.brush.options.size")
public static void size(CommandContext args, WorldEdit we, public static void size(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {

Datei anzeigen

@ -39,13 +39,13 @@ import com.sk89q.worldedit.regions.Region;
*/ */
public class UtilityCommands { public class UtilityCommands {
@Command( @Command(
aliases = {"/fill"}, aliases = { "/fill" },
usage = "<block> <radius> [depth]", usage = "<block> <radius> [depth]",
desc = "Fill a hole", desc = "Fill a hole",
min = 2, min = 2,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.fill"}) @CommandPermissions("worldedit.fill")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void fill(CommandContext args, WorldEdit we, public static void fill(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -69,13 +69,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/fillr"}, aliases = { "/fillr" },
usage = "<block> <radius> [depth]", usage = "<block> <radius> [depth]",
desc = "Fill a hole recursively", desc = "Fill a hole recursively",
min = 2, min = 2,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.fill.recursive"}) @CommandPermissions("worldedit.fill.recursive")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void fillr(CommandContext args, WorldEdit we, public static void fillr(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -99,13 +99,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/drain"}, aliases = { "/drain" },
usage = "<radius>", usage = "<radius>",
desc = "Drain a pool", desc = "Drain a pool",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.drain"}) @CommandPermissions("worldedit.drain")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void drain(CommandContext args, WorldEdit we, public static void drain(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -119,13 +119,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/fixlava", "fixlava"}, aliases = { "/fixlava", "fixlava" },
usage = "<radius>", usage = "<radius>",
desc = "Fix lava to be stationary", desc = "Fix lava to be stationary",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.fixlava"}) @CommandPermissions("worldedit.fixlava")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void fixLava(CommandContext args, WorldEdit we, public static void fixLava(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -139,13 +139,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/fixwater", "fixwater"}, aliases = { "/fixwater", "fixwater" },
usage = "<radius>", usage = "<radius>",
desc = "Fix water to be stationary", desc = "Fix water to be stationary",
min = 1, min = 1,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.fixwater"}) @CommandPermissions("worldedit.fixwater")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void fixWater(CommandContext args, WorldEdit we, public static void fixWater(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -159,13 +159,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/removeabove", "removeabove"}, aliases = { "/removeabove", "removeabove" },
usage = "[size] [height]", usage = "[size] [height]",
desc = "Remove blocks above your head.", desc = "Remove blocks above your head.",
min = 0, min = 0,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.removeabove"}) @CommandPermissions("worldedit.removeabove")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void removeAbove(CommandContext args, WorldEdit we, public static void removeAbove(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -181,13 +181,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/removebelow", "removebelow"}, aliases = { "/removebelow", "removebelow" },
usage = "[size] [height]", usage = "[size] [height]",
desc = "Remove blocks below you.", desc = "Remove blocks below you.",
min = 0, min = 0,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.removebelow"}) @CommandPermissions("worldedit.removebelow")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void removeBelow(CommandContext args, WorldEdit we, public static void removeBelow(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -203,13 +203,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/removenear", "removenear"}, aliases = { "/removenear", "removenear" },
usage = "<block> [size]", usage = "<block> [size]",
desc = "Remove blocks near you.", desc = "Remove blocks near you.",
min = 1, min = 1,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.removenear"}) @CommandPermissions("worldedit.removenear")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void removeNear(CommandContext args, WorldEdit we, public static void removeNear(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -225,14 +225,14 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/replacenear", "replacenear"}, aliases = { "/replacenear", "replacenear" },
usage = "<size> <from-id> <to-id>", usage = "<size> <from-id> <to-id>",
desc = "Replace nearby blocks", desc = "Replace nearby blocks",
flags = "f", flags = "f",
min = 3, min = 3,
max = 3 max = 3
) )
@CommandPermissions({"worldedit.replacenear"}) @CommandPermissions("worldedit.replacenear")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void replaceNear(CommandContext args, WorldEdit we, public static void replaceNear(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -264,13 +264,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/snow", "snow"}, aliases = { "/snow", "snow" },
usage = "[radius]", usage = "[radius]",
desc = "Simulates snow", desc = "Simulates snow",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.snow"}) @CommandPermissions("worldedit.snow")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void snow(CommandContext args, WorldEdit we, public static void snow(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -289,7 +289,7 @@ public class UtilityCommands {
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.thaw"}) @CommandPermissions("worldedit.thaw")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void thaw(CommandContext args, WorldEdit we, public static void thaw(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -302,13 +302,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/green", "green"}, aliases = { "/green", "green" },
usage = "[radius]", usage = "[radius]",
desc = "Greens the area", desc = "Greens the area",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.green"}) @CommandPermissions("worldedit.green")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void green(CommandContext args, WorldEdit we, public static void green(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -321,13 +321,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"/ex", "/ext", "/extinguish", "ex", "ext", "extinguish"}, aliases = { "/ex", "/ext", "/extinguish", "ex", "ext", "extinguish" },
usage = "[radius]", usage = "[radius]",
desc = "Extinguish nearby fire", desc = "Extinguish nearby fire",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.extinguish"}) @CommandPermissions("worldedit.extinguish")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void extinguish(CommandContext args, WorldEdit we, public static void extinguish(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -346,14 +346,14 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"butcher"}, aliases = { "butcher" },
usage = "[radius]", usage = "[radius]",
flags = "p", flags = "p",
desc = "Kill all or nearby mobs", desc = "Kill all or nearby mobs",
min = 0, min = 0,
max = 1 max = 1
) )
@CommandPermissions({"worldedit.butcher"}) @CommandPermissions("worldedit.butcher")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void butcher(CommandContext args, WorldEdit we, public static void butcher(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
@ -368,13 +368,13 @@ public class UtilityCommands {
} }
@Command( @Command(
aliases = {"remove", "rem", "rement"}, aliases = { "remove", "rem", "rement" },
usage = "<type> <radius>", usage = "<type> <radius>",
desc = "Remove all entities of a type", desc = "Remove all entities of a type",
min = 2, min = 2,
max = 2 max = 2
) )
@CommandPermissions({"worldedit.remove"}) @CommandPermissions("worldedit.remove")
@Logging(PLACEMENT) @Logging(PLACEMENT)
public static void remove(CommandContext args, WorldEdit we, public static void remove(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)

Datei anzeigen

@ -36,7 +36,7 @@ public class WorldEditCommands {
private static DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss z"); private static DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss z");
@Command( @Command(
aliases = {"version", "ver"}, aliases = { "version", "ver" },
usage = "", usage = "",
desc = "Get WorldEdit version", desc = "Get WorldEdit version",
min = 0, min = 0,
@ -51,13 +51,13 @@ public class WorldEditCommands {
} }
@Command( @Command(
aliases = {"reload"}, aliases = { "reload" },
usage = "", usage = "",
desc = "Reload WorldEdit", desc = "Reload WorldEdit",
min = 0, min = 0,
max = 0 max = 0
) )
@CommandPermissions({"worldedit.reload"}) @CommandPermissions("worldedit.reload")
public static void reload(CommandContext args, WorldEdit we, public static void reload(CommandContext args, WorldEdit we,
LocalSession session, LocalPlayer player, EditSession editSession) LocalSession session, LocalPlayer player, EditSession editSession)
throws WorldEditException { throws WorldEditException {
@ -67,7 +67,7 @@ public class WorldEditCommands {
} }
@Command( @Command(
aliases = {"cui"}, aliases = { "cui" },
usage = "", usage = "",
desc = "Complete CUI handshake", desc = "Complete CUI handshake",
min = 0, min = 0,
@ -81,7 +81,7 @@ public class WorldEditCommands {
} }
@Command( @Command(
aliases = {"tz"}, aliases = { "tz" },
usage = "[timezone]", usage = "[timezone]",
desc = "Set your timezone", desc = "Set your timezone",
min = 1, min = 1,

Datei anzeigen

@ -19,7 +19,6 @@
package com.sk89q.worldedit.tools; package com.sk89q.worldedit.tools;
import java.util.Arrays;
import java.util.HashSet; import java.util.HashSet;
import java.util.Iterator; import java.util.Iterator;
import java.util.Set; import java.util.Set;