mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-26 15:16:45 +01:00
Remove debug
This commit is contained in:
parent
699906476c
commit
f2b050444c
@ -963,11 +963,6 @@ public class PlotSquared {
|
|||||||
}
|
}
|
||||||
Settings.CONSOLE_COLOR = config.getBoolean("console.color");
|
Settings.CONSOLE_COLOR = config.getBoolean("console.color");
|
||||||
if (!config.getBoolean("chat.fancy") || !IMP.checkVersion(1, 7, 0)) {
|
if (!config.getBoolean("chat.fancy") || !IMP.checkVersion(1, 7, 0)) {
|
||||||
System.out.print("FANCY CHAT =======================================");
|
|
||||||
System.out.print("FANCY CHAT =======================================");
|
|
||||||
System.out.print("FANCY CHAT =======================================");
|
|
||||||
System.out.print(!config.getBoolean("chat.fancy"));
|
|
||||||
System.out.print(!IMP.checkVersion(1, 7, 0));
|
|
||||||
Settings.FANCY_CHAT = false;
|
Settings.FANCY_CHAT = false;
|
||||||
}
|
}
|
||||||
Settings.METRICS = config.getBoolean("metrics");
|
Settings.METRICS = config.getBoolean("metrics");
|
||||||
|
@ -56,9 +56,11 @@ public class Info extends SubCommand {
|
|||||||
public boolean execute(final PlotPlayer player, String... args) {
|
public boolean execute(final PlotPlayer player, String... args) {
|
||||||
String arg = null;
|
String arg = null;
|
||||||
if (args.length > 0) arg = args[0] + "";
|
if (args.length > 0) arg = args[0] + "";
|
||||||
|
if (arg != null) {
|
||||||
switch (arg) {
|
switch (arg) {
|
||||||
case "trusted":
|
case "trusted":
|
||||||
case "alias":
|
case "alias":
|
||||||
|
case "inv":
|
||||||
case "biome":
|
case "biome":
|
||||||
case "denied":
|
case "denied":
|
||||||
case "flags":
|
case "flags":
|
||||||
@ -69,7 +71,8 @@ public class Info extends SubCommand {
|
|||||||
case "rating":
|
case "rating":
|
||||||
arg = null;
|
arg = null;
|
||||||
}
|
}
|
||||||
Plot plot = MainUtil.getPlotFromString(player, arg, true);
|
}
|
||||||
|
Plot plot = MainUtil.getPlotFromString(player, arg, false);
|
||||||
if (plot == null) {
|
if (plot == null) {
|
||||||
if (player == null) {
|
if (player == null) {
|
||||||
return false;
|
return false;
|
||||||
|
@ -264,7 +264,7 @@ public class list extends SubCommand {
|
|||||||
if (page > totalPages) {
|
if (page > totalPages) {
|
||||||
page = totalPages;
|
page = totalPages;
|
||||||
}
|
}
|
||||||
// Only display 12!
|
// Only display pageSize!
|
||||||
int max = (page * pageSize) + pageSize;
|
int max = (page * pageSize) + pageSize;
|
||||||
if (max > plots.size()) {
|
if (max > plots.size()) {
|
||||||
max = plots.size();
|
max = plots.size();
|
||||||
@ -333,8 +333,8 @@ public class list extends SubCommand {
|
|||||||
.then("[")
|
.then("[")
|
||||||
.color(ChatColor.DARK_GRAY)
|
.color(ChatColor.DARK_GRAY)
|
||||||
.then(i + "")
|
.then(i + "")
|
||||||
.command("/plot visit " + plot.toString())
|
.command("/plot visit " + plot.world + ";" + plot.id)
|
||||||
.tooltip("/plot visit " + plot.toString())
|
.tooltip("/plot visit " + plot.world + ";" + plot.id)
|
||||||
.color(ChatColor.GOLD)
|
.color(ChatColor.GOLD)
|
||||||
.then("]")
|
.then("]")
|
||||||
|
|
||||||
@ -344,7 +344,7 @@ public class list extends SubCommand {
|
|||||||
.then(" " + plot.toString())
|
.then(" " + plot.toString())
|
||||||
|
|
||||||
.formattedTooltip(trusted, members, flags)
|
.formattedTooltip(trusted, members, flags)
|
||||||
.command("/plot info " + plot.toString())
|
.command("/plot info " + plot.world + ";" + plot.id)
|
||||||
|
|
||||||
.color(color)
|
.color(color)
|
||||||
.then(" - ")
|
.then(" - ")
|
||||||
@ -412,7 +412,7 @@ public class list extends SubCommand {
|
|||||||
.send(((BukkitPlayer) player).player);
|
.send(((BukkitPlayer) player).player);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (page == 0) {
|
if (page == 0 && totalPages != 0) {
|
||||||
// next
|
// next
|
||||||
new FancyMessage("")
|
new FancyMessage("")
|
||||||
.then("<-")
|
.then("<-")
|
||||||
@ -425,7 +425,7 @@ public class list extends SubCommand {
|
|||||||
.send(((BukkitPlayer) player).player);
|
.send(((BukkitPlayer) player).player);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (page == totalPages) {
|
if (page == totalPages && totalPages != 0) {
|
||||||
// back
|
// back
|
||||||
new FancyMessage("")
|
new FancyMessage("")
|
||||||
.then("<-")
|
.then("<-")
|
||||||
|
@ -222,24 +222,19 @@ public class UUIDHandler {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static String getName(final UUID uuid) {
|
public static String getName(final UUID uuid) {
|
||||||
System.out.print(uuid);
|
|
||||||
if (uuid == null) {
|
if (uuid == null) {
|
||||||
System.out.print(1);
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
// check online
|
// check online
|
||||||
final PlotPlayer player = UUIDHandler.getPlayer(uuid);
|
final PlotPlayer player = UUIDHandler.getPlayer(uuid);
|
||||||
if (player != null) {
|
if (player != null) {
|
||||||
System.out.print(2);
|
|
||||||
return player.getName();
|
return player.getName();
|
||||||
}
|
}
|
||||||
// check cache
|
// check cache
|
||||||
final StringWrapper name = UUIDHandler.uuidMap.inverse().get(uuid);
|
final StringWrapper name = UUIDHandler.uuidMap.inverse().get(uuid);
|
||||||
if (name != null) {
|
if (name != null) {
|
||||||
System.out.print(3);
|
|
||||||
return name.value;
|
return name.value;
|
||||||
}
|
}
|
||||||
System.out.print(4);
|
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user