mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-22 11:55:38 +01:00
commit
578e884be7
@ -53,7 +53,6 @@ import com.intellectualcrafters.plot.util.WorldUtil;
|
|||||||
import com.intellectualcrafters.plot.util.area.QuadMap;
|
import com.intellectualcrafters.plot.util.area.QuadMap;
|
||||||
import com.plotsquared.listener.WESubscriber;
|
import com.plotsquared.listener.WESubscriber;
|
||||||
import com.sk89q.worldedit.WorldEdit;
|
import com.sk89q.worldedit.WorldEdit;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.FileInputStream;
|
import java.io.FileInputStream;
|
||||||
import java.io.FileOutputStream;
|
import java.io.FileOutputStream;
|
||||||
|
@ -180,7 +180,6 @@ public class Auto extends SubCommand {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
plotarea.setMeta("lastPlot", new PlotId(0, 0));
|
plotarea.setMeta("lastPlot", new PlotId(0, 0));
|
||||||
boolean br = false;
|
|
||||||
while (true) {
|
while (true) {
|
||||||
PlotId start = getNextPlotId(getLastPlotId(plotarea), 1);
|
PlotId start = getNextPlotId(getLastPlotId(plotarea), 1);
|
||||||
PlotId end = new PlotId(start.x + size_x - 1, start.y + size_z - 1);
|
PlotId end = new PlotId(start.x + size_x - 1, start.y + size_z - 1);
|
||||||
|
@ -31,7 +31,6 @@ import com.intellectualcrafters.plot.util.EconHandler;
|
|||||||
import com.intellectualcrafters.plot.util.MainUtil;
|
import com.intellectualcrafters.plot.util.MainUtil;
|
||||||
import com.intellectualcrafters.plot.util.UUIDHandler;
|
import com.intellectualcrafters.plot.util.UUIDHandler;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
@CommandDeclaration(
|
@CommandDeclaration(
|
||||||
@ -45,7 +44,7 @@ import java.util.Set;
|
|||||||
public class Buy extends SubCommand {
|
public class Buy extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer plr, String... args) {
|
public boolean onCommand(PlotPlayer plr, String[] args) {
|
||||||
if (EconHandler.manager == null) {
|
if (EconHandler.manager == null) {
|
||||||
return sendMessage(plr, C.ECON_DISABLED);
|
return sendMessage(plr, C.ECON_DISABLED);
|
||||||
}
|
}
|
||||||
|
@ -13,7 +13,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
|
|||||||
public class Chat extends SubCommand {
|
public class Chat extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@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);
|
MainCommand.getInstance().toggle.chat(this, player, new String[0], null, null);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
@ -40,7 +40,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
|
|||||||
public class Claim extends SubCommand {
|
public class Claim extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer plr, String... args) {
|
public boolean onCommand(PlotPlayer plr, String[] args) {
|
||||||
String schematic = "";
|
String schematic = "";
|
||||||
if (args.length >= 1) {
|
if (args.length >= 1) {
|
||||||
schematic = args[0];
|
schematic = args[0];
|
||||||
|
@ -32,7 +32,6 @@ import com.intellectualcrafters.plot.util.Permissions;
|
|||||||
import com.intellectualcrafters.plot.util.SetQueue;
|
import com.intellectualcrafters.plot.util.SetQueue;
|
||||||
import com.intellectualcrafters.plot.util.TaskManager;
|
import com.intellectualcrafters.plot.util.TaskManager;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
|
|
||||||
@CommandDeclaration(command = "clear",
|
@CommandDeclaration(command = "clear",
|
||||||
@ -45,7 +44,7 @@ import java.util.Set;
|
|||||||
public class Clear extends SubCommand {
|
public class Clear extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(final PlotPlayer plr, String... args) {
|
public boolean onCommand(final PlotPlayer plr, String[] args) {
|
||||||
Location loc = plr.getLocation();
|
Location loc = plr.getLocation();
|
||||||
final Plot plot;
|
final Plot plot;
|
||||||
if (args.length == 1) {
|
if (args.length == 1) {
|
||||||
|
@ -35,7 +35,6 @@ import com.intellectualcrafters.plot.util.MainUtil;
|
|||||||
import com.intellectualcrafters.plot.util.Permissions;
|
import com.intellectualcrafters.plot.util.Permissions;
|
||||||
import com.intellectualcrafters.plot.util.UUIDHandler;
|
import com.intellectualcrafters.plot.util.UUIDHandler;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.Set;
|
import java.util.Set;
|
||||||
@ -50,7 +49,7 @@ import java.util.UUID;
|
|||||||
public class Cluster extends SubCommand {
|
public class Cluster extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@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
|
// list, create, delete, resize, invite, kick, leave, helpers, tp, sethome
|
||||||
if (args.length == 0) {
|
if (args.length == 0) {
|
||||||
|
@ -30,7 +30,6 @@ import com.intellectualcrafters.plot.util.MathMan;
|
|||||||
import com.intellectualcrafters.plot.util.TaskManager;
|
import com.intellectualcrafters.plot.util.TaskManager;
|
||||||
import com.intellectualcrafters.plot.util.WorldUtil;
|
import com.intellectualcrafters.plot.util.WorldUtil;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
@ -49,7 +48,7 @@ public class Condense extends SubCommand {
|
|||||||
public static boolean TASK = false;
|
public static boolean TASK = false;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(final PlotPlayer plr, String... args) {
|
public boolean onCommand(final PlotPlayer plr, String[] args) {
|
||||||
if ((args.length != 2) && (args.length != 3)) {
|
if ((args.length != 2) && (args.length != 3)) {
|
||||||
MainUtil.sendMessage(plr, "/plot condense <area> <start|stop|info> [radius]");
|
MainUtil.sendMessage(plr, "/plot condense <area> <start|stop|info> [radius]");
|
||||||
return false;
|
return false;
|
||||||
|
@ -35,7 +35,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
|
|||||||
public class Confirm extends SubCommand {
|
public class Confirm extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer plr, String... args) {
|
public boolean onCommand(PlotPlayer plr, String[] args) {
|
||||||
CmdInstance command = CmdConfirm.getPending(plr);
|
CmdInstance command = CmdConfirm.getPending(plr);
|
||||||
if (command == null) {
|
if (command == null) {
|
||||||
MainUtil.sendMessage(plr, C.FAILED_CONFIRM);
|
MainUtil.sendMessage(plr, C.FAILED_CONFIRM);
|
||||||
|
@ -40,7 +40,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
|
|||||||
public class CreateRoadSchematic extends SubCommand {
|
public class CreateRoadSchematic extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer player, String... args) {
|
public boolean onCommand(PlotPlayer player, String[] args) {
|
||||||
Location loc = player.getLocation();
|
Location loc = player.getLocation();
|
||||||
Plot plot = loc.getPlotAbs();
|
Plot plot = loc.getPlotAbs();
|
||||||
if (plot == null) {
|
if (plot == null) {
|
||||||
@ -50,7 +50,7 @@ public class CreateRoadSchematic extends SubCommand {
|
|||||||
return sendMessage(player, C.NOT_IN_PLOT_WORLD);
|
return sendMessage(player, C.NOT_IN_PLOT_WORLD);
|
||||||
}
|
}
|
||||||
HybridUtils.manager.setupRoadSchematic(plot);
|
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;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,6 @@ package com.intellectualcrafters.plot.commands;
|
|||||||
import com.intellectualcrafters.plot.config.C;
|
import com.intellectualcrafters.plot.config.C;
|
||||||
import com.intellectualcrafters.plot.object.PlotPlayer;
|
import com.intellectualcrafters.plot.object.PlotPlayer;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
@ -20,7 +19,7 @@ public class DebugAllowUnsafe extends SubCommand {
|
|||||||
public static final List<UUID> unsafeAllowed = new ArrayList<>();
|
public static final List<UUID> unsafeAllowed = new ArrayList<>();
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer plr, String... args) {
|
public boolean onCommand(PlotPlayer plr, String[] args) {
|
||||||
|
|
||||||
if (unsafeAllowed.contains(plr.getUUID())) {
|
if (unsafeAllowed.contains(plr.getUUID())) {
|
||||||
unsafeAllowed.remove(plr.getUUID());
|
unsafeAllowed.remove(plr.getUUID());
|
||||||
|
@ -56,7 +56,6 @@ import com.intellectualcrafters.plot.util.WorldUtil;
|
|||||||
import com.plotsquared.general.commands.Command;
|
import com.plotsquared.general.commands.Command;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
import com.plotsquared.listener.WEManager;
|
import com.plotsquared.listener.WEManager;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.nio.charset.StandardCharsets;
|
import java.nio.charset.StandardCharsets;
|
||||||
@ -65,7 +64,6 @@ import java.util.Arrays;
|
|||||||
import java.util.Date;
|
import java.util.Date;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
import javax.script.Bindings;
|
import javax.script.Bindings;
|
||||||
import javax.script.ScriptContext;
|
import javax.script.ScriptContext;
|
||||||
import javax.script.ScriptEngine;
|
import javax.script.ScriptEngine;
|
||||||
@ -165,7 +163,7 @@ public class DebugExec extends SubCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(final PlotPlayer player, String... args) {
|
public boolean onCommand(final PlotPlayer player, String[] args) {
|
||||||
java.util.List<String> allowed_params =
|
java.util.List<String> allowed_params =
|
||||||
Arrays.asList("calibrate-analysis", "remove-flag", "stop-expire", "start-expire", "show-expired", "update-expired", "seen");
|
Arrays.asList("calibrate-analysis", "remove-flag", "stop-expire", "start-expire", "show-expired", "update-expired", "seen");
|
||||||
if (args.length > 0) {
|
if (args.length > 0) {
|
||||||
|
@ -43,7 +43,7 @@ import com.plotsquared.general.commands.CommandDeclaration;
|
|||||||
public class DebugRoadRegen extends SubCommand {
|
public class DebugRoadRegen extends SubCommand {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer player, String... args) {
|
public boolean onCommand(PlotPlayer player, String[] args) {
|
||||||
Location loc = player.getLocation();
|
Location loc = player.getLocation();
|
||||||
PlotArea plotworld = loc.getPlotArea();
|
PlotArea plotworld = loc.getPlotArea();
|
||||||
if (!(plotworld instanceof HybridPlotWorld)) {
|
if (!(plotworld instanceof HybridPlotWorld)) {
|
||||||
|
@ -33,7 +33,6 @@ import com.intellectualcrafters.plot.util.MainUtil;
|
|||||||
import com.intellectualcrafters.plot.util.Permissions;
|
import com.intellectualcrafters.plot.util.Permissions;
|
||||||
import com.intellectualcrafters.plot.util.StringMan;
|
import com.intellectualcrafters.plot.util.StringMan;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
@ -55,8 +54,8 @@ public class FlagCmd extends SubCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer player, String... args) {
|
public boolean onCommand(PlotPlayer player, String[] args) {
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* plot flag set fly true
|
* plot flag set fly true
|
||||||
* plot flag remove fly
|
* plot flag remove fly
|
||||||
|
@ -30,7 +30,6 @@ import com.intellectualcrafters.plot.util.CommentManager;
|
|||||||
import com.intellectualcrafters.plot.util.MainUtil;
|
import com.intellectualcrafters.plot.util.MainUtil;
|
||||||
import com.intellectualcrafters.plot.util.StringMan;
|
import com.intellectualcrafters.plot.util.StringMan;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
@ -35,7 +35,6 @@ import com.intellectualcrafters.plot.util.SchematicHandler;
|
|||||||
import com.intellectualcrafters.plot.util.SchematicHandler.Schematic;
|
import com.intellectualcrafters.plot.util.SchematicHandler.Schematic;
|
||||||
import com.intellectualcrafters.plot.util.TaskManager;
|
import com.intellectualcrafters.plot.util.TaskManager;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.net.URL;
|
import java.net.URL;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
@ -53,7 +52,7 @@ public class SchematicCmd extends SubCommand {
|
|||||||
private boolean running = false;
|
private boolean running = false;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(final PlotPlayer plr, String... args) {
|
public boolean onCommand(final PlotPlayer plr, String[] args) {
|
||||||
if (args.length < 1) {
|
if (args.length < 1) {
|
||||||
sendMessage(plr, C.SCHEMATIC_MISSING_ARG);
|
sendMessage(plr, C.SCHEMATIC_MISSING_ARG);
|
||||||
return true;
|
return true;
|
||||||
@ -166,7 +165,7 @@ public class SchematicCmd extends SubCommand {
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (args.length != 2) {
|
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;
|
return false;
|
||||||
}
|
}
|
||||||
PlotArea area = PS.get().getPlotAreaByString(args[1]);
|
PlotArea area = PS.get().getPlotAreaByString(args[1]);
|
||||||
|
@ -37,7 +37,6 @@ import com.intellectualcrafters.plot.util.StringMan;
|
|||||||
import com.intellectualcrafters.plot.util.WorldUtil;
|
import com.intellectualcrafters.plot.util.WorldUtil;
|
||||||
import com.plotsquared.general.commands.Command;
|
import com.plotsquared.general.commands.Command;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
@ -159,7 +158,7 @@ public class Set extends SubCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer plr, String... args) {
|
public boolean onCommand(PlotPlayer plr, String[] args) {
|
||||||
if (args.length == 0) {
|
if (args.length == 0) {
|
||||||
return noArgs(plr);
|
return noArgs(plr);
|
||||||
}
|
}
|
||||||
|
@ -45,7 +45,6 @@ public class SetHome extends SetCommand {
|
|||||||
case "remove":
|
case "remove":
|
||||||
case "none": {
|
case "none": {
|
||||||
Plot base = plot.getBasePlot(false);
|
Plot base = plot.getBasePlot(false);
|
||||||
Location bot = base.getBottomAbs();
|
|
||||||
base.setHome(null);
|
base.setHome(null);
|
||||||
return MainUtil.sendMessage(plr, C.POSITION_UNSET);
|
return MainUtil.sendMessage(plr, C.POSITION_UNSET);
|
||||||
}
|
}
|
||||||
|
@ -34,7 +34,6 @@ import com.intellectualcrafters.plot.util.MainUtil;
|
|||||||
import com.intellectualcrafters.plot.util.TaskManager;
|
import com.intellectualcrafters.plot.util.TaskManager;
|
||||||
import com.intellectualcrafters.plot.util.WorldUtil;
|
import com.intellectualcrafters.plot.util.WorldUtil;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.nio.file.Files;
|
import java.nio.file.Files;
|
||||||
|
@ -29,7 +29,6 @@ import com.intellectualcrafters.plot.util.Permissions;
|
|||||||
import com.intellectualcrafters.plot.util.UUIDHandler;
|
import com.intellectualcrafters.plot.util.UUIDHandler;
|
||||||
import com.plotsquared.general.commands.Argument;
|
import com.plotsquared.general.commands.Argument;
|
||||||
import com.plotsquared.general.commands.CommandDeclaration;
|
import com.plotsquared.general.commands.CommandDeclaration;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
@ -47,7 +46,7 @@ public class Undeny extends SubCommand {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onCommand(PlotPlayer plr, String... args) {
|
public boolean onCommand(PlotPlayer plr, String[] args) {
|
||||||
|
|
||||||
Location loc = plr.getLocation();
|
Location loc = plr.getLocation();
|
||||||
Plot plot = loc.getPlotAbs();
|
Plot plot = loc.getPlotAbs();
|
||||||
|
Loading…
Reference in New Issue
Block a user