Merge pull request #1025 from manuelgu/master

Cleanup
This commit is contained in:
Jesse Boyd 2016-03-29 20:08:33 +11:00
commit 578e884be7
20 changed files with 18 additions and 34 deletions

View File

@ -53,7 +53,6 @@ import com.intellectualcrafters.plot.util.WorldUtil;
import com.intellectualcrafters.plot.util.area.QuadMap;
import com.plotsquared.listener.WESubscriber;
import com.sk89q.worldedit.WorldEdit;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;

View File

@ -180,7 +180,6 @@ public class Auto extends SubCommand {
return false;
}
plotarea.setMeta("lastPlot", new PlotId(0, 0));
boolean br = false;
while (true) {
PlotId start = getNextPlotId(getLastPlotId(plotarea), 1);
PlotId end = new PlotId(start.x + size_x - 1, start.y + size_z - 1);

View File

@ -31,7 +31,6 @@ import com.intellectualcrafters.plot.util.EconHandler;
import com.intellectualcrafters.plot.util.MainUtil;
import com.intellectualcrafters.plot.util.UUIDHandler;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.Set;
@CommandDeclaration(
@ -45,7 +44,7 @@ import java.util.Set;
public class Buy extends SubCommand {
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
if (EconHandler.manager == null) {
return sendMessage(plr, C.ECON_DISABLED);
}

View File

@ -13,7 +13,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
public class Chat extends SubCommand {
@Override
public boolean onCommand(PlotPlayer player, String... args) {
public boolean onCommand(PlotPlayer player, String[] args) {
MainCommand.getInstance().toggle.chat(this, player, new String[0], null, null);
return true;
}

View File

@ -40,7 +40,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
public class Claim extends SubCommand {
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
String schematic = "";
if (args.length >= 1) {
schematic = args[0];

View File

@ -32,7 +32,6 @@ import com.intellectualcrafters.plot.util.Permissions;
import com.intellectualcrafters.plot.util.SetQueue;
import com.intellectualcrafters.plot.util.TaskManager;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.Set;
@CommandDeclaration(command = "clear",
@ -45,7 +44,7 @@ import java.util.Set;
public class Clear extends SubCommand {
@Override
public boolean onCommand(final PlotPlayer plr, String... args) {
public boolean onCommand(final PlotPlayer plr, String[] args) {
Location loc = plr.getLocation();
final Plot plot;
if (args.length == 1) {

View File

@ -35,7 +35,6 @@ import com.intellectualcrafters.plot.util.MainUtil;
import com.intellectualcrafters.plot.util.Permissions;
import com.intellectualcrafters.plot.util.UUIDHandler;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Set;
@ -50,7 +49,7 @@ import java.util.UUID;
public class Cluster extends SubCommand {
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
// list, create, delete, resize, invite, kick, leave, helpers, tp, sethome
if (args.length == 0) {

View File

@ -30,7 +30,6 @@ import com.intellectualcrafters.plot.util.MathMan;
import com.intellectualcrafters.plot.util.TaskManager;
import com.intellectualcrafters.plot.util.WorldUtil;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashSet;
@ -49,7 +48,7 @@ public class Condense extends SubCommand {
public static boolean TASK = false;
@Override
public boolean onCommand(final PlotPlayer plr, String... args) {
public boolean onCommand(final PlotPlayer plr, String[] args) {
if ((args.length != 2) && (args.length != 3)) {
MainUtil.sendMessage(plr, "/plot condense <area> <start|stop|info> [radius]");
return false;

View File

@ -35,7 +35,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
public class Confirm extends SubCommand {
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
CmdInstance command = CmdConfirm.getPending(plr);
if (command == null) {
MainUtil.sendMessage(plr, C.FAILED_CONFIRM);

View File

@ -40,7 +40,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
public class CreateRoadSchematic extends SubCommand {
@Override
public boolean onCommand(PlotPlayer player, String... args) {
public boolean onCommand(PlotPlayer player, String[] args) {
Location loc = player.getLocation();
Plot plot = loc.getPlotAbs();
if (plot == null) {
@ -50,7 +50,7 @@ public class CreateRoadSchematic extends SubCommand {
return sendMessage(player, C.NOT_IN_PLOT_WORLD);
}
HybridUtils.manager.setupRoadSchematic(plot);
MainUtil.sendMessage(player, "&6Saved new road schematic. To test the road, fly to a few other plots and use /plot debugroadregen");
MainUtil.sendMessage(player, "$1Saved new road schematic. To test the road, fly to a few other plots and use /plot debugroadregen");
return true;
}
}

View File

@ -3,7 +3,6 @@ package com.intellectualcrafters.plot.commands;
import com.intellectualcrafters.plot.config.C;
import com.intellectualcrafters.plot.object.PlotPlayer;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.List;
import java.util.UUID;
@ -20,7 +19,7 @@ public class DebugAllowUnsafe extends SubCommand {
public static final List<UUID> unsafeAllowed = new ArrayList<>();
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
if (unsafeAllowed.contains(plr.getUUID())) {
unsafeAllowed.remove(plr.getUUID());

View File

@ -56,7 +56,6 @@ import com.intellectualcrafters.plot.util.WorldUtil;
import com.plotsquared.general.commands.Command;
import com.plotsquared.general.commands.CommandDeclaration;
import com.plotsquared.listener.WEManager;
import java.io.File;
import java.io.IOException;
import java.nio.charset.StandardCharsets;
@ -65,7 +64,6 @@ import java.util.Arrays;
import java.util.Date;
import java.util.HashMap;
import java.util.UUID;
import javax.script.Bindings;
import javax.script.ScriptContext;
import javax.script.ScriptEngine;
@ -165,7 +163,7 @@ public class DebugExec extends SubCommand {
}
@Override
public boolean onCommand(final PlotPlayer player, String... args) {
public boolean onCommand(final PlotPlayer player, String[] args) {
java.util.List<String> allowed_params =
Arrays.asList("calibrate-analysis", "remove-flag", "stop-expire", "start-expire", "show-expired", "update-expired", "seen");
if (args.length > 0) {

View File

@ -43,7 +43,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
public class DebugRoadRegen extends SubCommand {
@Override
public boolean onCommand(PlotPlayer player, String... args) {
public boolean onCommand(PlotPlayer player, String[] args) {
Location loc = player.getLocation();
PlotArea plotworld = loc.getPlotArea();
if (!(plotworld instanceof HybridPlotWorld)) {

View File

@ -33,7 +33,6 @@ import com.intellectualcrafters.plot.util.MainUtil;
import com.intellectualcrafters.plot.util.Permissions;
import com.intellectualcrafters.plot.util.StringMan;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashMap;
@ -55,8 +54,8 @@ public class FlagCmd extends SubCommand {
}
@Override
public boolean onCommand(PlotPlayer player, String... args) {
public boolean onCommand(PlotPlayer player, String[] args) {
/*
* plot flag set fly true
* plot flag remove fly

View File

@ -30,7 +30,6 @@ import com.intellectualcrafters.plot.util.CommentManager;
import com.intellectualcrafters.plot.util.MainUtil;
import com.intellectualcrafters.plot.util.StringMan;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.List;

View File

@ -35,7 +35,6 @@ import com.intellectualcrafters.plot.util.SchematicHandler;
import com.intellectualcrafters.plot.util.SchematicHandler.Schematic;
import com.intellectualcrafters.plot.util.TaskManager;
import com.plotsquared.general.commands.CommandDeclaration;
import java.net.URL;
import java.util.ArrayList;
import java.util.Collection;
@ -53,7 +52,7 @@ public class SchematicCmd extends SubCommand {
private boolean running = false;
@Override
public boolean onCommand(final PlotPlayer plr, String... args) {
public boolean onCommand(final PlotPlayer plr, String[] args) {
if (args.length < 1) {
sendMessage(plr, C.SCHEMATIC_MISSING_ARG);
return true;
@ -166,7 +165,7 @@ public class SchematicCmd extends SubCommand {
return false;
}
if (args.length != 2) {
MainUtil.sendMessage(plr, "&cNeed world arg. Use &7/plots sch exportall <area>");
MainUtil.sendMessage(plr, "&cNeed world argument. Use &7/plots sch exportall <area>");
return false;
}
PlotArea area = PS.get().getPlotAreaByString(args[1]);

View File

@ -37,7 +37,6 @@ import com.intellectualcrafters.plot.util.StringMan;
import com.intellectualcrafters.plot.util.WorldUtil;
import com.plotsquared.general.commands.Command;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.HashSet;
@ -159,7 +158,7 @@ public class Set extends SubCommand {
}
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
if (args.length == 0) {
return noArgs(plr);
}

View File

@ -45,7 +45,6 @@ public class SetHome extends SetCommand {
case "remove":
case "none": {
Plot base = plot.getBasePlot(false);
Location bot = base.getBottomAbs();
base.setHome(null);
return MainUtil.sendMessage(plr, C.POSITION_UNSET);
}

View File

@ -34,7 +34,6 @@ import com.intellectualcrafters.plot.util.MainUtil;
import com.intellectualcrafters.plot.util.TaskManager;
import com.intellectualcrafters.plot.util.WorldUtil;
import com.plotsquared.general.commands.CommandDeclaration;
import java.io.File;
import java.io.IOException;
import java.nio.file.Files;

View File

@ -29,7 +29,6 @@ import com.intellectualcrafters.plot.util.Permissions;
import com.intellectualcrafters.plot.util.UUIDHandler;
import com.plotsquared.general.commands.Argument;
import com.plotsquared.general.commands.CommandDeclaration;
import java.util.ArrayList;
import java.util.UUID;
@ -47,7 +46,7 @@ public class Undeny extends SubCommand {
}
@Override
public boolean onCommand(PlotPlayer plr, String... args) {
public boolean onCommand(PlotPlayer plr, String[] args) {
Location loc = plr.getLocation();
Plot plot = loc.getPlotAbs();