From c745b99922a88e6c93fe6924eff0a5cec9c3113a Mon Sep 17 00:00:00 2001 From: Timon Date: Thu, 6 Aug 2020 12:01:43 +0200 Subject: [PATCH 01/12] Added UseFlag check at Roads --- .../com/plotsquared/core/util/EventDispatcher.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java b/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java index 23d5dd15f..b495fb212 100644 --- a/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java +++ b/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java @@ -279,6 +279,12 @@ public class EventDispatcher { return true; case INTERACT_BLOCK: { if (plot == null) { + final List use = area.getRoadFlag(UseFlag.class); + for(final BlockTypeWrapper blockTypeWrapper : use) { + if (blockTypeWrapper.accepts(BlockTypes.AIR) || blockTypeWrapper.accepts(blockType)) { + return true; + } + } return Permissions.hasPermission(player, Captions.PERMISSION_ADMIN_INTERACT_ROAD.getTranslated(), notifyPerms); } @@ -301,6 +307,12 @@ public class EventDispatcher { } case TRIGGER_PHYSICAL: { if (plot == null) { + final List use = area.getRoadFlag(UseFlag.class); + for(final BlockTypeWrapper blockTypeWrapper : use) { + if (blockTypeWrapper.accepts(BlockTypes.AIR) || blockTypeWrapper.accepts(blockType)) { + return true; + } + } return Permissions.hasPermission(player, Captions.PERMISSION_ADMIN_INTERACT_ROAD.getTranslated(), false); } From 48d3c2105d71219948b55d2fe9f7d227e2b15049 Mon Sep 17 00:00:00 2001 From: MeFisto94 Date: Thu, 6 Aug 2020 13:56:58 +0200 Subject: [PATCH 02/12] Fixes an OfflinePlayerUtil breakage caused by NMS Changes --- .../bukkit/util/OfflinePlayerUtil.java | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java b/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java index 41ae4dedd..197b05cd6 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java @@ -97,6 +97,17 @@ public class OfflinePlayerUtil { return callConstructor(c, worldServer); } + public static Object getWorldServer116() { + Object server = getMinecraftServer(); + Class minecraftServerClass = getNmsClass("MinecraftServer"); + Class dimensionManager = getNmsClass("DimensionManager"); + Class genericResourceKey = getNmsClass("ResourceKey"); + Object overworld = getField(makeField(dimensionManager, "OVERWORLD"), null); + Method getWorldServer = + makeMethod(minecraftServerClass, "getWorldServer", genericResourceKey); + return callMethod(getWorldServer, server, overworld); + } + public static Object getWorldServerNew() { Object server = getMinecraftServer(); Class minecraftServerClass = getNmsClass("MinecraftServer"); @@ -115,7 +126,11 @@ public class OfflinePlayerUtil { try { o = callMethod(getWorldServer, server, 0); } catch (final RuntimeException e) { - o = getWorldServerNew(); + try { + o = getWorldServerNew(); + } catch (final RuntimeException f) { + o = getWorldServer116(); + } } return o; } From b46a19f5ca7255c6d6f4fef9cabbb4493b158930 Mon Sep 17 00:00:00 2001 From: EinDev Date: Sat, 8 Aug 2020 18:07:49 +0200 Subject: [PATCH 03/12] Keep player names, so they don't have to be looked up again. That way the lookup function MainUtil#getName won't get called which would throw an exception if called in the Bukkit Thread. As the player enters the Name, we don't have to look it up again. Fixes PS-96 --- .../com/plotsquared/core/command/Add.java | 39 +++++++++++-------- .../com/plotsquared/core/command/Deny.java | 30 +++++++------- .../com/plotsquared/core/command/Kick.java | 8 ++-- .../com/plotsquared/core/command/Remove.java | 36 ++++++++--------- .../com/plotsquared/core/command/Trust.java | 34 ++++++++-------- .../com/plotsquared/core/util/MainUtil.java | 27 ++++++------- 6 files changed, 88 insertions(+), 86 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Add.java b/Core/src/main/java/com/plotsquared/core/command/Add.java index 6d86f7532..f3e5015ca 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Add.java +++ b/Core/src/main/java/com/plotsquared/core/command/Add.java @@ -35,11 +35,11 @@ import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.TabCompletions; import com.plotsquared.core.util.task.RunnableVal2; import com.plotsquared.core.util.task.RunnableVal3; +import com.plotsquared.core.uuid.UUIDMapping; import java.util.Collection; import java.util.Collections; import java.util.Iterator; -import java.util.UUID; import java.util.concurrent.CompletableFuture; import java.util.concurrent.TimeoutException; @@ -79,44 +79,49 @@ public class Add extends Command { } else { try { checkTrue(!uuids.isEmpty(), Captions.INVALID_PLAYER, args[0]); - Iterator iterator = uuids.iterator(); + + Iterator iterator = uuids.iterator(); int size = plot.getTrusted().size() + plot.getMembers().size(); while (iterator.hasNext()) { - UUID uuid = iterator.next(); - if (uuid == DBFunc.EVERYONE && !( + UUIDMapping uuidMapping = iterator.next(); + if (uuidMapping.getUuid() == DBFunc.EVERYONE && !( Permissions.hasPermission(player, Captions.PERMISSION_TRUST_EVERYONE) || Permissions .hasPermission(player, Captions.PERMISSION_ADMIN_COMMAND_TRUST))) { - MainUtil.sendMessage(player, Captions.INVALID_PLAYER, MainUtil.getName(uuid)); + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, uuidMapping.getUsername()); iterator.remove(); continue; } - if (plot.isOwner(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); + if (plot.isOwner(uuidMapping.getUuid())) { + new Thread(() -> + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, uuidMapping.getUsername()) + ).start(); iterator.remove(); continue; } - if (plot.getMembers().contains(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); + if (plot.getMembers().contains(uuidMapping.getUuid())) { + new Thread(() -> + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, uuidMapping.getUsername()) + ).start(); iterator.remove(); continue; } - size += plot.getTrusted().contains(uuid) ? 0 : 1; + size += plot.getTrusted().contains(uuidMapping.getUuid()) ? 0 : 1; } checkTrue(!uuids.isEmpty(), null); checkTrue(size <= plot.getArea().getMaxPlotMembers() || Permissions.hasPermission(player, Captions.PERMISSION_ADMIN_COMMAND_TRUST), Captions.PLOT_MAX_MEMBERS); // Success confirm.run(this, () -> { - for (UUID uuid : uuids) { - if (uuid != DBFunc.EVERYONE) { - if (!plot.removeTrusted(uuid)) { - if (plot.getDenied().contains(uuid)) { - plot.removeDenied(uuid); + for (UUIDMapping uuidMapping : uuids) { + if (uuidMapping.getUuid() != DBFunc.EVERYONE) { + if (!plot.removeTrusted(uuidMapping.getUuid())) { + if (plot.getDenied().contains(uuidMapping.getUuid())) { + plot.removeDenied(uuidMapping.getUuid()); } } } - plot.addMember(uuid); - PlotSquared.get().getEventDispatcher().callMember(player, plot, uuid, true); + plot.addMember(uuidMapping.getUuid()); + PlotSquared.get().getEventDispatcher().callMember(player, plot, uuidMapping.getUuid(), true); MainUtil.sendMessage(player, Captions.MEMBER_ADDED); } }, null); diff --git a/Core/src/main/java/com/plotsquared/core/command/Deny.java b/Core/src/main/java/com/plotsquared/core/command/Deny.java index 1cb862304..e1b2536f1 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Deny.java +++ b/Core/src/main/java/com/plotsquared/core/command/Deny.java @@ -35,11 +35,11 @@ import com.plotsquared.core.util.MainUtil; import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.TabCompletions; import com.plotsquared.core.util.WorldUtil; +import com.plotsquared.core.uuid.UUIDMapping; import com.sk89q.worldedit.world.gamemode.GameModes; import java.util.Collection; import java.util.Collections; -import java.util.UUID; import java.util.concurrent.TimeoutException; @CommandDeclaration(command = "deny", @@ -77,26 +77,26 @@ public class Deny extends SubCommand { } else if (throwable != null || uuids.isEmpty()) { MainUtil.sendMessage(player, Captions.INVALID_PLAYER, args[0]); } else { - for (UUID uuid : uuids) { - if (uuid == DBFunc.EVERYONE && !( + for (UUIDMapping uuidMapping : uuids) { + if (uuidMapping.getUuid() == DBFunc.EVERYONE && !( Permissions.hasPermission(player, Captions.PERMISSION_DENY_EVERYONE) || Permissions .hasPermission(player, Captions.PERMISSION_ADMIN_COMMAND_DENY))) { - MainUtil.sendMessage(player, Captions.INVALID_PLAYER, MainUtil.getName(uuid)); - } else if (plot.isOwner(uuid)) { - MainUtil.sendMessage(player, Captions.CANT_REMOVE_OWNER, MainUtil.getName(uuid)); + MainUtil.sendMessage(player, Captions.INVALID_PLAYER, uuidMapping.getUsername()); + } else if (plot.isOwner(uuidMapping.getUuid())) { + MainUtil.sendMessage(player, Captions.CANT_REMOVE_OWNER, uuidMapping.getUsername()); return; - } else if (plot.getDenied().contains(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); + } else if (plot.getDenied().contains(uuidMapping.getUuid())) { + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, uuidMapping.getUsername()); return; } else { - if (uuid != DBFunc.EVERYONE) { - plot.removeMember(uuid); - plot.removeTrusted(uuid); + if (uuidMapping.getUuid() != DBFunc.EVERYONE) { + plot.removeMember(uuidMapping.getUuid()); + plot.removeTrusted(uuidMapping.getUuid()); } - plot.addDenied(uuid); - PlotSquared.get().getEventDispatcher().callDenied(player, plot, uuid, true); - if (!uuid.equals(DBFunc.EVERYONE)) { - handleKick(PlotSquared.imp().getPlayerManager().getPlayerIfExists(uuid), plot); + plot.addDenied(uuidMapping.getUuid()); + PlotSquared.get().getEventDispatcher().callDenied(player, plot, uuidMapping.getUuid(), true); + if (!uuidMapping.equals(DBFunc.EVERYONE)) { + handleKick(PlotSquared.imp().getPlayerManager().getPlayerIfExists(uuidMapping.getUuid()), plot); } else { for (PlotPlayer plotPlayer : plot.getPlayersInPlot()) { // Ignore plot-owners diff --git a/Core/src/main/java/com/plotsquared/core/command/Kick.java b/Core/src/main/java/com/plotsquared/core/command/Kick.java index 911ea9810..810051a4c 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Kick.java +++ b/Core/src/main/java/com/plotsquared/core/command/Kick.java @@ -35,12 +35,12 @@ import com.plotsquared.core.util.MainUtil; import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.TabCompletions; import com.plotsquared.core.util.WorldUtil; +import com.plotsquared.core.uuid.UUIDMapping; import java.util.Collection; import java.util.Collections; import java.util.HashSet; import java.util.Set; -import java.util.UUID; import java.util.concurrent.TimeoutException; @CommandDeclaration(command = "kick", @@ -75,8 +75,8 @@ public class Kick extends SubCommand { MainUtil.sendMessage(player, Captions.INVALID_PLAYER, args[0]); } else { Set> players = new HashSet<>(); - for (UUID uuid : uuids) { - if (uuid == DBFunc.EVERYONE) { + for (UUIDMapping uuidMapping : uuids) { + if (uuidMapping.getUuid() == DBFunc.EVERYONE) { for (PlotPlayer pp : plot.getPlayersInPlot()) { if (pp == player || Permissions .hasPermission(pp, Captions.PERMISSION_ADMIN_ENTRY_DENIED)) { @@ -86,7 +86,7 @@ public class Kick extends SubCommand { } continue; } - PlotPlayer pp = PlotSquared.imp().getPlayerManager().getPlayerIfExists(uuid); + PlotPlayer pp = PlotSquared.imp().getPlayerManager().getPlayerIfExists(uuidMapping.getUuid()); if (pp != null) { players.add(pp); } diff --git a/Core/src/main/java/com/plotsquared/core/command/Remove.java b/Core/src/main/java/com/plotsquared/core/command/Remove.java index 871bd2b60..1c2797941 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Remove.java +++ b/Core/src/main/java/com/plotsquared/core/command/Remove.java @@ -34,10 +34,10 @@ import com.plotsquared.core.plot.Plot; import com.plotsquared.core.util.MainUtil; import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.TabCompletions; +import com.plotsquared.core.uuid.UUIDMapping; import java.util.Collection; import java.util.Collections; -import java.util.UUID; import java.util.concurrent.TimeoutException; @CommandDeclaration(command = "remove", @@ -78,37 +78,37 @@ public class Remove extends SubCommand { MainUtil.sendMessage(player, Captions.INVALID_PLAYER, args[0]); return; } else if (!uuids.isEmpty()) { - for (UUID uuid : uuids) { - if (plot.getTrusted().contains(uuid)) { - if (plot.removeTrusted(uuid)) { + for (UUIDMapping uuidMapping : uuids) { + if (plot.getTrusted().contains(uuidMapping.getUuid())) { + if (plot.removeTrusted(uuidMapping.getUuid())) { PlotSquared.get().getEventDispatcher() - .callTrusted(player, plot, uuid, false); + .callTrusted(player, plot, uuidMapping.getUuid(), false); count++; } - } else if (plot.getMembers().contains(uuid)) { - if (plot.removeMember(uuid)) { + } else if (plot.getMembers().contains(uuidMapping.getUuid())) { + if (plot.removeMember(uuidMapping.getUuid())) { PlotSquared.get().getEventDispatcher() - .callMember(player, plot, uuid, false); + .callMember(player, plot, uuidMapping.getUuid(), false); count++; } - } else if (plot.getDenied().contains(uuid)) { - if (plot.removeDenied(uuid)) { + } else if (plot.getDenied().contains(uuidMapping.getUuid())) { + if (plot.removeDenied(uuidMapping.getUuid())) { PlotSquared.get().getEventDispatcher() - .callDenied(player, plot, uuid, false); + .callDenied(player, plot, uuidMapping.getUuid(), false); count++; } - } else if (uuid == DBFunc.EVERYONE) { - if (plot.removeTrusted(uuid)) { + } else if (uuidMapping.getUuid() == DBFunc.EVERYONE) { + if (plot.removeTrusted(uuidMapping.getUuid())) { PlotSquared.get().getEventDispatcher() - .callTrusted(player, plot, uuid, false); + .callTrusted(player, plot, uuidMapping.getUuid(), false); count++; - } else if (plot.removeMember(uuid)) { + } else if (plot.removeMember(uuidMapping.getUuid())) { PlotSquared.get().getEventDispatcher() - .callMember(player, plot, uuid, false); + .callMember(player, plot, uuidMapping.getUuid(), false); count++; - } else if (plot.removeDenied(uuid)) { + } else if (plot.removeDenied(uuidMapping.getUuid())) { PlotSquared.get().getEventDispatcher() - .callDenied(player, plot, uuid, false); + .callDenied(player, plot, uuidMapping.getUuid(), false); count++; } } diff --git a/Core/src/main/java/com/plotsquared/core/command/Trust.java b/Core/src/main/java/com/plotsquared/core/command/Trust.java index 1c4064543..066a02278 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Trust.java +++ b/Core/src/main/java/com/plotsquared/core/command/Trust.java @@ -35,11 +35,11 @@ import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.TabCompletions; import com.plotsquared.core.util.task.RunnableVal2; import com.plotsquared.core.util.task.RunnableVal3; +import com.plotsquared.core.uuid.UUIDMapping; import java.util.Collection; import java.util.Collections; import java.util.Iterator; -import java.util.UUID; import java.util.concurrent.CompletableFuture; import java.util.concurrent.TimeoutException; @@ -81,28 +81,28 @@ public class Trust extends Command { return; } else { checkTrue(!uuids.isEmpty(), Captions.INVALID_PLAYER, args[0]); - Iterator iterator = uuids.iterator(); + Iterator iterator = uuids.iterator(); int size = currentPlot.getTrusted().size() + currentPlot.getMembers().size(); while (iterator.hasNext()) { - UUID uuid = iterator.next(); - if (uuid == DBFunc.EVERYONE && !( + UUIDMapping uuidMapping = iterator.next(); + if (uuidMapping.getUuid() == DBFunc.EVERYONE && !( Permissions.hasPermission(player, Captions.PERMISSION_TRUST_EVERYONE) || Permissions .hasPermission(player, Captions.PERMISSION_ADMIN_COMMAND_TRUST))) { - MainUtil.sendMessage(player, Captions.INVALID_PLAYER, MainUtil.getName(uuid)); + MainUtil.sendMessage(player, Captions.INVALID_PLAYER, uuidMapping.getUsername()); iterator.remove(); continue; } - if (currentPlot.isOwner(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); + if (currentPlot.isOwner(uuidMapping.getUuid())) { + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, uuidMapping.getUsername()); iterator.remove(); continue; } - if (currentPlot.getTrusted().contains(uuid)) { - MainUtil.sendMessage(player, Captions.ALREADY_ADDED, MainUtil.getName(uuid)); + if (currentPlot.getTrusted().contains(uuidMapping.getUuid())) { + MainUtil.sendMessage(player, Captions.ALREADY_ADDED, uuidMapping.getUsername()); iterator.remove(); continue; } - size += currentPlot.getMembers().contains(uuid) ? 0 : 1; + size += currentPlot.getMembers().contains(uuidMapping.getUuid()) ? 0 : 1; } checkTrue(!uuids.isEmpty(), null); checkTrue(size <= currentPlot.getArea().getMaxPlotMembers() || Permissions @@ -110,16 +110,16 @@ public class Trust extends Command { Captions.PLOT_MAX_MEMBERS); // Success confirm.run(this, () -> { - for (UUID uuid : uuids) { - if (uuid != DBFunc.EVERYONE) { - if (!currentPlot.removeMember(uuid)) { - if (currentPlot.getDenied().contains(uuid)) { - currentPlot.removeDenied(uuid); + for (UUIDMapping uuidMapping : uuids) { + if (uuidMapping.getUuid() != DBFunc.EVERYONE) { + if (!currentPlot.removeMember(uuidMapping.getUuid())) { + if (currentPlot.getDenied().contains(uuidMapping.getUuid())) { + currentPlot.removeDenied(uuidMapping.getUuid()); } } } - currentPlot.addTrusted(uuid); - PlotSquared.get().getEventDispatcher().callTrusted(player, currentPlot, uuid, true); + currentPlot.addTrusted(uuidMapping.getUuid()); + PlotSquared.get().getEventDispatcher().callTrusted(player, currentPlot, uuidMapping.getUuid(), true); MainUtil.sendMessage(player, Captions.TRUSTED_ADDED); } }, null); diff --git a/Core/src/main/java/com/plotsquared/core/util/MainUtil.java b/Core/src/main/java/com/plotsquared/core/util/MainUtil.java index 9f79f3273..a56e3e1b2 100644 --- a/Core/src/main/java/com/plotsquared/core/util/MainUtil.java +++ b/Core/src/main/java/com/plotsquared/core/util/MainUtil.java @@ -748,10 +748,9 @@ public class MainUtil { return ratings; } - public static void getUUIDsFromString(final String list, final BiConsumer, Throwable> consumer) { + public static void getUUIDsFromString(final String list, final BiConsumer, Throwable> consumer) { String[] split = list.split(","); - - final Set result = new HashSet<>(); + final Set result = new HashSet<>(); final List request = new LinkedList<>(); for (final String name : split) { @@ -759,10 +758,10 @@ public class MainUtil { consumer.accept(Collections.emptySet(), null); return; } else if ("*".equals(name)) { - result.add(DBFunc.EVERYONE); + result.add(new UUIDMapping(DBFunc.EVERYONE, "*")); } else if (name.length() > 16) { try { - result.add(UUID.fromString(name)); + result.add(new UUIDMapping(UUID.fromString(name), name)); } catch (IllegalArgumentException ignored) { consumer.accept(Collections.emptySet(), null); return; @@ -776,16 +775,14 @@ public class MainUtil { consumer.accept(result, null); } else { PlotSquared.get().getImpromptuUUIDPipeline().getUUIDs(request, Settings.UUID.NON_BLOCKING_TIMEOUT) - .whenComplete((uuids, throwable) -> { - if (throwable != null) { - consumer.accept(null, throwable); - } else { - for (final UUIDMapping uuid : uuids) { - result.add(uuid.getUuid()); - } - consumer.accept(result, null); - } - }); + .whenComplete((uuids, throwable) -> { + if (throwable != null) { + consumer.accept(null, throwable); + } else { + result.addAll(uuids); + consumer.accept(result, null); + } + }); } } From 7c756304b55f57f44d05a398eeedec4fbf8abb44 Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Tue, 11 Aug 2020 16:20:33 +0200 Subject: [PATCH 04/12] 1.16.2 support - Bump EssentialsX version to the latest release --- Bukkit/build.gradle | 6 +++--- Bukkit/pom.xml | 6 +++--- Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java | 1 + .../plotsquared/bukkit/entity/ReplicatingEntityWrapper.java | 2 ++ build.gradle | 1 - 5 files changed, 9 insertions(+), 7 deletions(-) diff --git a/Bukkit/build.gradle b/Bukkit/build.gradle index 61842d3ce..2a8fd96f2 100644 --- a/Bukkit/build.gradle +++ b/Bukkit/build.gradle @@ -23,8 +23,8 @@ dependencies { implementation(project(":PlotSquared-Core")) compile("org.bstats:bstats-bukkit:1.7") compile(project(":PlotSquared-Core")) - compile("com.destroystokyo.paper:paper-api:1.16.1-R0.1-SNAPSHOT") - implementation("org.spigotmc:spigot-api:1.16.1-R0.1-SNAPSHOT") + compile("com.destroystokyo.paper:paper-api:1.16.2-R0.1-SNAPSHOT") + implementation("org.spigotmc:spigot-api:1.16.2-R0.1-SNAPSHOT") compile(group: "com.sk89q.worldedit", name: "worldedit-bukkit", version: "7.1.0") { exclude(module: "bukkit") @@ -36,7 +36,7 @@ dependencies { } implementation("me.clip:placeholderapi:2.10.6") implementation("net.luckperms:api:5.1") - implementation("net.ess3:EssentialsX:2.17.2") { + implementation("net.ess3:EssentialsX:2.18.0") { exclude(group: "io.papermc", module: "paperlib") } implementation("net.alpenblock:BungeePerms:4.0-dev-106") diff --git a/Bukkit/pom.xml b/Bukkit/pom.xml index 26f8a6607..f52aab5f4 100644 --- a/Bukkit/pom.xml +++ b/Bukkit/pom.xml @@ -27,7 +27,7 @@ com.destroystokyo.paper paper-api - 1.16.1-R0.1-SNAPSHOT + 1.16.2-R0.1-SNAPSHOT compile @@ -149,7 +149,7 @@ org.spigotmc spigot-api - 1.16.1-R0.1-SNAPSHOT + 1.16.2-R0.1-SNAPSHOT runtime @@ -173,7 +173,7 @@ net.ess3 EssentialsX - 2.17.2 + 2.18.0 runtime diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java index f499f5d16..34cbcc5b3 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java @@ -770,6 +770,7 @@ public final class BukkitMain extends JavaPlugin implements Listener, IPlotMain< } continue; case "ZOMBIFIED_PIGLIN": + case "PIGLIN_BRUTE": case "LLAMA": case "DONKEY": case "MULE": diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/entity/ReplicatingEntityWrapper.java b/Bukkit/src/main/java/com/plotsquared/bukkit/entity/ReplicatingEntityWrapper.java index 83740e9db..d82c274e9 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/entity/ReplicatingEntityWrapper.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/entity/ReplicatingEntityWrapper.java @@ -310,6 +310,7 @@ public final class ReplicatingEntityWrapper extends EntityWrapper { case "HOGLIN": case "ZOMBIFIED_PIGLIN": case "PIGLIN": + case "PIGLIN_BRUTE": case "ZOMBIE": case "WITHER": case "WITCH": @@ -711,6 +712,7 @@ public final class ReplicatingEntityWrapper extends EntityWrapper { case "HOGLIN": case "PIGLIN": case "ZOMBIFIED_PIGLIN": + case "PIGLIN_BRUTE": case "ZOMBIE": case "WITHER": case "WITCH": diff --git a/build.gradle b/build.gradle index 40639372c..6ed92cdac 100644 --- a/build.gradle +++ b/build.gradle @@ -127,7 +127,6 @@ subprojects { relocate("org.json", "com.plotsquared.json") { exclude "org/json/simple/**" } - // relocate('org.mcstats', 'com.plotsquared.stats') archiveFileName = "${project.name}-${parent.version}.jar" destinationDirectory = file "../target" } From 6315b9ea52c5176354fd2c344d020c9e9ca34318 Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Tue, 11 Aug 2020 17:43:24 +0200 Subject: [PATCH 05/12] gradle 6.6 --- gradle/wrapper/gradle-wrapper.jar | Bin 58694 -> 58910 bytes gradle/wrapper/gradle-wrapper.properties | 2 +- gradlew | 2 ++ gradlew.bat | 1 + 4 files changed, 4 insertions(+), 1 deletion(-) diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 490fda8577df6c95960ba7077c43220e5bb2c0d9..62d4c053550b91381bbd28b1afc82d634bf73a8a 100644 GIT binary patch delta 6447 zcmY*dbyQSczlH%shY+L(kQ}C6ise@?c@F%#`dE9xT=qM=Dm?$VxD1hrECD1a#01Q8o zMyT3}z+1K>hPE%4doH=x5X;^NP(OFD5GByp;5FQ^bpzkBa(;eudMu7Iyv$DE+N=>p z{3Y5_BP>F3)tXW*Styc(Ji3jnK-giGA_&42fsbZ@#+e+ly3w0VmLC;LA)h1UY(ChA zfwqQ?-@}@S93F|exOv;Se;P|SrYvEG(8q&|ltqvQHO9KgCSwM!Y+#d5eIRq$Mi`pU__N$FTxW@KAWIw= zayY6@9EyxG<_tr&{Wi87m5*mf=u&=;eL1gf{Mt)q8Drick8CcxzLW>cG~TbW)|$*D zYMc|5eZNNzt7O_C1LqgaI`Z0B+2#;3yO;E7N4oMY@~7$4;MRonU+Ca z#*cD!7$u9pZ|3f!-_6rpN}XhAWd`1qiR{e*1CJK1dvBsjUyY@BuT|;EAz}*0uSwT_ zq(g0jXTAK4wsQ>kIKEfRQZw^GIKNRZmV)b;c*Kpc?IvNu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Og;z= z3z>Lgn+88SWz5<$r*2$j5F6$glpX51lvo`8iT|m8vPVVVa|jx z&hfX2>kf%tAM?<=>xP+`#7lZs61$5|7J_%%!KyPj!t#T}j$H#+@?leTQwL&WsN$BN zuXS}6RGLD|V8HiN%M-zT^@+Hmns8IP+?%IVh@_upzIr!I+-a7r=-%NBXw*Op0`LK3 zG5fdG`C@Axy?d+8VQLq(qkUTD+FNVrN5Q|J6R&jh2Lv)Ole+5pGloEZZQ79>m7YGM zSPJ1GRDQtW?r9jb{g**e3Mr>PHrRWagZ|ku4kjL;JOdL~Id05kc*CA+ui@= zieS-e>hskR-1I9Sx7b4i6p>2LP#vgtG6;8vGL>E3$NPQ$J2r~XGQDNg;Sw=& zC}lz+3@Sq%I2q-97R&9|8Ij2^?^DGQK_oiqZS2$!-rzVqn=~d~TS{n&I+svxt4dWO zT?K0)JEx>9E7saW8h!5+MmAkC`g~v*@ z6VKn0>eZdon>BH(O$mACnxk3D?vSlCFFnvZ#+&hUs)Wr!aP{<@|oc^G>bJk59^xhmz!RA%|K_$o)V`D@gVs>@bSmXVID_PQXp znfja8U01+t3V!o{8ZKi~G@#q$KrAH-Ks3$G{Qo}H|N1ijJMsgZDgOmM1O$Fi0>0CX zpbAzXhYbP@PV;~=*nn7eQGjoT2b9nGFNg-PpHT$a@?7JL7I&pmkmclS7#Y#zRYg_`D0h47O z&|%88tXNh8{Yk$@@*HA-B9r#tDkY$>!U#Ie`j1TupjRn@;(ykyyld-zJ{@qm!UG~I zxR#ZxV8CEi5JXV?ANc~bS9*;MYtkTvifc5iynmg!XpIr%SN*R#E?|3&2QVs~N02d=N!1;GdfNGr)gc$|K#-y*M=Ra9B4#cmk-naoQuS*cWnE3C4 F{|nTN-B$nr diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index bb8b2fc26..6c9a22477 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-6.5.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-6.6-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew index 2fe81a7d9..fbd7c5158 100755 --- a/gradlew +++ b/gradlew @@ -82,6 +82,7 @@ esac CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar + # Determine the Java command to use to start the JVM. if [ -n "$JAVA_HOME" ] ; then if [ -x "$JAVA_HOME/jre/sh/java" ] ; then @@ -129,6 +130,7 @@ fi if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then APP_HOME=`cygpath --path --mixed "$APP_HOME"` CLASSPATH=`cygpath --path --mixed "$CLASSPATH"` + JAVACMD=`cygpath --unix "$JAVACMD"` # We build the pattern for arguments to be converted via cygpath diff --git a/gradlew.bat b/gradlew.bat index 62bd9b9cc..5093609d5 100644 --- a/gradlew.bat +++ b/gradlew.bat @@ -84,6 +84,7 @@ set CMD_LINE_ARGS=%* set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + @rem Execute Gradle "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS% From a1b10a2900ec15adead0146f7c98348b73c99aec Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Tue, 11 Aug 2020 17:49:04 +0200 Subject: [PATCH 06/12] Remove dead files --- .github/ISSUE_TEMPLATE.md | 101 ------------------------------ .github/ISSUE_TEMPLATE/config.yml | 8 --- README.md | 2 +- 3 files changed, 1 insertion(+), 110 deletions(-) delete mode 100644 .github/ISSUE_TEMPLATE.md delete mode 100644 .github/ISSUE_TEMPLATE/config.yml diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md deleted file mode 100644 index f1ee68845..000000000 --- a/.github/ISSUE_TEMPLATE.md +++ /dev/null @@ -1,101 +0,0 @@ ---- -name: Bug/Issue report for PlotSquared -about: Bug / Issue report about this plugin -title: '' -labels: "[?] Testing Required" -assignees: '' - ---- - - - - - - - -# Bug Report Template: - -## Required Information section: -> ALL FIELDS IN THIS SECTION ARE REQUIRED, and must contain appropriate information -### Server config info (/plot debugpaste / file paste links): - - - -**/plot debugpaste:** - -### Server type: -**Select one** - -- [] Spigot / Paper *(CraftBukkit should not be used, re-test with Spigot first!)* -- [] Sponge -- [] NukkitX - -### PlotSquared version: - -``` -Paste the output here, between the tick marks, replacing this text -``` - -### Minecraft Version: -**Select one** - -- [] Minecraft 1.15.2 -- [] Minecraft 1.14.4 -- [] Minecraft 1.13.2 -- [] Minecraft 1.12.2 -- [] Minecraft 1.11.2 -- [] Minecraft 1.10.2 -- [] Minecraft 1.9.4 -- [] Minecraft 1.8.8 -- [] Minecraft Java Edition *other versions, please specify*: -- [] Minecraft Bedrock Edition *specify version*: -- [] Minecraft Sponge *specify version*: - -### Server build info: - -``` -Paste the output here, between the tick marks, replacing this text -``` - -### WorldEdit/FAWE versions: - -- [] FAWE version: -- [] WorldEdit version: - -### Description of the problem: - - - -### How to replicate: - - -## Additional Information: -> The information here is optional for you to provide, however it may help us to more readily diagnose any compatibility and bug issues. - -### Other plugins being used on the server: - - -### Relevant console output, log lines, and/or screenshots: - - -### Additional relevant comments/remarks: - - -# AFFIRMATION OF COMPLETION: - -- [] I included all information required in the sections above -- [] I made sure there are no duplicates of this report [(Use Search)](https://github.com/IntellectualSites/PlotSquared/issues?utf8=%E2%9C%93&q=is%3Aissue) -- [] I made sure I am using an up-to-date version of PlotSquared -- [] I made sure the bug/error is not caused by any other plugin -- [x] I didn't read but checked everything above. \ No newline at end of file diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml deleted file mode 100644 index fd39e3738..000000000 --- a/.github/ISSUE_TEMPLATE/config.yml +++ /dev/null @@ -1,8 +0,0 @@ -blank_issues_enabled: false -contact_links: - - name: PlotSquared Issue Tracker - url: https://issues.intellectualsites.com/projects/ps - about: Click here to move to our new issue tracker - - name: PlotSquared Suggestions - url: https://github.com/IntellectualSites/PlotSquaredSuggestions - about: If you want to submit feature or suggestion ideas, do that here \ No newline at end of file diff --git a/README.md b/README.md index 4d5de20ef..7380ac78f 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@

- +

--- From d6dfa9a0b9b5a06e233ca9cb0b762ac7caed0fb4 Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Tue, 11 Aug 2020 20:12:31 +0200 Subject: [PATCH 07/12] https --- Bukkit/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Bukkit/build.gradle b/Bukkit/build.gradle index 2a8fd96f2..81ae0c3c0 100644 --- a/Bukkit/build.gradle +++ b/Bukkit/build.gradle @@ -6,7 +6,7 @@ repositories { maven { url = "https://oss.sonatype.org/content/repositories/snapshots/" } maven { url = "https://jitpack.io" } maven { url = "https://repo.codemc.org/repository/maven-public" } - maven { url = "http://repo.extendedclip.com/content/repositories/placeholderapi/" } + maven { url = "https://repo.extendedclip.com/content/repositories/placeholderapi/" } maven { name = "papermc" url = "https://papermc.io/repo/repository/maven-public/" From 808bddbfbb1d85473104b4040786dac53e3e8f6b Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Wed, 12 Aug 2020 10:30:05 +0200 Subject: [PATCH 08/12] Apply scaling to image --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 7380ac78f..a05b3ea21 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@

- +

--- From 6c9b73b100a5ae2cf175b19d6424e0cedbba8604 Mon Sep 17 00:00:00 2001 From: MeFisto94 Date: Sun, 16 Aug 2020 14:02:03 +0200 Subject: [PATCH 09/12] Apply patch by @SirYwell to construct the ResourceKey without consulting the DimensionManager --- .../bukkit/util/OfflinePlayerUtil.java | 23 +++++++++++++------ 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java b/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java index 197b05cd6..94a6acedf 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/util/OfflinePlayerUtil.java @@ -63,11 +63,11 @@ public class OfflinePlayerUtil { Object profile = newGameProfile(id, name); Class entityPlayerClass = getNmsClass("EntityPlayer"); Constructor entityPlayerConstructor = - makeConstructor(entityPlayerClass, getNmsClass("MinecraftServer"), - getNmsClass("WorldServer"), getUtilClass("com.mojang.authlib.GameProfile"), - getNmsClass("PlayerInteractManager")); + makeConstructor(entityPlayerClass, getNmsClass("MinecraftServer"), + getNmsClass("WorldServer"), getUtilClass("com.mojang.authlib.GameProfile"), + getNmsClass("PlayerInteractManager")); Object entityPlayer = - callConstructor(entityPlayerConstructor, server, worldServer, profile, interactManager); + callConstructor(entityPlayerConstructor, server, worldServer, profile, interactManager); return (Player) getBukkitEntity(entityPlayer); } @@ -100,12 +100,21 @@ public class OfflinePlayerUtil { public static Object getWorldServer116() { Object server = getMinecraftServer(); Class minecraftServerClass = getNmsClass("MinecraftServer"); - Class dimensionManager = getNmsClass("DimensionManager"); Class genericResourceKey = getNmsClass("ResourceKey"); - Object overworld = getField(makeField(dimensionManager, "OVERWORLD"), null); + Class minecraftKey = getNmsClass("MinecraftKey"); + // MinecraftKey + MinecraftKey -> ResourceKey + Method constructResourceKey = makeMethod(genericResourceKey, "a", minecraftKey, minecraftKey); + // MinecraftKey(String) + Constructor minecraftKeyConstructor = makeConstructor(minecraftKey, String.class); + // minecraft:overworld + Object overworldKey = callConstructor(minecraftKeyConstructor, "overworld"); + // minecraft:dimension + Object dimensionKey = callConstructor(minecraftKeyConstructor, "dimension"); + // ResourceKey[minecraft:dimension / minecraft:overworld] + Object resourceKey = callMethod(constructResourceKey, null, dimensionKey, overworldKey); Method getWorldServer = makeMethod(minecraftServerClass, "getWorldServer", genericResourceKey); - return callMethod(getWorldServer, server, overworld); + return callMethod(getWorldServer, server, resourceKey); } public static Object getWorldServerNew() { From 61d1dcc231b5e1657a7b0fdae5089e21bcaa317c Mon Sep 17 00:00:00 2001 From: MeFisto94 Date: Sun, 16 Aug 2020 14:09:32 +0200 Subject: [PATCH 10/12] Ignore Events if they are not caused by real players (i.e. citizens) --- .../bukkit/listener/PlayerEventListener.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java index c4d7c6d90..8392591b5 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java @@ -69,6 +69,7 @@ import com.plotsquared.core.util.MainUtil; import com.plotsquared.core.util.MathMan; import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.PremiumVerification; +import com.plotsquared.core.util.ReflectionUtils; import com.plotsquared.core.util.RegExUtil; import com.plotsquared.core.util.entity.EntityCategories; import com.plotsquared.core.util.task.TaskManager; @@ -139,6 +140,7 @@ import java.util.HashSet; import java.util.List; import java.util.Set; import java.util.UUID; +import java.util.function.Predicate; import java.util.regex.Pattern; /** @@ -153,7 +155,15 @@ public class PlayerEventListener extends PlotListener implements Listener { private PlayerMoveEvent moveTmp; private String internalVersion; + private final Predicate isRealPlayerCheck; + { + Class playerImplementation = ReflectionUtils.getCbClass("entity.CraftPlayer"); + if (playerImplementation == null) { + isRealPlayerCheck = p -> true; + } else { + isRealPlayerCheck = p -> p.getClass() == playerImplementation; + } try { fieldPlayer = PlayerEvent.class.getDeclaredField("player"); fieldPlayer.setAccessible(true); @@ -346,6 +356,9 @@ public class PlayerEventListener extends PlotListener implements Listener { @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void onTeleport(PlayerTeleportEvent event) { + if (!isRealPlayerCheck.test(event.getPlayer())) { + return; + } Player player = event.getPlayer(); BukkitPlayer pp = BukkitUtil.getPlayer(player); Plot lastPlot = pp.getMeta(PlotPlayer.META_LAST_PLOT); @@ -452,6 +465,9 @@ public class PlayerEventListener extends PlotListener implements Listener { @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void playerMove(PlayerMoveEvent event) { + if (!isRealPlayerCheck.test(event.getPlayer())) { + return; + } org.bukkit.Location from = event.getFrom(); org.bukkit.Location to = event.getTo(); int x2; @@ -643,6 +659,9 @@ public class PlayerEventListener extends PlotListener implements Listener { @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void onWorldChanged(PlayerChangedWorldEvent event) { + if (!isRealPlayerCheck.test(event.getPlayer())) { + return; + } Player player = event.getPlayer(); BukkitPlayer pp = BukkitUtil.getPlayer(player); // Delete last location From 62f675adbe1ed70d92efc7ef4532237290f0ee45 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Fri, 21 Aug 2020 00:01:53 +0200 Subject: [PATCH 11/12] Allow visiting all owners of merged plots --- Core/src/main/java/com/plotsquared/core/command/Visit.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Visit.java b/Core/src/main/java/com/plotsquared/core/command/Visit.java index 9d803f6e3..ae6b3947e 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Visit.java +++ b/Core/src/main/java/com/plotsquared/core/command/Visit.java @@ -180,7 +180,9 @@ public class Visit extends Command { Captions.COMMAND_SYNTAX.send(player, getUsage()); } else { final UUID uuid = uuids.toArray(new UUID[0])[0]; - this.visit(player, PlotQuery.newQuery().ownedBy(uuid).whereBasePlot(), finalSortByArea, confirm, whenDone, finalPage1); + this.visit(player, PlotQuery.newQuery() + .thatPasses(plot -> plot.isOwner(uuid)), + finalSortByArea, confirm, whenDone, finalPage1); } }); break; @@ -209,7 +211,7 @@ public class Visit extends Command { MainUtil.sendMessage(player, Captions.INVALID_PLAYER, finalArgs[0]); } } else { - this.visit(player, PlotQuery.newQuery().ownedBy(uuid).whereBasePlot(), null, confirm, whenDone, finalPage); + this.visit(player, PlotQuery.newQuery().thatPasses(plot -> plot.isOwner(uuid)).whereBasePlot(), null, confirm, whenDone, finalPage); } }); } else { From 1064d777c26ef39089e5ab1745a2c0b3f3e3bfcc Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Fri, 21 Aug 2020 00:02:07 +0200 Subject: [PATCH 12/12] Clean up unused code --- .../com/plotsquared/core/command/Visit.java | 23 ------------------- 1 file changed, 23 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Visit.java b/Core/src/main/java/com/plotsquared/core/command/Visit.java index ae6b3947e..c5f8b4b6d 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Visit.java +++ b/Core/src/main/java/com/plotsquared/core/command/Visit.java @@ -264,27 +264,4 @@ public class Visit extends Command { return completions; } - - private void completeNumbers(final List commands, final String arg, final int start) { - for (int i = 0; i < 100; i++) { - final String command = Integer.toString(start + 1); - if (!command.toLowerCase().startsWith(arg.toLowerCase())) { - continue; - } - commands.add(new Command(this, false, command, "", - RequiredType.NONE, CommandCategory.TELEPORT) {}); - } - } - - private void completeAreas(final List commands, final String arg) { - for (final PlotArea area : PlotSquared.get().getPlotAreas()) { - final String areaName = area.getWorldName() + ";" + area.getId(); - if (!areaName.toLowerCase().startsWith(arg.toLowerCase())) { - continue; - } - commands.add(new Command(this, false, area.getWorldName() + ";" + area.getId(), "", - RequiredType.NONE, CommandCategory.TELEPORT) {}); - } - } - }