From f27009216c21a3bbe009f0c80c6b20c3e372277e Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 21 Jun 2022 19:09:17 +0200 Subject: [PATCH 001/111] chore: Replace AnnotationHelper class (#3706) --- Bukkit/build.gradle.kts | 2 + .../plotsquared/bukkit/queue/GenChunk.java | 4 +- Core/build.gradle.kts | 2 + .../com/plotsquared/core/PlotPlatform.java | 4 +- .../core/generator/HybridPlotWorld.java | 8 +-- .../core/location/UncheckedWorldLocation.java | 8 +-- .../core/plot/flag/FlagContainer.java | 5 +- ...BlockArrayCacheScopedQueueCoordinator.java | 4 +- .../core/util/AnnotationHelper.java | 55 ------------------- .../core/util/EventDispatcher.java | 4 +- build.gradle.kts | 2 +- 11 files changed, 23 insertions(+), 75 deletions(-) delete mode 100644 Core/src/main/java/com/plotsquared/core/util/AnnotationHelper.java diff --git a/Bukkit/build.gradle.kts b/Bukkit/build.gradle.kts index f29140b42..958f4627a 100644 --- a/Bukkit/build.gradle.kts +++ b/Bukkit/build.gradle.kts @@ -50,6 +50,7 @@ dependencies { implementation(libs.arkitektonika) implementation(libs.http4j) implementation("com.intellectualsites.paster:Paster") + implementation("com.intellectualsites.informative-annotations:informative-annotations") // Adventure implementation("net.kyori:adventure-platform-bukkit") @@ -87,6 +88,7 @@ tasks.named("shadowJar") { relocate("javax.inject", "com.plotsquared.core.annotation.inject") relocate("net.jcip", "com.plotsquared.core.annotations.jcip") relocate("edu.umd.cs.findbugs", "com.plotsquared.core.annotations.findbugs") + relocate("com.intellectualsites.informative-annotations", "com.plotsquared.core.annotation.informative") // Get rid of all the libs which are 100% unused. minimize() diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java index 0b580cf48..44ec39545 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java @@ -19,12 +19,12 @@ package com.plotsquared.bukkit.queue; import com.google.common.base.Preconditions; +import com.intellectualsites.annotations.DoNotUse; import com.plotsquared.bukkit.util.BukkitBlockUtil; import com.plotsquared.bukkit.util.BukkitUtil; import com.plotsquared.core.location.ChunkWrapper; import com.plotsquared.core.location.Location; import com.plotsquared.core.queue.ScopedQueueCoordinator; -import com.plotsquared.core.util.AnnotationHelper; import com.plotsquared.core.util.ChunkUtil; import com.plotsquared.core.util.PatternUtil; import com.sk89q.worldedit.bukkit.BukkitAdapter; @@ -44,7 +44,7 @@ import org.checkerframework.checker.nullness.qual.Nullable; import java.util.Arrays; -@AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") +@DoNotUse public class GenChunk extends ScopedQueueCoordinator { public final Biome[] biomes; diff --git a/Core/build.gradle.kts b/Core/build.gradle.kts index a9a7f02b1..284b5399b 100644 --- a/Core/build.gradle.kts +++ b/Core/build.gradle.kts @@ -43,6 +43,7 @@ dependencies { api(libs.cloudServices) api(libs.arkitektonika) api("com.intellectualsites.paster:Paster") + api("com.intellectualsites.informative-annotations:informative-annotations") } tasks.processResources { @@ -62,5 +63,6 @@ tasks { opt.links("https://jd.adventure.kyori.net/api/4.9.3/") opt.links("https://google.github.io/guice/api-docs/" + libs.guice.get().versionConstraint.toString() + "/javadoc/") opt.links("https://checkerframework.org/api/") + opt.links("https://javadoc.io/doc/com.intellectualsites.informative-annotations/informative-annotations/latest/") } } diff --git a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java index b107724a5..75ceef94d 100644 --- a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java +++ b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java @@ -22,6 +22,7 @@ import cloud.commandframework.services.ServicePipeline; import com.google.inject.Injector; import com.google.inject.Key; import com.google.inject.TypeLiteral; +import com.intellectualsites.annotations.DoNotUse; import com.plotsquared.core.backup.BackupManager; import com.plotsquared.core.configuration.caption.LocaleHolder; import com.plotsquared.core.generator.GeneratorWrapper; @@ -33,7 +34,6 @@ import com.plotsquared.core.permissions.PermissionHandler; import com.plotsquared.core.player.PlotPlayer; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.queue.GlobalBlockQueue; -import com.plotsquared.core.util.AnnotationHelper; import com.plotsquared.core.util.ChunkManager; import com.plotsquared.core.util.EconHandler; import com.plotsquared.core.util.PlatformWorldManager; @@ -308,7 +308,7 @@ public interface PlotPlatform

extends LocaleHolder { * @return worldedit implementations * @since 6.3.0 */ - @AnnotationHelper.ApiDescription(info = "Internal use only") + @DoNotUse @NonNull String worldEditImplementations(); /** diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index 3c5b8686c..054410817 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -20,6 +20,7 @@ package com.plotsquared.core.generator; import com.google.inject.Inject; import com.google.inject.assistedinject.Assisted; +import com.intellectualsites.annotations.DoNotUse; import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.ConfigurationSection; import com.plotsquared.core.configuration.Settings; @@ -33,7 +34,6 @@ import com.plotsquared.core.plot.PlotId; import com.plotsquared.core.plot.PlotManager; import com.plotsquared.core.plot.schematic.Schematic; import com.plotsquared.core.queue.GlobalBlockQueue; -import com.plotsquared.core.util.AnnotationHelper; import com.plotsquared.core.util.FileUtils; import com.plotsquared.core.util.MathMan; import com.plotsquared.core.util.SchematicHandler; @@ -531,7 +531,7 @@ public class HybridPlotWorld extends ClassicPlotWorld { * * @since 6.9.0 */ - @AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") + @DoNotUse public @Nullable List getPlotSchematicEntities() { return schem3Entities; } @@ -541,7 +541,7 @@ public class HybridPlotWorld extends ClassicPlotWorld { * * @since 6.9.0 */ - @AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") + @DoNotUse public @Nullable BlockVector3 getPlotSchematicMinPoint() { return schem3MinPoint; } @@ -551,7 +551,7 @@ public class HybridPlotWorld extends ClassicPlotWorld { * * @since 6.9.0 */ - @AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") + @DoNotUse public boolean populationNeeded() { return schem1PopulationNeeded || schem2PopulationNeeded || schem3PopulationNeeded; } diff --git a/Core/src/main/java/com/plotsquared/core/location/UncheckedWorldLocation.java b/Core/src/main/java/com/plotsquared/core/location/UncheckedWorldLocation.java index baa0c5086..bdf58ef5d 100644 --- a/Core/src/main/java/com/plotsquared/core/location/UncheckedWorldLocation.java +++ b/Core/src/main/java/com/plotsquared/core/location/UncheckedWorldLocation.java @@ -18,7 +18,7 @@ */ package com.plotsquared.core.location; -import com.plotsquared.core.util.AnnotationHelper; +import com.intellectualsites.annotations.DoNotUse; import com.sk89q.worldedit.math.BlockVector3; import org.checkerframework.checker.nullness.qual.NonNull; @@ -28,7 +28,7 @@ import org.checkerframework.checker.nullness.qual.NonNull; * * @since 6.9.0 */ -@AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") +@DoNotUse public final class UncheckedWorldLocation extends Location { private final String worldName; @@ -54,7 +54,7 @@ public final class UncheckedWorldLocation extends Location { * * @since 6.9.0 */ - @AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") + @DoNotUse public static @NonNull UncheckedWorldLocation at( final @NonNull String world, final int x, final int y, final int z ) { @@ -62,7 +62,7 @@ public final class UncheckedWorldLocation extends Location { } @Override - @AnnotationHelper.ApiDescription(info = "Internal use only. Subject to changes at any time.") + @DoNotUse public @NonNull String getWorldName() { return this.worldName; } diff --git a/Core/src/main/java/com/plotsquared/core/plot/flag/FlagContainer.java b/Core/src/main/java/com/plotsquared/core/plot/flag/FlagContainer.java index 265f5f2c8..37fda5dd2 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/flag/FlagContainer.java +++ b/Core/src/main/java/com/plotsquared/core/plot/flag/FlagContainer.java @@ -20,8 +20,8 @@ package com.plotsquared.core.plot.flag; import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableMap; +import com.intellectualsites.annotations.NotPublic; import com.plotsquared.core.configuration.caption.CaptionUtility; -import com.plotsquared.core.util.AnnotationHelper; import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; import org.checkerframework.checker.nullness.qual.NonNull; @@ -32,7 +32,6 @@ import java.util.HashMap; import java.util.HashSet; import java.util.Locale; import java.util.Map; -import java.util.Objects; /** * Container type for {@link PlotFlag plot flags}. @@ -353,7 +352,7 @@ public class FlagContainer { * @return a new Runnable that cleans up once the FlagContainer isn't needed anymore. * @since 6.0.10 */ - @AnnotationHelper.ApiDescription(info = "This method should not be considered as public or API.") + @NotPublic public Runnable createCleanupHook() { return () -> GlobalFlagContainer.getInstance().unsubscribe(unknownsRef); } diff --git a/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java b/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java index a57f2c389..243f5637f 100644 --- a/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java +++ b/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java @@ -18,8 +18,8 @@ */ package com.plotsquared.core.queue; +import com.intellectualsites.annotations.DoNotUse; import com.plotsquared.core.location.Location; -import com.plotsquared.core.util.AnnotationHelper; import com.sk89q.jnbt.CompoundTag; import com.sk89q.worldedit.function.pattern.Pattern; import com.sk89q.worldedit.math.BlockVector3; @@ -37,7 +37,7 @@ import org.checkerframework.checker.nullness.qual.Nullable; * in {@link BlockArrayCacheScopedQueueCoordinator#setOffsetX(int)} and * {@link BlockArrayCacheScopedQueueCoordinator#setOffsetZ(int)} */ -@AnnotationHelper.ApiDescription(info = "Internal use only. Subject to change at any time and created for specific use cases.") +@DoNotUse public class BlockArrayCacheScopedQueueCoordinator extends ScopedQueueCoordinator { private final BlockState[][][] blockStates; diff --git a/Core/src/main/java/com/plotsquared/core/util/AnnotationHelper.java b/Core/src/main/java/com/plotsquared/core/util/AnnotationHelper.java deleted file mode 100644 index bb8d69664..000000000 --- a/Core/src/main/java/com/plotsquared/core/util/AnnotationHelper.java +++ /dev/null @@ -1,55 +0,0 @@ -/* - * PlotSquared, a land and world management plugin for Minecraft. - * Copyright (C) IntellectualSites - * Copyright (C) IntellectualSites team and contributors - * - * This program is free software: you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ -package com.plotsquared.core.util; - -import java.lang.annotation.Documented; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -import static java.lang.annotation.ElementType.METHOD; -import static java.lang.annotation.ElementType.MODULE; -import static java.lang.annotation.ElementType.PACKAGE; -import static java.lang.annotation.ElementType.RECORD_COMPONENT; -import static java.lang.annotation.ElementType.TYPE; - -/** - * @since 6.2.2 - */ -@AnnotationHelper.ApiDescription(info = "An internal class for custom annotations." + - "This is in no form part of the API and is subject to change at any time.") -public final class AnnotationHelper { - - private AnnotationHelper() { - } - - @Documented - @Retention(RetentionPolicy.CLASS) - @Target(value = {METHOD, PACKAGE, MODULE, RECORD_COMPONENT, TYPE}) - public @interface ApiDescription { - /** - * Returns additional information how to use a class for the API - * - * @return the version string - * @since 6.2.2 - */ - String info() default ""; - } - -} 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 7285e1981..d1ad9386c 100644 --- a/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java +++ b/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java @@ -19,6 +19,7 @@ package com.plotsquared.core.util; import com.google.common.eventbus.EventBus; +import com.intellectualsites.annotations.DoNotUse; import com.plotsquared.core.configuration.Settings; import com.plotsquared.core.configuration.caption.TranslatableCaption; import com.plotsquared.core.events.PlayerAutoPlotEvent; @@ -81,8 +82,7 @@ import java.util.ArrayList; import java.util.List; import java.util.UUID; -@AnnotationHelper.ApiDescription(info = "This is an internal class used by PlotSquared to dispatch events." + - "This is in no form part of the API and is subject to change at any time.") +@DoNotUse public class EventDispatcher { private final EventBus eventBus = new EventBus("PlotSquaredEvents"); diff --git a/build.gradle.kts b/build.gradle.kts index 9aa40c8bc..7f9d801ae 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.5")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.7")) } dependencies { From f218902581d049a7693f9cfc17d5364e0817234d Mon Sep 17 00:00:00 2001 From: Jordan Date: Tue, 21 Jun 2022 18:09:29 +0100 Subject: [PATCH 002/111] Implement build height limits into more events (#3691) * Implement build height limits into more events * Implement util method to check if y is within world build limits * Extract duplicate player-build-height-checking to plot area - Extract to core module to allow any possible future platforms to access the method, as they will always duplicate * Add code tag to javadoc Co-authored-by: Alexander Brandes Co-authored-by: Alexander Brandes --- .../bukkit/listener/BlockEventListener.java | 88 ++++++++++--------- .../listener/BlockEventListener117.java | 41 ++++----- .../bukkit/listener/PlayerEventListener.java | 7 +- .../com/plotsquared/core/plot/PlotArea.java | 34 +++++++ .../core/util/EventDispatcher.java | 9 ++ 5 files changed, 114 insertions(+), 65 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index 06c1f3e66..198710578 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -265,15 +265,9 @@ public class BlockEventListener implements Listener { BukkitPlayer pp = BukkitUtil.adapt(player); Plot plot = area.getPlot(location); if (plot != null) { - if ((location.getY() >= area.getMaxBuildHeight() || location.getY() < area - .getMinBuildHeight()) && !Permissions - .hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) { + if (area.notifyIfOutsideBuildArea(pp, location.getY())) { event.setCancelled(true); - pp.sendMessage( - TranslatableCaption.of("height.height_limit"), - Template.of("minHeight", String.valueOf(area.getMinBuildHeight())), - Template.of("maxHeight", String.valueOf(area.getMaxBuildHeight())) - ); + return; } if (!plot.hasOwner()) { if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_UNOWNED)) { @@ -351,15 +345,9 @@ public class BlockEventListener implements Listener { event.setCancelled(true); return; } - } else if ((location.getY() >= area.getMaxBuildHeight() || location.getY() < area - .getMinBuildHeight()) && !Permissions - .hasPermission(plotPlayer, Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) { + } else if (area.notifyIfOutsideBuildArea(plotPlayer, location.getY())) { event.setCancelled(true); - plotPlayer.sendMessage( - TranslatableCaption.of("height.height_limit"), - Template.of("minHeight", String.valueOf(area.getMinBuildHeight())), - Template.of("maxHeight", String.valueOf(area.getMaxBuildHeight())) - ); + return; } if (!plot.hasOwner()) { if (!Permissions @@ -537,7 +525,7 @@ public class BlockEventListener implements Listener { if (plot == null) { return; } - if (location.getY() >= area.getMaxBuildHeight() || location.getY() < area.getMinBuildHeight()) { + if (!area.buildRangeContainsY(location.getY())) { event.setCancelled(true); return; } @@ -739,7 +727,7 @@ public class BlockEventListener implements Listener { } return; } - if (toLocation.getY() >= toArea.getMaxBuildHeight() || toLocation.getY() < toArea.getMinBuildHeight()) { + if (!toArea.buildRangeContainsY(toLocation.getY())) { event.setCancelled(true); return; } @@ -813,6 +801,11 @@ public class BlockEventListener implements Listener { return; } + if (!area.buildRangeContainsY(location.getY())) { + event.setCancelled(true); + return; + } + Plot plot = location.getOwnedPlot(); if (plot == null || !plot.getFlag(CropGrowFlag.class)) { if (plot != null) { @@ -856,15 +849,16 @@ public class BlockEventListener implements Listener { } for (Block block1 : event.getBlocks()) { Location bloc = BukkitUtil.adapt(block1.getLocation()); - if (!area.contains(bloc.getX(), bloc.getZ()) || !area.contains( - bloc.getX() + relative.getBlockX(), - bloc.getZ() + relative.getBlockZ() - )) { + Location newLoc = bloc.add(relative.getBlockX(), relative.getBlockY(), relative.getBlockZ()); + if (!area.contains(bloc.getX(), bloc.getZ()) || !area.contains(newLoc)) { event.setCancelled(true); return; } - if (!plot.equals(area.getOwnedPlot(bloc)) || !plot - .equals(area.getOwnedPlot(bloc.add(relative.getBlockX(), relative.getBlockY(), relative.getBlockZ())))) { + if (!plot.equals(area.getOwnedPlot(bloc)) || !plot.equals(area.getOwnedPlot(newLoc))) { + event.setCancelled(true); + return; + } + if (!area.buildRangeContainsY(bloc.getY()) || !area.buildRangeContainsY(newLoc.getY())) { event.setCancelled(true); return; } @@ -890,9 +884,8 @@ public class BlockEventListener implements Listener { } for (Block block1 : event.getBlocks()) { Location bloc = BukkitUtil.adapt(block1.getLocation()); - if (bloc.isPlotArea() || bloc - .add(relative.getBlockX(), relative.getBlockY(), relative.getBlockZ()) - .isPlotArea()) { + Location newLoc = bloc.add(relative.getBlockX(), relative.getBlockY(), relative.getBlockZ()); + if (bloc.isPlotArea() || newLoc.isPlotArea()) { event.setCancelled(true); return; } @@ -906,15 +899,16 @@ public class BlockEventListener implements Listener { } for (Block block1 : event.getBlocks()) { Location bloc = BukkitUtil.adapt(block1.getLocation()); - if (!area.contains(bloc.getX(), bloc.getZ()) || !area.contains( - bloc.getX() + relative.getBlockX(), - bloc.getZ() + relative.getBlockZ() - )) { + Location newLoc = bloc.add(relative.getBlockX(), relative.getBlockY(), relative.getBlockZ()); + if (!area.contains(bloc.getX(), bloc.getZ()) || !area.contains(newLoc)) { event.setCancelled(true); return; } - if (!plot.equals(area.getOwnedPlot(bloc)) || !plot - .equals(area.getOwnedPlot(bloc.add(relative.getBlockX(), relative.getBlockY(), relative.getBlockZ())))) { + if (!plot.equals(area.getOwnedPlot(bloc)) || !plot.equals(area.getOwnedPlot(newLoc))) { + event.setCancelled(true); + return; + } + if (!area.buildRangeContainsY(bloc.getY()) || !area.buildRangeContainsY(newLoc.getY())) { event.setCancelled(true); return; } @@ -938,6 +932,11 @@ public class BlockEventListener implements Listener { Location location = BukkitUtil.adapt(event.getBlock().getRelative(targetFace).getLocation()); if (location.isPlotRoad()) { event.setCancelled(true); + return; + } + PlotArea area = location.getPlotArea(); + if (area != null && !area.buildRangeContainsY(location.getY())) { + event.setCancelled(true); } } } @@ -977,6 +976,10 @@ public class BlockEventListener implements Listener { Plot plot = area.getOwnedPlot(location); if (!Objects.equals(plot, origin)) { event.getBlocks().remove(i); + continue; + } + if (!area.buildRangeContainsY(location.getY())) { + event.getBlocks().remove(i); } } } @@ -1068,6 +1071,10 @@ public class BlockEventListener implements Listener { Plot plot = area.getOwnedPlot(location1); if (player != null) { BukkitPlayer pp = BukkitUtil.adapt(player); + if (area.notifyIfOutsideBuildArea(pp, location1.getY())) { + event.setCancelled(true); + return; + } if (plot == null) { if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_ROAD)) { pp.sendMessage( @@ -1175,7 +1182,10 @@ public class BlockEventListener implements Listener { return true; } Plot plot = area.getOwnedPlot(blockLocation); - return !Objects.equals(plot, origin); + if (!Objects.equals(plot, origin)) { + return true; + } + return !area.buildRangeContainsY(location.getY()); }); } if (blocks.isEmpty()) { @@ -1217,15 +1227,7 @@ public class BlockEventListener implements Listener { event.setCancelled(true); break; } - if (Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) { - continue; - } - if (currentLocation.getY() >= area.getMaxBuildHeight() || currentLocation.getY() < area.getMinBuildHeight()) { - pp.sendMessage( - TranslatableCaption.of("height.height_limit"), - Template.of("minHeight", String.valueOf(area.getMinBuildHeight())), - Template.of("maxHeight", String.valueOf(area.getMaxBuildHeight())) - ); + if (area.notifyIfOutsideBuildArea(pp, currentLocation.getY())) { event.setCancelled(true); break; } diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java index ccefb86fa..2d23515ad 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java @@ -80,10 +80,19 @@ public class BlockEventListener117 implements Listener { return; } + BukkitPlayer plotPlayer = null; + + if (entity instanceof Player player) { + plotPlayer = BukkitUtil.adapt(player); + if (area.notifyIfOutsideBuildArea(plotPlayer, location.getY())) { + event.setCancelled(true); + return; + } + } + Plot plot = location.getOwnedPlot(); if (plot == null || !plot.getFlag(MiscInteractFlag.class)) { - if (entity instanceof Player player) { - BukkitPlayer plotPlayer = BukkitUtil.adapt(player); + if (plotPlayer != null) { if (plot != null) { if (!plot.isAdded(plotPlayer.getUUID())) { plot.debug(plotPlayer.getName() + " couldn't trigger sculk sensors because misc-interact = false"); @@ -115,12 +124,12 @@ public class BlockEventListener117 implements Listener { PlotArea area = location.getPlotArea(); if (area == null) { for (int i = blocks.size() - 1; i >= 0; i--) { - location = BukkitUtil.adapt(blocks.get(i).getLocation()); - if (location.isPlotArea()) { + Location blockLocation = BukkitUtil.adapt(blocks.get(i).getLocation()); + blockLocation = BukkitUtil.adapt(blocks.get(i).getLocation()); + if (blockLocation.isPlotArea()) { blocks.remove(i); } } - return; } else { Plot origin = area.getOwnedPlot(location); if (origin == null) { @@ -128,27 +137,19 @@ public class BlockEventListener117 implements Listener { return; } for (int i = blocks.size() - 1; i >= 0; i--) { - location = BukkitUtil.adapt(blocks.get(i).getLocation()); - if (!area.contains(location.getX(), location.getZ())) { + Location blockLocation = BukkitUtil.adapt(blocks.get(i).getLocation()); + if (!area.contains(blockLocation.getX(), blockLocation.getZ())) { blocks.remove(i); continue; } - Plot plot = area.getOwnedPlot(location); + Plot plot = area.getOwnedPlot(blockLocation); if (!Objects.equals(plot, origin)) { event.getBlocks().remove(i); + continue; + } + if (!area.buildRangeContainsY(location.getY())) { + event.getBlocks().remove(i); } - } - } - Plot origin = area.getPlot(location); - if (origin == null) { - event.setCancelled(true); - return; - } - for (int i = blocks.size() - 1; i >= 0; i--) { - location = BukkitUtil.adapt(blocks.get(i).getLocation()); - Plot plot = area.getOwnedPlot(location); - if (!Objects.equals(plot, origin) && (!plot.isMerged() && !origin.isMerged())) { - event.getBlocks().remove(i); } } } 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 1a09da355..842fbd66d 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java @@ -146,13 +146,11 @@ import org.bukkit.util.Vector; import org.checkerframework.checker.nullness.qual.NonNull; import java.lang.reflect.Field; -import java.util.ArrayList; import java.util.HashSet; import java.util.List; import java.util.Locale; import java.util.Set; import java.util.UUID; -import java.util.regex.Pattern; /** * Player Events involving plots. @@ -1719,6 +1717,7 @@ public class PlayerEventListener extends PlotListener implements Listener { if (PlotSquared.get().getPlotAreaManager().getPlotAreasSet(world).size() == 0) { return; } + BukkitPlayer pp = (event.getEntity() instanceof Player player) ? BukkitUtil.adapt(player) : null; int minX = Integer.MAX_VALUE; int maxX = Integer.MIN_VALUE; int minZ = Integer.MAX_VALUE; @@ -1740,6 +1739,10 @@ public class PlayerEventListener extends PlotListener implements Listener { if (area == null) { continue; } + if (area.notifyIfOutsideBuildArea(pp, location.getY())) { + event.setCancelled(true); + return; + } Plot plot = location.getOwnedPlot(); if (plot == null) { if (area.isRoadFlags() && area.getRoadFlag(DenyPortalsFlag.class)) { diff --git a/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java b/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java index fb42e9881..352614832 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java +++ b/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java @@ -36,6 +36,7 @@ import com.plotsquared.core.location.BlockLoc; import com.plotsquared.core.location.Direction; import com.plotsquared.core.location.Location; import com.plotsquared.core.location.PlotLoc; +import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.ConsolePlayer; import com.plotsquared.core.player.MetaDataAccess; import com.plotsquared.core.player.PlayerMetaDataKeys; @@ -48,6 +49,7 @@ import com.plotsquared.core.plot.flag.implementations.DoneFlag; import com.plotsquared.core.queue.GlobalBlockQueue; import com.plotsquared.core.queue.QueueCoordinator; import com.plotsquared.core.util.MathMan; +import com.plotsquared.core.util.Permissions; import com.plotsquared.core.util.PlotExpression; import com.plotsquared.core.util.RegionUtil; import com.plotsquared.core.util.StringMan; @@ -624,6 +626,38 @@ public abstract class PlotArea { getRegionAbs() == null || this.region.contains(location.getBlockVector3())); } + /** + * Get if the {@code PlotArea}'s build range (min build height -> max build height) contains the given y value + * + * @param y y height + * @return if build height contains y + */ + public boolean buildRangeContainsY(int y) { + return y >= minBuildHeight && y < maxBuildHeight; + } + + /** + * Utility method to check if the player is attempting to place blocks outside the build area, and notify of this if the + * player does not have permissions. + * + * @param player Player to check + * @param y y height to check + * @return true if outside build area with no permissions + * @since TODO + */ + public boolean notifyIfOutsideBuildArea(PlotPlayer player, int y) { + if (!buildRangeContainsY(y) && !Permissions.hasPermission(player, Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) { + player.sendMessage( + TranslatableCaption.of("height.height_limit"), + Template.of("minHeight", String.valueOf(minBuildHeight)), + Template.of("maxHeight", String.valueOf(maxBuildHeight)) + ); + // Return true if "failed" as the method will always be inverted otherwise + return true; + } + return false; + } + public @NonNull Set getPlotsAbs(final UUID uuid) { if (uuid == null) { return Collections.emptySet(); 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 d1ad9386c..e91c7b35b 100644 --- a/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java +++ b/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java @@ -332,6 +332,15 @@ public class EventDispatcher { ) { PlotArea area = location.getPlotArea(); assert area != null; + if (!area.buildRangeContainsY(location.getY()) && !Permissions + .hasPermission(player, Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) { + player.sendMessage( + TranslatableCaption.of("height.height_limit"), + Template.of("minHeight", String.valueOf(area.getMinBuildHeight())), + Template.of("maxHeight", String.valueOf(area.getMaxBuildHeight())) + ); + return false; + } Plot plot = area.getPlot(location); if (plot != null) { if (plot.isAdded(player.getUUID())) { From 312cb2996c6551247f992ee6c9d12257af8edaa6 Mon Sep 17 00:00:00 2001 From: Traks <58818927+traksag@users.noreply.github.com> Date: Wed, 22 Jun 2022 13:50:46 +0200 Subject: [PATCH 003/111] Better handling of offline projectile shooters (#3705) --- .../bukkit/listener/ProjectileEventListener.java | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java index 4293038df..2f37df132 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java @@ -149,6 +149,18 @@ public class ProjectileEventListener implements Listener { Plot plot = area.getPlot(location); ProjectileSource shooter = entity.getShooter(); if (shooter instanceof Player) { + if (!((Player) shooter).isOnline()) { + if (plot != null) { + if (plot.isAdded(((Player) shooter).getUniqueId()) || plot.getFlag(ProjectilesFlag.class)) { + return; + } + } + + entity.remove(); + event.setCancelled(true); + return; + } + PlotPlayer pp = BukkitUtil.adapt((Player) shooter); if (plot == null) { if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_PROJECTILE_UNOWNED)) { From c09d0d882ee075872c98c13b04db57abf4e442f5 Mon Sep 17 00:00:00 2001 From: Traks <58818927+traksag@users.noreply.github.com> Date: Wed, 22 Jun 2022 13:50:56 +0200 Subject: [PATCH 004/111] Use single PlotListener instance (#3704) --- .../bukkit/listener/PlayerEventListener.java | 26 ++++++++++--------- 1 file changed, 14 insertions(+), 12 deletions(-) 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 842fbd66d..6eddc83e1 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java @@ -156,7 +156,7 @@ import java.util.UUID; * Player Events involving plots. */ @SuppressWarnings("unused") -public class PlayerEventListener extends PlotListener implements Listener { +public class PlayerEventListener implements Listener { private static final Set MINECARTS = Set.of( Material.MINECART, @@ -175,6 +175,7 @@ public class PlayerEventListener extends PlotListener implements Listener { private final EventDispatcher eventDispatcher; private final WorldEdit worldEdit; private final PlotAreaManager plotAreaManager; + private final PlotListener plotListener; // To prevent recursion private boolean tmpTeleport = true; private Field fieldPlayer; @@ -194,12 +195,13 @@ public class PlayerEventListener extends PlotListener implements Listener { public PlayerEventListener( final @NonNull PlotAreaManager plotAreaManager, final @NonNull EventDispatcher eventDispatcher, - final @NonNull WorldEdit worldEdit + final @NonNull WorldEdit worldEdit, + final @NonNull PlotListener plotListener ) { - super(eventDispatcher); this.eventDispatcher = eventDispatcher; this.worldEdit = worldEdit; this.plotAreaManager = plotAreaManager; + this.plotListener = plotListener; } @EventHandler @@ -352,7 +354,7 @@ public class PlayerEventListener extends PlotListener implements Listener { if (area != null) { Plot plot = area.getPlot(location); if (plot != null) { - plotEntry(pp, plot); + plotListener.plotEntry(pp, plot); } } // Delayed @@ -404,7 +406,7 @@ public class PlayerEventListener extends PlotListener implements Listener { PlotArea area = location.getPlotArea(); if (area == null) { if (lastPlot != null) { - plotExit(pp, lastPlot); + plotListener.plotExit(pp, lastPlot); lastPlotAccess.remove(); } try (final MetaDataAccess lastLocationAccess = @@ -538,7 +540,7 @@ public class PlayerEventListener extends PlotListener implements Listener { if (now == null) { try (final MetaDataAccess kickAccess = pp.accessTemporaryMetaData(PlayerMetaDataKeys.TEMPORARY_KICK)) { - if (lastPlot != null && !plotExit(pp, lastPlot) && this.tmpTeleport && !kickAccess.get().orElse(false)) { + if (lastPlot != null && !plotListener.plotExit(pp, lastPlot) && this.tmpTeleport && !kickAccess.get().orElse(false)) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_EXIT_DENIED)) @@ -556,7 +558,7 @@ public class PlayerEventListener extends PlotListener implements Listener { } } else if (now.equals(lastPlot)) { ForceFieldListener.handleForcefield(player, pp, now); - } else if (!plotEntry(pp, now) && this.tmpTeleport) { + } else if (!plotListener.plotEntry(pp, now) && this.tmpTeleport) { pp.sendMessage( TranslatableCaption.of("deny.no_enter"), Template.of("plot", now.toString()) @@ -628,7 +630,7 @@ public class PlayerEventListener extends PlotListener implements Listener { if (plot == null) { try (final MetaDataAccess kickAccess = pp.accessTemporaryMetaData(PlayerMetaDataKeys.TEMPORARY_KICK)) { - if (lastPlot != null && !plotExit(pp, lastPlot) && this.tmpTeleport && !kickAccess.get().orElse(false)) { + if (lastPlot != null && !plotListener.plotExit(pp, lastPlot) && this.tmpTeleport && !kickAccess.get().orElse(false)) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_EXIT_DENIED)) @@ -646,7 +648,7 @@ public class PlayerEventListener extends PlotListener implements Listener { } } else if (plot.equals(lastPlot)) { ForceFieldListener.handleForcefield(player, pp, plot); - } else if (!plotEntry(pp, plot) && this.tmpTeleport) { + } else if (!plotListener.plotEntry(pp, plot) && this.tmpTeleport) { pp.sendMessage( TranslatableCaption.of("deny.no_enter"), Template.of("plot", plot.toString()) @@ -793,7 +795,7 @@ public class PlayerEventListener extends PlotListener implements Listener { lastLocationAccess.remove(); } if (plot != null) { - plotExit(pp, plot); + plotListener.plotExit(pp, plot); } if (this.worldEdit != null) { if (!Permissions.hasPermission(pp, Permission.PERMISSION_WORLDEDIT_BYPASS)) { @@ -807,7 +809,7 @@ public class PlayerEventListener extends PlotListener implements Listener { if (location.isPlotArea()) { plot = location.getPlot(); if (plot != null) { - plotEntry(pp, plot); + plotListener.plotEntry(pp, plot); } } } @@ -1280,7 +1282,7 @@ public class PlayerEventListener extends PlotListener implements Listener { TaskManager.removeFromTeleportQueue(event.getPlayer().getName()); BukkitPlayer pp = BukkitUtil.adapt(event.getPlayer()); pp.unregister(); - this.logout(pp.getUUID()); + plotListener.logout(pp.getUUID()); } @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) From f4b886d977d56940aab57a1a4258917becf7fe68 Mon Sep 17 00:00:00 2001 From: Jordan Date: Thu, 23 Jun 2022 18:18:29 +0100 Subject: [PATCH 005/111] Minor cleanup of the plot analyze code (#3708) - No need to wrap the final analysis into another async method. It's already contained in an async task - Don't overstretch a chunk bounday when setting blocks to newBlocks array --- .../java/com/plotsquared/core/generator/HybridUtils.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java b/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java index fcfbe1bf8..cc00345bd 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java @@ -189,13 +189,13 @@ public class HybridUtils { if (X == ctx) { maxX = tx & 15; } else { - maxX = 16; + maxX = 15; } int maxZ; if (Z == ctz) { maxZ = tz & 15; } else { - maxZ = 16; + maxZ = 15; } int chunkBlockX = X << 4; @@ -221,7 +221,7 @@ public class HybridUtils { } }); - final Runnable run = () -> TaskManager.runTaskAsync(() -> { + final Runnable run = () -> { int size = width * length; int[] changes = new int[size]; int[] faces = new int[size]; @@ -296,7 +296,7 @@ public class HybridUtils { analysis.variety_sd = (int) (MathMan.getSD(variety, analysis.variety) * 100); whenDone.value = analysis; whenDone.run(); - }); + }; queue.setCompleteTask(run); queue.enqueue(); }); From 26bec7fe2f89f1ea98a06a7adf56d70996ad2a19 Mon Sep 17 00:00:00 2001 From: NotMyFault Date: Sun, 26 Jun 2022 11:18:33 +0200 Subject: [PATCH 006/111] style: Address javadoc violations --- .../src/main/java/com/plotsquared/core/location/Location.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/location/Location.java b/Core/src/main/java/com/plotsquared/core/location/Location.java index b2363db8e..369e2d33f 100644 --- a/Core/src/main/java/com/plotsquared/core/location/Location.java +++ b/Core/src/main/java/com/plotsquared/core/location/Location.java @@ -313,7 +313,7 @@ public sealed class Location extends BlockLoc implements Comparable pe /** * Get the absolute {@link Plot}, if any, that contains this location * - * @return (Absolute) plot containing the location, or {code null} + * @return (Absolute) plot containing the location, or {@code null} */ public @Nullable Plot getPlotAbs() { final PlotArea area = this.getPlotArea(); @@ -327,7 +327,7 @@ public sealed class Location extends BlockLoc implements Comparable pe /** * Get the {@link Plot}, if any, that contains this location * - * @return plot containing the location, or {code null} + * @return plot containing the location, or {@code null} */ public @Nullable Plot getPlot() { final PlotArea area = this.getPlotArea(); From 005600c99eec6eac0ce5823cccb47a26de754bab Mon Sep 17 00:00:00 2001 From: Traks <58818927+traksag@users.noreply.github.com> Date: Mon, 27 Jun 2022 13:31:45 +0200 Subject: [PATCH 007/111] Show old flag value in remove command (#3711) --- .../main/java/com/plotsquared/core/command/FlagCommand.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/FlagCommand.java b/Core/src/main/java/com/plotsquared/core/command/FlagCommand.java index f5868c031..16d28c38a 100644 --- a/Core/src/main/java/com/plotsquared/core/command/FlagCommand.java +++ b/Core/src/main/java/com/plotsquared/core/command/FlagCommand.java @@ -462,6 +462,7 @@ public final class FlagCommand extends Command { return; } final Plot plot = player.getLocation().getPlotAbs(); + final PlotFlag flagWithOldValue = plot.getFlagContainer().getFlag(flag.getClass()); PlotFlagRemoveEvent event = eventDispatcher.callFlagRemove(flag, plot); if (event.getEventResult() == Result.DENY) { player.sendMessage( @@ -506,7 +507,7 @@ public final class FlagCommand extends Command { if (plot.removeFlag(flag)) { player.sendMessage(TranslatableCaption.of("flag.flag_removed"), Template.of("flag", args[0]), Template.of( "value", - String.valueOf(flag) + String.valueOf(flagWithOldValue) )); return; } else { @@ -544,7 +545,7 @@ public final class FlagCommand extends Command { } player.sendMessage(TranslatableCaption.of("flag.flag_removed"), Template.of("flag", args[0]), Template.of( "value", - String.valueOf(flag) + String.valueOf(flagWithOldValue) )); } From 263cb47a2104215cd7cc09959023e874bd97dde8 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 27 Jun 2022 14:56:44 +0200 Subject: [PATCH 008/111] build: Release 6.9.1 --- .../com/plotsquared/core/generator/HybridPlotWorld.java | 7 +++++-- Core/src/main/java/com/plotsquared/core/plot/PlotArea.java | 2 +- build.gradle.kts | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index 054410817..c14b4f29e 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -21,6 +21,7 @@ package com.plotsquared.core.generator; import com.google.inject.Inject; import com.google.inject.assistedinject.Assisted; import com.intellectualsites.annotations.DoNotUse; +import com.intellectualsites.annotations.NotPublic; import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.ConfigurationSection; import com.plotsquared.core.configuration.Settings; @@ -480,7 +481,8 @@ public class HybridPlotWorld extends ClassicPlotWorld { /** * @deprecated This method should not be available for public API usage and will be made private. */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(since = "6.9.1") + @NotPublic public void addOverlayBlock(short x, short y, short z, BaseBlock id, boolean rotate, int height) { if (z < 0) { z += this.SIZE; @@ -510,7 +512,8 @@ public class HybridPlotWorld extends ClassicPlotWorld { /** * @deprecated This method should not be available for public API usage and will be made private. */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(since = "6.9.1") + @NotPublic public void addOverlayBiome(short x, short z, BiomeType id) { if (z < 0) { z += this.SIZE; diff --git a/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java b/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java index 352614832..63f5577ba 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java +++ b/Core/src/main/java/com/plotsquared/core/plot/PlotArea.java @@ -643,7 +643,7 @@ public abstract class PlotArea { * @param player Player to check * @param y y height to check * @return true if outside build area with no permissions - * @since TODO + * @since 6.9.1 */ public boolean notifyIfOutsideBuildArea(PlotPlayer player, int y) { if (!buildRangeContainsY(y) && !Permissions.hasPermission(player, Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) { diff --git a/build.gradle.kts b/build.gradle.kts index 7f9d801ae..955a9aaab 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.1-SNAPSHOT" +version = "6.9.1" subprojects { group = rootProject.group From 5f4c8d92df053aca1dfcd1312e2569ad0883a8e5 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 27 Jun 2022 14:57:32 +0200 Subject: [PATCH 009/111] build: Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 955a9aaab..5460ee674 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.1" +version = "6.9.2-SNAPSHOT" subprojects { group = rootProject.group From cd9f0789de937646205b087d4e408a2e0d50544e Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 27 Jun 2022 16:47:32 +0200 Subject: [PATCH 010/111] build: Update bom to 1.9 --- build.gradle.kts | 2 +- renovate.json | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 5460ee674..9bbefc5f5 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.7")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.9")) } dependencies { diff --git a/renovate.json b/renovate.json index fd1e7e57b..48ca5d129 100644 --- a/renovate.json +++ b/renovate.json @@ -3,10 +3,6 @@ "config:base", ":disableDependencyDashboard" ], - "timezone": "Europe/Berlin", - "schedule": [ - "every monday" - ], "labels": ["Renovate"], "commitMessagePrefix": "build: ", "rebaseWhen": "conflicted" From e90fd231d919e4e8bc6e2e70937a53ddada9fd03 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 27 Jun 2022 17:00:13 +0200 Subject: [PATCH 011/111] build: Update dependency com.github.spotbugs:spotbugs-annotations to v4.7.1 (#3714) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 256a4d926..6ac4baec2 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -2,7 +2,7 @@ # Platform expectations paper = "1.18.1-R0.1-SNAPSHOT" guice = "5.1.0" -spotbugs = "4.7.0" +spotbugs = "4.7.1" # Plugins worldedit = "7.2.10" From 91017acce48ec4ffa04747cf28c05a621367619e Mon Sep 17 00:00:00 2001 From: dordsor21 Date: Mon, 27 Jun 2022 17:41:47 +0100 Subject: [PATCH 012/111] Realistically only need the "highest" y level of adding overlay block errors --- .../java/com/plotsquared/core/generator/HybridPlotWorld.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index c14b4f29e..b4598fad6 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -500,7 +500,7 @@ public class HybridPlotWorld extends ClassicPlotWorld { int pair = MathMan.pair(x, z); BaseBlock[] existing = this.G_SCH.computeIfAbsent(pair, k -> new BaseBlock[height]); if (y >= height) { - if (y != lastOverlayHeightError) { + if (y > lastOverlayHeightError) { lastOverlayHeightError = y; LOGGER.error(String.format("Error adding overlay block. `y > height`. y=%s, height=%s", y, height)); } From 4d4d2ab0871f5bcc66d25a7b24bcf1c36fb4e371 Mon Sep 17 00:00:00 2001 From: Traks <58818927+traksag@users.noreply.github.com> Date: Tue, 28 Jun 2022 21:15:09 +0200 Subject: [PATCH 013/111] Ignore cancelled projectile launch events (#3709) --- .../plotsquared/bukkit/listener/ProjectileEventListener.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java index 2f37df132..743649a80 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java @@ -89,7 +89,7 @@ public class ProjectileEventListener implements Listener { } } - @EventHandler + @EventHandler(ignoreCancelled = true) public void onProjectileLaunch(ProjectileLaunchEvent event) { Projectile entity = event.getEntity(); ProjectileSource shooter = entity.getShooter(); From 7f436c405b65049b0f6ddfc42fafda0b190bf71e Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sun, 3 Jul 2022 14:58:17 +0200 Subject: [PATCH 014/111] fix: Don't fail post processing compilation on non-ascii charmap (#3719) --- Bukkit/build.gradle.kts | 1 + Core/build.gradle.kts | 1 + 2 files changed, 2 insertions(+) diff --git a/Bukkit/build.gradle.kts b/Bukkit/build.gradle.kts index 958f4627a..5b9bcbf21 100644 --- a/Bukkit/build.gradle.kts +++ b/Bukkit/build.gradle.kts @@ -105,5 +105,6 @@ tasks { opt.links("https://jd.adventure.kyori.net/api/4.9.3/") opt.links("https://google.github.io/guice/api-docs/" + libs.guice.get().versionConstraint.toString() + "/javadoc/") opt.links("https://checkerframework.org/api/") + opt.encoding("UTF-8") } } diff --git a/Core/build.gradle.kts b/Core/build.gradle.kts index 284b5399b..d5103d1a6 100644 --- a/Core/build.gradle.kts +++ b/Core/build.gradle.kts @@ -64,5 +64,6 @@ tasks { opt.links("https://google.github.io/guice/api-docs/" + libs.guice.get().versionConstraint.toString() + "/javadoc/") opt.links("https://checkerframework.org/api/") opt.links("https://javadoc.io/doc/com.intellectualsites.informative-annotations/informative-annotations/latest/") + opt.encoding("UTF-8") } } From 31e777a03acaaba70531453d516ef5c13dab0340 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 4 Jul 2022 14:07:14 +0200 Subject: [PATCH 015/111] build: Update dependency me.clip:placeholderapi to v2.11.2 (#3720) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 6ac4baec2..e39fa1505 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -6,7 +6,7 @@ spotbugs = "4.7.1" # Plugins worldedit = "7.2.10" -placeholderapi = "2.11.1" +placeholderapi = "2.11.2" luckperms = "5.4" essentialsx = "2.19.4" mvdwapi = "3.1.1" From 12e27052602bce21b24419ac721c141a754df098 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 5 Jul 2022 15:02:25 +0200 Subject: [PATCH 016/111] Revert #3681 (#3722) Revert "Adjust schematic height logic when pasting and actually set air as well (#3681)" This reverts commit 08ce4c872c0f7a95e1106a4f2ee6030ee92f4de0. --- .../core/generator/HybridPlotWorld.java | 125 ++++++------------ 1 file changed, 40 insertions(+), 85 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index b4598fad6..5fb6ad868 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -75,9 +75,6 @@ public class HybridPlotWorld extends ClassicPlotWorld { public short PATH_WIDTH_UPPER; public HashMap G_SCH; public HashMap G_SCH_B; - /** - * The Y level at which schematic generation will start, lowest of either road or plot schematic generation. - */ public int SCHEM_Y; private Location SIGN_LOCATION; private File root = null; @@ -270,57 +267,33 @@ public class HybridPlotWorld extends ClassicPlotWorld { int oddshift = (this.ROAD_WIDTH & 1); SCHEM_Y = schematicStartHeight(); - - // plotY and roadY are important to allow plot and/or road schematic "overflow" into each other without causing AIOOB - // exceptions when attempting either to set blocks to, or get block from G_SCH - // Default plot schematic start height, normalized to the minimum height schematics are pasted from. int plotY = PLOT_HEIGHT - SCHEM_Y; int minRoadWall = Settings.Schematics.USE_WALL_IN_ROAD_SCHEM_HEIGHT ? Math.min(ROAD_HEIGHT, WALL_HEIGHT) : ROAD_HEIGHT; - // Default road schematic start height, normalized to the minimum height schematics are pasted from. int roadY = minRoadWall - SCHEM_Y; - int worldGenHeight = getMaxGenHeight() - getMinGenHeight() + 1; - - int maxSchematicHeight = 0; + int worldHeight = getMaxGenHeight() - getMinGenHeight() + 1; // SCHEM_Y should be normalised to the plot "start" height if (schematic3 != null) { - if ((maxSchematicHeight = schematic3.getClipboard().getDimensions().getY()) == worldGenHeight) { - SCHEM_Y = getMinGenHeight(); - plotY = 0; + if (schematic3.getClipboard().getDimensions().getY() == worldHeight) { + SCHEM_Y = plotY = 0; } else if (!Settings.Schematics.PASTE_ON_TOP) { - SCHEM_Y = getMinBuildHeight(); - plotY = 0; + SCHEM_Y = plotY = getMinBuildHeight() - getMinGenHeight(); } } if (schematic1 != null) { - if ((maxSchematicHeight = Math.max( - schematic1.getClipboard().getDimensions().getY(), - maxSchematicHeight - )) == worldGenHeight) { - SCHEM_Y = getMinGenHeight(); - roadY = 0; // Road is the lowest schematic - if (schematic3 != null && schematic3.getClipboard().getDimensions().getY() != worldGenHeight) { - // Road is the lowest schematic. Normalize plotY to it. - if (Settings.Schematics.PASTE_ON_TOP) { - plotY = PLOT_HEIGHT - getMinGenHeight(); - } else { - plotY = getMinBuildHeight() - getMinGenHeight(); - } + if (schematic1.getClipboard().getDimensions().getY() == worldHeight) { + SCHEM_Y = roadY = getMinGenHeight(); + if (schematic3 != null && schematic3.getClipboard().getDimensions().getY() != worldHeight + && !Settings.Schematics.PASTE_ON_TOP) { + plotY = PLOT_HEIGHT; } } else if (!Settings.Schematics.PASTE_ROAD_ON_TOP) { - if (SCHEM_Y == getMinGenHeight()) { // Only possible if plot schematic is enabled - // Plot is still the lowest schematic, normalize roadY to it - roadY = getMinBuildHeight() - getMinGenHeight(); - } else if (schematic3 != null) { - SCHEM_Y = getMinBuildHeight(); - roadY = 0;// Road is the lowest schematic - if (Settings.Schematics.PASTE_ON_TOP) { - // Road is the lowest schematic. Normalize plotY to it. - plotY = PLOT_HEIGHT - getMinBuildHeight(); - } - // If plot schematic is not paste-on-top, it will be from min build height thus plotY = 0 as well already. + SCHEM_Y = roadY = getMinBuildHeight(); + if (schematic3 != null && schematic3.getClipboard().getDimensions().getY() != worldHeight + && !Settings.Schematics.PASTE_ON_TOP) { + plotY = PLOT_HEIGHT; } } } @@ -358,15 +331,17 @@ public class HybridPlotWorld extends ClassicPlotWorld { y + min.getBlockY(), z + min.getBlockZ() )); - schem3PopulationNeeded |= id.hasNbtData(); - addOverlayBlock( - (short) (x + shift + oddshift + centerShiftX), - (short) (y + plotY), - (short) (z + shift + oddshift + centerShiftZ), - id, - false, - maxSchematicHeight - ); + if (!id.getBlockType().getMaterial().isAir()) { + schem3PopulationNeeded |= id.hasNbtData(); + addOverlayBlock( + (short) (x + shift + oddshift + centerShiftX), + (short) (y + plotY), + (short) (z + shift + oddshift + centerShiftZ), + id, + false, + h3 + ); + } } if (blockArrayClipboard3.hasBiomes()) { BiomeType biome = blockArrayClipboard3.getBiome(BlockVector2.at( @@ -416,23 +391,18 @@ public class HybridPlotWorld extends ClassicPlotWorld { y + min.getBlockY(), z + min.getBlockZ() )); - schem1PopulationNeeded |= id.hasNbtData(); - addOverlayBlock( - (short) (x - shift), - (short) (y + roadY), - (short) (z + shift + oddshift), - id, - false, - maxSchematicHeight - ); - addOverlayBlock( - (short) (z + shift + oddshift), - (short) (y + roadY), - (short) (shift - x + (oddshift - 1)), - id, - true, - maxSchematicHeight - ); + if (!id.getBlockType().getMaterial().isAir()) { + schem1PopulationNeeded |= id.hasNbtData(); + addOverlayBlock((short) (x - shift), (short) (y + roadY), (short) (z + shift + oddshift), id, false, h1); + addOverlayBlock( + (short) (z + shift + oddshift), + (short) (y + roadY), + (short) (shift - x + (oddshift - 1)), + id, + true, + h1 + ); + } } if (blockArrayClipboard1.hasBiomes()) { BiomeType biome = blockArrayClipboard1.getBiome(BlockVector2.at(x + min.getBlockX(), z + min.getBlockZ())); @@ -460,15 +430,10 @@ public class HybridPlotWorld extends ClassicPlotWorld { y + min.getBlockY(), z + min.getBlockZ() )); - schem2PopulationNeeded |= id.hasNbtData(); - addOverlayBlock( - (short) (x - shift), - (short) (y + roadY), - (short) (z - shift), - id, - false, - maxSchematicHeight - ); + if (!id.getBlockType().getMaterial().isAir()) { + schem2PopulationNeeded |= id.hasNbtData(); + addOverlayBlock((short) (x - shift), (short) (y + roadY), (short) (z - shift), id, false, h2); + } } if (blockArrayClipboard2.hasBiomes()) { BiomeType biome = blockArrayClipboard2.getBiome(BlockVector2.at(x + min.getBlockX(), z + min.getBlockZ())); @@ -478,11 +443,6 @@ public class HybridPlotWorld extends ClassicPlotWorld { } } - /** - * @deprecated This method should not be available for public API usage and will be made private. - */ - @Deprecated(since = "6.9.1") - @NotPublic public void addOverlayBlock(short x, short y, short z, BaseBlock id, boolean rotate, int height) { if (z < 0) { z += this.SIZE; @@ -509,11 +469,6 @@ public class HybridPlotWorld extends ClassicPlotWorld { existing[y] = id; } - /** - * @deprecated This method should not be available for public API usage and will be made private. - */ - @Deprecated(since = "6.9.1") - @NotPublic public void addOverlayBiome(short x, short z, BiomeType id) { if (z < 0) { z += this.SIZE; From 3676e1df35cab342d41d625a4271204f18c2cc84 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 5 Jul 2022 22:25:57 +0200 Subject: [PATCH 017/111] build: Release 6.9.2 --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 9bbefc5f5..7c865d74b 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.2-SNAPSHOT" +version = "6.9.2" subprojects { group = rootProject.group From c446a95b0751dab9f6946100dd775c89a7a6fdd1 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 5 Jul 2022 22:26:52 +0200 Subject: [PATCH 018/111] build: Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 7c865d74b..9e3ad065b 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.2" +version = "6.9.3-SNAPSHOT" subprojects { group = rootProject.group From 73d2686b177e38fa0cc553d20a13a68c2305bc8a Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 6 Jul 2022 00:14:20 +0200 Subject: [PATCH 019/111] build: Update dependency com.intellectualsites.bom:bom-1.18.x to v1.10 (#3723) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 9e3ad065b..1b3de5b12 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.9")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.10")) } dependencies { From 93f6de702936b21e1e7dc434cb53d23e068cf56d Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 15 Jul 2022 10:03:27 +0200 Subject: [PATCH 020/111] build: Update dependency gradle to v7.5 (#3727) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/wrapper/gradle-wrapper.jar | Bin 59821 -> 60756 bytes gradle/wrapper/gradle-wrapper.properties | 2 +- gradlew | 6 ++++++ gradlew.bat | 14 ++++++++------ 4 files changed, 15 insertions(+), 7 deletions(-) diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 41d9927a4d4fb3f96a785543079b8df6723c946b..249e5832f090a2944b7473328c07c9755baa3196 100644 GIT binary patch delta 10197 zcmaKS1ymhDwk=#NxVyW%y9U<)A-Dv)xI0|j{UX8L-JRg>5ZnnKAh;%chM6~S-g^K4 z>eZ{yK4;gd>gwvXs=Id8Jk-J}R4pT911;+{Jp9@aiz6!p1Oz9z&_kGLA%J5%3Ih@0 zQ|U}%$)3u|G`jIfPzMVfcWs?jV2BO^*3+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gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index aa991fcea..8049c684f 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-7.4.2-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew index 1b6c78733..a69d9cb6c 100755 --- a/gradlew +++ b/gradlew @@ -205,6 +205,12 @@ set -- \ org.gradle.wrapper.GradleWrapperMain \ "$@" +# Stop when "xargs" is not available. +if ! command -v xargs >/dev/null 2>&1 +then + die "xargs is not available" +fi + # Use "xargs" to parse quoted args. # # With -n1 it outputs one arg per line, with the quotes and backslashes removed. diff --git a/gradlew.bat b/gradlew.bat index ac1b06f93..53a6b238d 100644 --- a/gradlew.bat +++ b/gradlew.bat @@ -14,7 +14,7 @@ @rem limitations under the License. @rem -@if "%DEBUG%" == "" @echo off +@if "%DEBUG%"=="" @echo off @rem ########################################################################## @rem @rem Gradle startup script for Windows @@ -25,7 +25,7 @@ if "%OS%"=="Windows_NT" setlocal set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. +if "%DIRNAME%"=="" set DIRNAME=. set APP_BASE_NAME=%~n0 set APP_HOME=%DIRNAME% @@ -40,7 +40,7 @@ if defined JAVA_HOME goto findJavaFromJavaHome set JAVA_EXE=java.exe %JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto execute +if %ERRORLEVEL% equ 0 goto execute echo. echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. @@ -75,13 +75,15 @@ set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar :end @rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd +if %ERRORLEVEL% equ 0 goto mainEnd :fail rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% :mainEnd if "%OS%"=="Windows_NT" endlocal From 87f89541b582cd3aac06d378886f59da756ceec9 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 15 Jul 2022 10:04:01 +0200 Subject: [PATCH 021/111] build: Update dependency com.intellectualsites.bom:bom-1.18.x to v1.11 (#3726) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 1b3de5b12..cb5f2a14b 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.10")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.11")) } dependencies { From 276d8f8e1ec8d14d0f5b6e703e5c203c9eb655c4 Mon Sep 17 00:00:00 2001 From: Bernhard Date: Sun, 24 Jul 2022 10:32:29 +0200 Subject: [PATCH 022/111] change message of `/p remove ` if player does not need to be removed (#3734) refactor: change message of `/p remove ` if unnecessary --- Core/src/main/java/com/plotsquared/core/command/Remove.java | 4 ++-- Core/src/main/resources/lang/messages_en.json | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) 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 492a01085..3a2e06a2d 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Remove.java +++ b/Core/src/main/java/com/plotsquared/core/command/Remove.java @@ -115,8 +115,8 @@ public class Remove extends SubCommand { } if (count == 0) { player.sendMessage( - TranslatableCaption.of("errors.invalid_player"), - Template.of("value", args[0]) + TranslatableCaption.of("member.player_not_removed"), + Template.of("player", args[0]) ); } else { player.sendMessage( diff --git a/Core/src/main/resources/lang/messages_en.json b/Core/src/main/resources/lang/messages_en.json index 85c829d8c..397bb0933 100644 --- a/Core/src/main/resources/lang/messages_en.json +++ b/Core/src/main/resources/lang/messages_en.json @@ -414,6 +414,7 @@ "kick.you_got_kicked": "You got kicked from the plot!", "trusted.trusted_added": "You successfully trusted a user to the plot.", "trusted.plot_removed_user": "Plot of which you were added to has been deleted due to owner inactivity.", + "member.player_not_removed": " is neither added, trusted or denied on the plot, thus doesn't need to be removed.", "member.removed_players": "Removed player(s) from this plot.", "member.plot_left": " left the plot.", "member.plot_cant_leave_owner": "You are the plot owner. You cannot leave this plot.", From 98708118d8fd2700ba9e1a85cb05bb0f31058d8c Mon Sep 17 00:00:00 2001 From: Jordan Date: Sun, 24 Jul 2022 14:55:43 +0100 Subject: [PATCH 023/111] Deprecate the static Permissions "util" class that is almost entirely superseded by methods in PermissionHolder instances themselves (#3695) Co-authored-by: Alexander Brandes --- .../plotsquared/core/util/Permissions.java | 32 ++++++++++++++++++- 1 file changed, 31 insertions(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/util/Permissions.java b/Core/src/main/java/com/plotsquared/core/util/Permissions.java index 12d61e013..f3a1df019 100644 --- a/Core/src/main/java/com/plotsquared/core/util/Permissions.java +++ b/Core/src/main/java/com/plotsquared/core/util/Permissions.java @@ -30,9 +30,18 @@ import org.checkerframework.checker.nullness.qual.NonNull; * The Permissions class handles checking user permissions.
* - This will respect * nodes and plots.admin and can be used to check permission ranges (e.g. plots.plot.5)
* - Checking the PlotPlayer class directly will not take the above into account
+ * + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes */ +@Deprecated(forRemoval = true, since = "TODO") public class Permissions { + /** + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes + */ + @Deprecated(forRemoval = true, since = "TODO") public static boolean hasPermission(PlotPlayer player, Permission permission, boolean notify) { return hasPermission(player, permission.toString(), notify); } @@ -43,18 +52,25 @@ public class Permissions { * @param caller permission holder * @param permission Permission * @return {@code true} if the owner has the given permission, else {@code false} + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes */ + @Deprecated(forRemoval = true, since = "TODO") public static boolean hasPermission(final @NonNull PermissionHolder caller, final @NonNull Permission permission) { return caller.hasPermission(permission.toString()); } /** - * Check if the owner of the profile has a given (global) permission + * Check if the owner of the profile has a given (global) permission. There is no guarantee that per-world permissions will + * be checked because unmaintained crap plugins like PEX exist. * * @param caller permission holder * @param permission Permission * @return {@code true} if the owner has the given permission, else {@code false} + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes */ + @Deprecated(forRemoval = true, since = "TODO") public static boolean hasPermission(final @NonNull PermissionHolder caller, final @NonNull String permission) { return caller.hasPermission(permission); } @@ -68,7 +84,10 @@ public class Permissions { * @param key Permission "key" * @return {@code true} if the owner has the given permission, else {@code false} * @since 6.0.10 + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes */ + @Deprecated(forRemoval = true, since = "TODO") public static boolean hasKeyedPermission( final @NonNull PermissionHolder caller, final @NonNull String permission, final @NonNull String key @@ -83,7 +102,10 @@ public class Permissions { * @param permission permission * @param notify if to notify the permission holder * @return if permission is had + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes */ + @Deprecated(forRemoval = true, since = "TODO") public static boolean hasPermission(PlotPlayer player, String permission, boolean notify) { if (!hasPermission(player, permission)) { if (notify) { @@ -97,6 +119,11 @@ public class Permissions { return true; } + /** + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes + */ + @Deprecated(forRemoval = true, since = "TODO") public static int hasPermissionRange(PlotPlayer player, Permission Permission, int range) { return hasPermissionRange(player, Permission.toString(), range); } @@ -110,7 +137,10 @@ public class Permissions { * @param stub The permission stub to check e.g. for `plots.plot.#` the stub is `plots.plot` * @param range The range to check * @return The highest permission they have within that range + * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed + * classes */ + @Deprecated(forRemoval = true, since = "TODO") public static int hasPermissionRange(PlotPlayer player, String stub, int range) { return player.hasPermissionRange(stub, range); } From ae59c7442fa9d55d985a3f279ac2e8b71537f342 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Mon, 25 Jul 2022 21:02:54 +0200 Subject: [PATCH 024/111] fix: improve handling of missing message files (#3718) * improve handling of missing message files * fix javadoc Co-authored-by: Alexander Brandes --- .../plotsquared/bukkit/BukkitPlatform.java | 5 +++ .../com/plotsquared/core/PlotPlatform.java | 5 +++ .../com/plotsquared/core/PlotSquared.java | 5 ++- .../caption/load/CaptionLoader.java | 45 +++++++++++++++---- 4 files changed, 51 insertions(+), 9 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java index 96bccd892..d2da2fb2a 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java @@ -732,6 +732,11 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl this.getServer().getPluginManager().disablePlugin(this); } + @Override + public void shutdownServer() { + getServer().shutdown(); + } + private void registerCommands() { final BukkitCommand bukkitCommand = new BukkitCommand(); final PluginCommand plotCommand = getCommand("plots"); diff --git a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java index 75ceef94d..020c3c740 100644 --- a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java +++ b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java @@ -75,6 +75,11 @@ public interface PlotPlatform

extends LocaleHolder { */ void shutdown(); + /** + * Completely shuts down the server. + */ + void shutdownServer(); + /** * Get the name of the plugin * diff --git a/Core/src/main/java/com/plotsquared/core/PlotSquared.java b/Core/src/main/java/com/plotsquared/core/PlotSquared.java index 9b8d2fd02..5f89c69c1 100644 --- a/Core/src/main/java/com/plotsquared/core/PlotSquared.java +++ b/Core/src/main/java/com/plotsquared/core/PlotSquared.java @@ -197,6 +197,9 @@ public class PlotSquared { this.loadCaptionMap(); } catch (final Exception e) { LOGGER.error("Failed to load caption map", e); + LOGGER.error("Shutting down server to prevent further issues"); + this.platform.shutdownServer(); + throw new RuntimeException("Abort loading PlotSquared"); } // Setup the global flag container @@ -267,7 +270,7 @@ public class PlotSquared { captionMap = this.captionLoader.loadAll(this.platform.getDirectory().toPath().resolve("lang")); } else { String fileName = "messages_" + Settings.Enabled_Components.DEFAULT_LOCALE + ".json"; - captionMap = this.captionLoader.loadSingle(this.platform.getDirectory().toPath().resolve("lang").resolve(fileName)); + captionMap = this.captionLoader.loadOrCreateSingle(this.platform.getDirectory().toPath().resolve("lang").resolve(fileName)); } this.captionMaps.put(TranslatableCaption.DEFAULT_NAMESPACE, captionMap); LOGGER.info( diff --git a/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java b/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java index 4a8b5c14f..ca6e934b0 100644 --- a/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java +++ b/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java @@ -190,13 +190,14 @@ public final class CaptionLoader { /** * Load a message file into a new CaptionMap. The file name must match - * the pattern {@code messages_.json} where {@code } - * is a valid {@link Locale} string. + * the pattern expected by the {@link #localeExtractor}. + * Note that this method does not attempt to create a new file. * * @param file The file to load * @return A new CaptionMap containing the loaded messages * @throws IOException if the file couldn't be accessed or read successfully. * @throws IllegalArgumentException if the file name doesn't match the specified format. + * @see #loadOrCreateSingle(Path) */ public @NonNull CaptionMap loadSingle(final @NonNull Path file) throws IOException { final Locale locale = this.localeExtractor.apply(file); @@ -205,15 +206,43 @@ public final class CaptionLoader { if (patch(map, locale)) { save(file, map); // update the file using the modified map } - return new LocalizedCaptionMap(locale, map.entrySet().stream() - .collect(Collectors.toMap( - entry -> TranslatableCaption.of(this.namespace, entry.getKey()), - Map.Entry::getValue - ) - )); + return new LocalizedCaptionMap(locale, mapToCaptions(map)); } } + /** + * Load a message file into a new CaptionMap. The file name must match + * the pattern expected by the {@link #localeExtractor}. + * If no file exists at the given path, this method will + * attempt to create one and fill it with default values. + * + * @param file The file to load + * @return A new CaptionMap containing the loaded messages + * @throws IOException if the file couldn't be accessed or read successfully. + * @throws IllegalArgumentException if the file name doesn't match the specified format. + * @see #loadSingle(Path) + * @since TODO + */ + public @NonNull CaptionMap loadOrCreateSingle(final @NonNull Path file) throws IOException { + final Locale locale = this.localeExtractor.apply(file); + if (!Files.exists(file) ) { + Map map = new LinkedHashMap<>(); + patch(map, locale); + save(file, map); + return new LocalizedCaptionMap(locale, mapToCaptions(map)); + } else { + return loadSingle(file); + } + } + + private @NonNull Map mapToCaptions(Map map) { + return map.entrySet().stream().collect( + Collectors.toMap( + entry -> TranslatableCaption.of(this.namespace, entry.getKey()), + Map.Entry::getValue + )); + } + /** * Add missing entries to the given map. * Entries are missing if the key exists in {@link #defaultLocale} but isn't present From dcf98c229827ccdfdf56c2217c29bfac0ed142b1 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 25 Jul 2022 21:10:39 +0200 Subject: [PATCH 025/111] build: Release 6.9.3 --- .../caption/load/CaptionLoader.java | 4 ++-- .../com/plotsquared/core/util/Permissions.java | 16 ++++++++-------- build.gradle.kts | 2 +- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java b/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java index ca6e934b0..68d99220c 100644 --- a/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java +++ b/Core/src/main/java/com/plotsquared/core/configuration/caption/load/CaptionLoader.java @@ -174,7 +174,7 @@ public final class CaptionLoader { public @NonNull CaptionMap loadAll(final @NonNull Path directory) throws IOException { final Map localeMaps = new HashMap<>(); try (final Stream files = Files.list(directory)) { - final List captionFiles = files.filter(Files::isRegularFile).collect(Collectors.toList()); + final List captionFiles = files.filter(Files::isRegularFile).toList(); for (Path file : captionFiles) { try { final CaptionMap localeMap = loadSingle(file); @@ -221,7 +221,7 @@ public final class CaptionLoader { * @throws IOException if the file couldn't be accessed or read successfully. * @throws IllegalArgumentException if the file name doesn't match the specified format. * @see #loadSingle(Path) - * @since TODO + * @since 6.9.3 */ public @NonNull CaptionMap loadOrCreateSingle(final @NonNull Path file) throws IOException { final Locale locale = this.localeExtractor.apply(file); diff --git a/Core/src/main/java/com/plotsquared/core/util/Permissions.java b/Core/src/main/java/com/plotsquared/core/util/Permissions.java index f3a1df019..06d0ddbee 100644 --- a/Core/src/main/java/com/plotsquared/core/util/Permissions.java +++ b/Core/src/main/java/com/plotsquared/core/util/Permissions.java @@ -34,14 +34,14 @@ import org.checkerframework.checker.nullness.qual.NonNull; * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ -@Deprecated(forRemoval = true, since = "TODO") +@Deprecated(forRemoval = true, since = "6.9.3") public class Permissions { /** * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static boolean hasPermission(PlotPlayer player, Permission permission, boolean notify) { return hasPermission(player, permission.toString(), notify); } @@ -55,7 +55,7 @@ public class Permissions { * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static boolean hasPermission(final @NonNull PermissionHolder caller, final @NonNull Permission permission) { return caller.hasPermission(permission.toString()); } @@ -70,7 +70,7 @@ public class Permissions { * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static boolean hasPermission(final @NonNull PermissionHolder caller, final @NonNull String permission) { return caller.hasPermission(permission); } @@ -87,7 +87,7 @@ public class Permissions { * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static boolean hasKeyedPermission( final @NonNull PermissionHolder caller, final @NonNull String permission, final @NonNull String key @@ -105,7 +105,7 @@ public class Permissions { * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static boolean hasPermission(PlotPlayer player, String permission, boolean notify) { if (!hasPermission(player, permission)) { if (notify) { @@ -123,7 +123,7 @@ public class Permissions { * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static int hasPermissionRange(PlotPlayer player, Permission Permission, int range) { return hasPermissionRange(player, Permission.toString(), range); } @@ -140,7 +140,7 @@ public class Permissions { * @deprecated all logic that may once have been in the class lives elsewhere. We also want to do away with statically-accessed * classes */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.9.3") public static int hasPermissionRange(PlotPlayer player, String stub, int range) { return player.hasPermissionRange(stub, range); } diff --git a/build.gradle.kts b/build.gradle.kts index cb5f2a14b..636c715cc 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.3-SNAPSHOT" +version = "6.9.3" subprojects { group = rootProject.group From c8f4907f77872dddbd5f0cdc40bad38e7e74c03b Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 25 Jul 2022 21:11:35 +0200 Subject: [PATCH 026/111] build: Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 636c715cc..281f9c257 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.3" +version = "6.9.4-SNAPSHOT" subprojects { group = rootProject.group From 0e4319b75749b826b24b499a328d35148585688d Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 26 Jul 2022 22:47:25 +0200 Subject: [PATCH 027/111] build: Update dependency org.junit.jupiter:junit-jupiter to v5.9.0 (#3741) * build: Update dependency org.junit.jupiter:junit-jupiter to v5.9.0 * Update renovate.json Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Alexander Brandes --- build.gradle.kts | 2 +- renovate.json | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index 281f9c257..bb105ec93 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -70,7 +70,7 @@ subprojects { dependencies { // Tests - testImplementation("org.junit.jupiter:junit-jupiter:5.8.2") + testImplementation("org.junit.jupiter:junit-jupiter:5.9.0") } plugins.withId("java") { diff --git a/renovate.json b/renovate.json index 48ca5d129..dcd72876c 100644 --- a/renovate.json +++ b/renovate.json @@ -1,9 +1,7 @@ { "extends": [ - "config:base", - ":disableDependencyDashboard" + "config:base" ], "labels": ["Renovate"], - "commitMessagePrefix": "build: ", "rebaseWhen": "conflicted" } From 9609990832bc988bbc90edeaa0b1a0d4ff0e78e6 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 26 Jul 2022 22:47:51 +0200 Subject: [PATCH 028/111] build: Update dependency com.intellectualsites.bom:bom-1.18.x to v1.12 (#3739) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index bb105ec93..85f394030 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.11")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.12")) } dependencies { From aeb4350ccb2ba842e117dbdb320ecabe3a7adf05 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Fri, 29 Jul 2022 19:01:35 +0200 Subject: [PATCH 029/111] Update bug_report.yml --- .github/ISSUE_TEMPLATE/bug_report.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index ce357a5ab..5137c03c7 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -27,10 +27,10 @@ body: description: Which server version version you using? If your server version is not listed, it is not supported. Update to a supported version first. multiple: false options: + - '1.19.1' - '1.19' - '1.18.2' - '1.18.1' - - '1.18' - '1.17.1' - '1.16.5' validations: From 4e5a2b9f96407630416e5ead4d6f6735f6870b71 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Fri, 29 Jul 2022 23:00:37 +0200 Subject: [PATCH 030/111] fix: Add user friendly message for creationdate placeholder (#3745) --- .../plotsquared/core/util/placeholders/PlaceholderRegistry.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/util/placeholders/PlaceholderRegistry.java b/Core/src/main/java/com/plotsquared/core/util/placeholders/PlaceholderRegistry.java index 0f71356d8..291d10361 100644 --- a/Core/src/main/java/com/plotsquared/core/util/placeholders/PlaceholderRegistry.java +++ b/Core/src/main/java/com/plotsquared/core/util/placeholders/PlaceholderRegistry.java @@ -164,7 +164,7 @@ public final class PlaceholderRegistry { PlayerManager.getPlayerList(plot.getDenied(), player)); }); this.createPlaceholder("currentplot_creationdate", (player, plot) -> { - if (plot.getTimestamp() == 0) { + if (plot.getTimestamp() == 0 || !plot.hasOwner()) { return legacyComponent(TranslatableCaption.of("info.unknown"), player); } long creationDate = plot.getTimestamp(); From 3b747ffecf0c44dec509823e39d853ed5dfa064d Mon Sep 17 00:00:00 2001 From: Traks <58818927+traksag@users.noreply.github.com> Date: Fri, 29 Jul 2022 23:00:55 +0200 Subject: [PATCH 031/111] Don't allow wall corals to dry (#3746) --- .../com/plotsquared/bukkit/listener/BlockEventListener.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index 198710578..ffcc11abc 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -692,7 +692,7 @@ public class BlockEventListener implements Listener { } return; } - if (Tag.CORAL_BLOCKS.isTagged(blockType) || Tag.CORALS.isTagged(blockType)) { + if (Tag.CORAL_BLOCKS.isTagged(blockType) || Tag.CORALS.isTagged(blockType) || Tag.WALL_CORALS.isTagged(blockType)) { if (!plot.getFlag(CoralDryFlag.class)) { plot.debug("Coral could not dry because coral-dry = false"); event.setCancelled(true); From ee589ac7f05eeeae0dc55c5dd8041ba0d776e340 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sun, 31 Jul 2022 15:58:38 +0200 Subject: [PATCH 032/111] fix(deps): update worldedit to v7.2.11 (#3750) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index e39fa1505..f8ca974ab 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -5,7 +5,7 @@ guice = "5.1.0" spotbugs = "4.7.1" # Plugins -worldedit = "7.2.10" +worldedit = "7.2.11" placeholderapi = "2.11.2" luckperms = "5.4" essentialsx = "2.19.4" From d1021d19da7620b14db1b4ff7636e6790b7c565c Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sat, 6 Aug 2022 13:49:01 +0200 Subject: [PATCH 033/111] chore(deps): update dependency gradle to v7.5.1 (#3761) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/wrapper/gradle-wrapper.properties | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 8049c684f..ae04661ee 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-7.5-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists From 6f96daae5638afd498bced7b9dbdcb651d7a94ea Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sat, 6 Aug 2022 13:49:25 +0200 Subject: [PATCH 034/111] Update bug_report.yml --- .github/ISSUE_TEMPLATE/bug_report.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 5137c03c7..3067cc238 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -27,6 +27,7 @@ body: description: Which server version version you using? If your server version is not listed, it is not supported. Update to a supported version first. multiple: false options: + - '1.19.2' - '1.19.1' - '1.19' - '1.18.2' From 0bdeeea83bafb388cb3ae4bcb9c9cf4d0703c15b Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sun, 7 Aug 2022 21:16:18 +0200 Subject: [PATCH 035/111] fix(deps): update worldedit to v7.2.12 (#3762) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index f8ca974ab..a3ade912a 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -5,7 +5,7 @@ guice = "5.1.0" spotbugs = "4.7.1" # Plugins -worldedit = "7.2.11" +worldedit = "7.2.12" placeholderapi = "2.11.2" luckperms = "5.4" essentialsx = "2.19.4" From e0eff15694d8116102fbc323d3f2dc01d81ff9b7 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Sun, 7 Aug 2022 21:19:01 +0200 Subject: [PATCH 036/111] fix: use correct uuid type in `/grant` (#3759) use correct type --- .../main/java/com/plotsquared/core/command/Grant.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Grant.java b/Core/src/main/java/com/plotsquared/core/command/Grant.java index 4a96878b8..841098515 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Grant.java +++ b/Core/src/main/java/com/plotsquared/core/command/Grant.java @@ -32,7 +32,6 @@ import com.plotsquared.core.util.TabCompletions; import com.plotsquared.core.util.task.RunnableVal; import com.plotsquared.core.util.task.RunnableVal2; import com.plotsquared.core.util.task.RunnableVal3; -import com.plotsquared.core.uuid.UUIDMapping; import net.kyori.adventure.text.minimessage.Template; import java.util.Collection; @@ -40,6 +39,7 @@ import java.util.Collections; import java.util.LinkedList; import java.util.List; import java.util.Map; +import java.util.UUID; import java.util.concurrent.CompletableFuture; import java.util.concurrent.TimeoutException; import java.util.stream.Collectors; @@ -88,8 +88,8 @@ public class Grant extends Command { Template.of("value", String.valueOf(uuids)) ); } else { - final UUIDMapping uuid = uuids.toArray(new UUIDMapping[0])[0]; - PlotPlayer pp = PlotSquared.platform().playerManager().getPlayerIfExists(uuid.getUuid()); + final UUID uuid = uuids.iterator().next(); + PlotPlayer pp = PlotSquared.platform().playerManager().getPlayerIfExists(uuid); if (pp != null) { try (final MetaDataAccess access = pp.accessPersistentMetaData( PlayerMetaDataKeys.PERSISTENT_GRANTED_PLOTS)) { @@ -103,7 +103,7 @@ public class Grant extends Command { } } } else { - DBFunc.getPersistentMeta(uuid.getUuid(), new RunnableVal<>() { + DBFunc.getPersistentMeta(uuid, new RunnableVal<>() { @Override public void run(Map value) { final byte[] array = value.get("grantedPlots"); @@ -128,7 +128,7 @@ public class Grant extends Command { boolean replace = array != null; String key = "grantedPlots"; byte[] rawData = Ints.toByteArray(amount); - DBFunc.addPersistentMeta(uuid.getUuid(), key, rawData, replace); + DBFunc.addPersistentMeta(uuid, key, rawData, replace); player.sendMessage( TranslatableCaption.of("grants.added"), Template.of("grants", String.valueOf(amount)) From 3d19c5c2ad12ea9f8993efdfe10bfd1e96b624ec Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Mon, 8 Aug 2022 12:50:22 +0200 Subject: [PATCH 037/111] perf: avoid quadratic overhead for UUID collection (#3749) avoid quadratic overhead for UUID collection --- .../plotsquared/bukkit/BukkitPlatform.java | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java index d2da2fb2a..f249c1b5f 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java @@ -656,20 +656,15 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl final @NonNull SQLiteUUIDService sqLiteUUIDService, final @NonNull CacheUUIDService cacheUUIDService ) { - // Load all uuids into a big chunky boi queue - final Queue uuidQueue = new LinkedBlockingQueue<>(); + // Record all unique UUID's and put them into a queue + final Set uuidSet = new HashSet<>(); PlotSquared.get().forEachPlotRaw(plot -> { - final Set uuids = new HashSet<>(); - uuids.add(plot.getOwnerAbs()); - uuids.addAll(plot.getMembers()); - uuids.addAll(plot.getTrusted()); - uuids.addAll(plot.getDenied()); - for (final UUID uuid : uuids) { - if (!uuidQueue.contains(uuid)) { - uuidQueue.add(uuid); - } - } + uuidSet.add(plot.getOwnerAbs()); + uuidSet.addAll(plot.getMembers()); + uuidSet.addAll(plot.getTrusted()); + uuidSet.addAll(plot.getDenied()); }); + final Queue uuidQueue = new LinkedBlockingQueue<>(uuidSet); LOGGER.info("(UUID) {} UUIDs will be cached", uuidQueue.size()); From cba1927cc7ad7aba5068722389c8efbe7b680122 Mon Sep 17 00:00:00 2001 From: Pierre Maurice Schwang Date: Wed, 10 Aug 2022 10:22:19 +0200 Subject: [PATCH 038/111] Items no longer despawn on road when natural_mob_spawning = true and kill-road-items = false (#3764) * fix: handling of item despawning on road * chore: de-duplicate check * chore: check in PaperListener for consistency --- .../bukkit/listener/EntitySpawnListener.java | 12 ++++++------ .../plotsquared/bukkit/listener/PaperListener.java | 14 +++++++------- 2 files changed, 13 insertions(+), 13 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntitySpawnListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntitySpawnListener.java index 77d694379..841f52970 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntitySpawnListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntitySpawnListener.java @@ -126,16 +126,16 @@ public class EntitySpawnListener implements Listener { Plot plot = location.getOwnedPlotAbs(); EntityType type = entity.getType(); if (plot == null) { + if (type == EntityType.DROPPED_ITEM) { + if (Settings.Enabled_Components.KILL_ROAD_ITEMS) { + event.setCancelled(true); + } + return; + } if (!area.isMobSpawning()) { if (type == EntityType.PLAYER) { return; } - if (type == EntityType.DROPPED_ITEM) { - if (Settings.Enabled_Components.KILL_ROAD_ITEMS) { - event.setCancelled(true); - } - return; - } if (type.isAlive()) { event.setCancelled(true); } diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java index a2609fb23..9e3d9ba8e 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java @@ -229,17 +229,17 @@ public class PaperListener implements Listener { Plot plot = location.getOwnedPlotAbs(); if (plot == null) { EntityType type = event.getType(); + // PreCreatureSpawnEvent **should** not be called for DROPPED_ITEM, just for the sake of consistency + if (type == EntityType.DROPPED_ITEM) { + if (Settings.Enabled_Components.KILL_ROAD_ITEMS) { + event.setCancelled(true); + } + return; + } if (!area.isMobSpawning()) { if (type == EntityType.PLAYER) { return; } - if (type == EntityType.DROPPED_ITEM) { - if (Settings.Enabled_Components.KILL_ROAD_ITEMS) { - event.setShouldAbortSpawn(true); - event.setCancelled(true); - } - return; - } if (type.isAlive()) { event.setShouldAbortSpawn(true); event.setCancelled(true); From 77bce43acee2258089b2e7f20e58ae00c93b4711 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Wed, 10 Aug 2022 11:03:20 +0200 Subject: [PATCH 039/111] fix: replace usages of snow tag (#3758) * replace usages of snow tag * powder snow is 1.17+ --- .../bukkit/listener/BlockEventListener.java | 23 ++++++++++++++++--- 1 file changed, 20 insertions(+), 3 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index ffcc11abc..24749e8fd 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -121,6 +121,23 @@ public class BlockEventListener implements Listener { Material.TURTLE_EGG, Material.TURTLE_SPAWN_EGG ); + private static final Set SNOW; // needed as Tag.SNOW isn't present in 1.16.5 + + static { + if (PlotSquared.platform().serverVersion()[1] < 17) { + SNOW = Set.of( + Material.SNOW, + Material.SNOW_BLOCK + ); + } else { + SNOW = Set.of( + Material.SNOW, + Material.SNOW_BLOCK, + Material.POWDER_SNOW // only since 1.17 + ); + } + } + private final PlotAreaManager plotAreaManager; private final WorldEdit worldEdit; @@ -529,7 +546,7 @@ public class BlockEventListener implements Listener { event.setCancelled(true); return; } - if (Tag.SNOW.isTagged(event.getNewState().getType())) { + if (SNOW.contains(event.getNewState().getType())) { if (!plot.getFlag(SnowFormFlag.class)) { plot.debug("Snow could not form because snow-form = false"); event.setCancelled(true); @@ -561,7 +578,7 @@ public class BlockEventListener implements Listener { return; } Class> flag; - if (Tag.SNOW.isTagged(event.getNewState().getType())) { + if (SNOW.contains(event.getNewState().getType())) { flag = SnowFormFlag.class; } else if (Tag.ICE.isTagged(event.getNewState().getType())) { flag = IceFormFlag.class; @@ -678,7 +695,7 @@ public class BlockEventListener implements Listener { } return; } - if (Tag.SNOW.isTagged(blockType)) { + if (SNOW.contains(blockType)) { if (!plot.getFlag(SnowMeltFlag.class)) { plot.debug("Snow could not melt because snow-melt = false"); event.setCancelled(true); From b0a4e11c46c465cc2cb549100966d8a22d2dc13f Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 10 Aug 2022 11:09:51 +0200 Subject: [PATCH 040/111] build: Release 6.9.4 --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 85f394030..7a564dd1b 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.4-SNAPSHOT" +version = "6.9.4" subprojects { group = rootProject.group From 9fd96dbaa2eeb7e96849709f4f8865f5bfb72240 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 10 Aug 2022 11:10:41 +0200 Subject: [PATCH 041/111] build: Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 7a564dd1b..9aef07376 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.4" +version = "6.9.5-SNAPSHOT" subprojects { group = rootProject.group From 1ef424a2f1b8d08378355071c54cf61f98cfd473 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 10 Aug 2022 16:52:47 +0200 Subject: [PATCH 042/111] fix(deps): update dependency com.intellectualsites.bom:bom-1.18.x to v1.13 (#3766) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 9aef07376..d8ea8abc5 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.12")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.13")) } dependencies { From 9ff9097ff9a7c95fa28190e9a1efb3a6fd8aa8fc Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 12 Aug 2022 14:13:42 +0200 Subject: [PATCH 043/111] fix(deps): update dependency net.essentialsx:essentialsx to v2.19.5 (#3767) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index a3ade912a..1a59e88c2 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -8,7 +8,7 @@ spotbugs = "4.7.1" worldedit = "7.2.12" placeholderapi = "2.11.2" luckperms = "5.4" -essentialsx = "2.19.4" +essentialsx = "2.19.5" mvdwapi = "3.1.1" # Third party From 8d4333ad9d936d9f18daa69051a2ab3f54465d49 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sat, 13 Aug 2022 10:12:05 +0200 Subject: [PATCH 044/111] fix(deps): update dependency net.essentialsx:essentialsx to v2.19.6 (#3770) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 1a59e88c2..f778c26f6 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -8,7 +8,7 @@ spotbugs = "4.7.1" worldedit = "7.2.12" placeholderapi = "2.11.2" luckperms = "5.4" -essentialsx = "2.19.5" +essentialsx = "2.19.6" mvdwapi = "3.1.1" # Third party From 986812b9e4b7472fbb09f1e5e3f198d7c2bd2444 Mon Sep 17 00:00:00 2001 From: Pierre Maurice Schwang Date: Fri, 19 Aug 2022 13:41:04 +0200 Subject: [PATCH 045/111] chore: make snow set more future-proof (#3768) --- .../bukkit/listener/BlockEventListener.java | 22 +++++-------------- 1 file changed, 6 insertions(+), 16 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index 24749e8fd..7347b724d 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -109,6 +109,8 @@ import java.util.List; import java.util.Objects; import java.util.Set; import java.util.UUID; +import java.util.stream.Collectors; +import java.util.stream.Stream; @SuppressWarnings("unused") public class BlockEventListener implements Listener { @@ -121,22 +123,10 @@ public class BlockEventListener implements Listener { Material.TURTLE_EGG, Material.TURTLE_SPAWN_EGG ); - private static final Set SNOW; // needed as Tag.SNOW isn't present in 1.16.5 - - static { - if (PlotSquared.platform().serverVersion()[1] < 17) { - SNOW = Set.of( - Material.SNOW, - Material.SNOW_BLOCK - ); - } else { - SNOW = Set.of( - Material.SNOW, - Material.SNOW_BLOCK, - Material.POWDER_SNOW // only since 1.17 - ); - } - } + private static final Set SNOW = Stream.of(Material.values()) // needed as Tag.SNOW isn't present in 1.16.5 + .filter(material -> material.name().contains("SNOW")) + .filter(Material::isBlock) + .collect(Collectors.toUnmodifiableSet()); private final PlotAreaManager plotAreaManager; private final WorldEdit worldEdit; From 408b834376c002db20c3382ffd9b6001138adfb4 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sat, 20 Aug 2022 15:31:51 +0200 Subject: [PATCH 046/111] [ci skip] chore: Add renovate schema URL --- renovate.json | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/renovate.json b/renovate.json index dcd72876c..54da313f2 100644 --- a/renovate.json +++ b/renovate.json @@ -1,6 +1,8 @@ { + "$schema": "https://docs.renovatebot.com/renovate-schema.json", "extends": [ - "config:base" + "config:base", + ":semanticCommitsDisabled" ], "labels": ["Renovate"], "rebaseWhen": "conflicted" From fcc5bc5473dbbdc5ffc8712aaedd766fba23cc7f Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 24 Aug 2022 09:56:33 +0200 Subject: [PATCH 047/111] Update dependency net.essentialsx:EssentialsX to v2.19.7 (#3780) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index f778c26f6..f7479f814 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -8,7 +8,7 @@ spotbugs = "4.7.1" worldedit = "7.2.12" placeholderapi = "2.11.2" luckperms = "5.4" -essentialsx = "2.19.6" +essentialsx = "2.19.7" mvdwapi = "3.1.1" # Third party From 295b8a01357b570616e83bb9964cc911572d2f3c Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sat, 27 Aug 2022 09:32:40 +0200 Subject: [PATCH 048/111] Update dependency cloud.commandframework:cloud-services to v1.7.1 (#3784) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index f7479f814..298e90257 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -14,7 +14,7 @@ mvdwapi = "3.1.1" # Third party prtree = "2.0.0" aopalliance = "1.0" -cloud-services = "1.7.0" +cloud-services = "1.7.1" arkitektonika = "2.1.1" squirrelid = "0.3.1" http4j = "1.3" From 6df63f7fc782029c99e9f0c5ac27cef4516b2d91 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sat, 3 Sep 2022 12:55:55 +0200 Subject: [PATCH 049/111] Invoke -parameters on compile time (#3787) chore: Invoke -parameters on compile time --- build.gradle.kts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/build.gradle.kts b/build.gradle.kts index d8ea8abc5..d7b946442 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -174,10 +174,7 @@ subprojects { tasks { compileJava { - options.compilerArgs.addAll(arrayOf("-Xmaxerrs", "1000")) - options.compilerArgs.add("-Xlint:all") - for (disabledLint in arrayOf("processing", "path", "fallthrough", "serial")) - options.compilerArgs.add("-Xlint:$disabledLint") + options.compilerArgs.add("-parameters") options.isDeprecation = true options.encoding = "UTF-8" } From 69f5f88183c9c3d20110c1e00a665d6862e74add Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 5 Sep 2022 09:40:41 +0200 Subject: [PATCH 050/111] Update dependency com.github.spotbugs:spotbugs-annotations to v4.7.2 (#3793) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 298e90257..83a136062 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -2,7 +2,7 @@ # Platform expectations paper = "1.18.1-R0.1-SNAPSHOT" guice = "5.1.0" -spotbugs = "4.7.1" +spotbugs = "4.7.2" # Plugins worldedit = "7.2.12" From 476f3d328db4dd0e08183e50559aa6bde6147837 Mon Sep 17 00:00:00 2001 From: DerEingerostete <49292345+DerEingerostete@users.noreply.github.com> Date: Mon, 5 Sep 2022 20:06:37 +0200 Subject: [PATCH 051/111] feature: add flag for beacon effects of other plots (#3627) * feature: add flag for beacon effects of other plots Took 7 minutes * fix: don't add the beacon effect flag if the platform is not paper Took 2 minutes * fix: creating consistency in documentation Took 7 minutes * feature: add global paper setting for the beacon-effect * fix: description of the plot flag and rewrite of the listener * fix: renamed flag and added road support * fix: renamed flag and changed flag functionality * fix: added spigot fallback listener and fixed NPE * refactor: Address checkstyle violations * addition: remove beacon effects when player leaves a plot * fix: updated javadoc and fixed usage of the PlotListener#addEffect method * chore: Run license updater Co-authored-by: BuildTools Co-authored-by: Alexander Brandes --- .../plotsquared/bukkit/BukkitPlatform.java | 3 + .../bukkit/listener/PaperListener.java | 50 ++++++++++++++++ .../bukkit/listener/PlayerEventListener.java | 25 ++++++++ .../bukkit/listener/SpigotListener.java | 57 +++++++++++++++++++ .../bukkit/player/BukkitPlayer.java | 10 +++- .../core/configuration/Settings.java | 2 + .../core/listener/PlotListener.java | 52 +++++++++++++++++ .../core/player/ConsolePlayer.java | 4 ++ .../plotsquared/core/player/PlotPlayer.java | 8 +++ .../core/plot/flag/GlobalFlagContainer.java | 2 + .../implementations/BeaconEffectsFlag.java | 39 +++++++++++++ Core/src/main/resources/lang/messages_en.json | 1 + 12 files changed, 252 insertions(+), 1 deletion(-) create mode 100644 Bukkit/src/main/java/com/plotsquared/bukkit/listener/SpigotListener.java create mode 100644 Core/src/main/java/com/plotsquared/core/plot/flag/implementations/BeaconEffectsFlag.java diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java index f249c1b5f..b19130c1c 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java @@ -41,6 +41,7 @@ import com.plotsquared.bukkit.listener.PlayerEventListener; import com.plotsquared.bukkit.listener.ProjectileEventListener; import com.plotsquared.bukkit.listener.ServerListener; import com.plotsquared.bukkit.listener.SingleWorldListener; +import com.plotsquared.bukkit.listener.SpigotListener; import com.plotsquared.bukkit.listener.WorldEvents; import com.plotsquared.bukkit.placeholder.PAPIPlaceholders; import com.plotsquared.bukkit.placeholder.PlaceholderFormatter; @@ -360,6 +361,8 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl } else { getServer().getPluginManager().registerEvents(injector().getInstance(PaperListener.class), this); } + } else { + getServer().getPluginManager().registerEvents(injector().getInstance(SpigotListener.class), this); } this.plotListener.startRunnable(); } diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java index 9e3d9ba8e..54cc21a41 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java @@ -18,6 +18,7 @@ */ package com.plotsquared.bukkit.listener; +import com.destroystokyo.paper.event.block.BeaconEffectEvent; import com.destroystokyo.paper.event.entity.EntityPathfindEvent; import com.destroystokyo.paper.event.entity.PlayerNaturallySpawnCreaturesEvent; import com.destroystokyo.paper.event.entity.PreCreatureSpawnEvent; @@ -36,8 +37,11 @@ import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.PlotPlayer; import com.plotsquared.core.plot.Plot; import com.plotsquared.core.plot.PlotArea; +import com.plotsquared.core.plot.flag.FlagContainer; +import com.plotsquared.core.plot.flag.implementations.BeaconEffectsFlag; import com.plotsquared.core.plot.flag.implementations.DoneFlag; import com.plotsquared.core.plot.flag.implementations.ProjectilesFlag; +import com.plotsquared.core.plot.flag.types.BooleanFlag; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.util.Permissions; import net.kyori.adventure.text.minimessage.Template; @@ -400,4 +404,50 @@ public class PaperListener implements Listener { } } + @EventHandler(ignoreCancelled = true) + public void onBeaconEffect(final BeaconEffectEvent event) { + Block block = event.getBlock(); + Location beaconLocation = BukkitUtil.adapt(block.getLocation()); + Plot beaconPlot = beaconLocation.getPlot(); + + PlotArea area = beaconLocation.getPlotArea(); + if (area == null) { + return; + } + + Player player = event.getPlayer(); + Location playerLocation = BukkitUtil.adapt(player.getLocation()); + + PlotPlayer plotPlayer = BukkitUtil.adapt(player); + Plot playerStandingPlot = playerLocation.getPlot(); + if (playerStandingPlot == null) { + FlagContainer container = area.getRoadFlagContainer(); + if (!getBooleanFlagValue(container, BeaconEffectsFlag.class, true) || + (beaconPlot != null && Settings.Enabled_Components.DISABLE_BEACON_EFFECT_OVERFLOW)) { + event.setCancelled(true); + } + return; + } + + FlagContainer container = playerStandingPlot.getFlagContainer(); + boolean plotBeaconEffects = getBooleanFlagValue(container, BeaconEffectsFlag.class, true); + if (playerStandingPlot.equals(beaconPlot)) { + if (!plotBeaconEffects) { + event.setCancelled(true); + } + return; + } + + if (!plotBeaconEffects || Settings.Enabled_Components.DISABLE_BEACON_EFFECT_OVERFLOW) { + event.setCancelled(true); + } + } + + private boolean getBooleanFlagValue(@NonNull FlagContainer container, + @NonNull Class> flagClass, + boolean defaultValue) { + BooleanFlag flag = container.getFlag(flagClass); + return flag == null ? defaultValue : flag.getValue(); + } + } 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 6eddc83e1..1af53b6ad 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java @@ -106,6 +106,7 @@ import org.bukkit.event.Listener; import org.bukkit.event.block.Action; import org.bukkit.event.entity.EntityPickupItemEvent; import org.bukkit.event.entity.EntityPlaceEvent; +import org.bukkit.event.entity.EntityPotionEffectEvent; import org.bukkit.event.entity.PlayerDeathEvent; import org.bukkit.event.hanging.HangingBreakByEntityEvent; import org.bukkit.event.hanging.HangingPlaceEvent; @@ -142,6 +143,7 @@ import org.bukkit.inventory.meta.ItemMeta; import org.bukkit.metadata.FixedMetadataValue; import org.bukkit.metadata.MetadataValue; import org.bukkit.plugin.Plugin; +import org.bukkit.potion.PotionEffect; import org.bukkit.util.Vector; import org.checkerframework.checker.nullness.qual.NonNull; @@ -204,6 +206,29 @@ public class PlayerEventListener implements Listener { this.plotListener = plotListener; } + @EventHandler(ignoreCancelled = true) + public void onEffect(@NonNull EntityPotionEffectEvent event) { + if (Settings.Enabled_Components.DISABLE_BEACON_EFFECT_OVERFLOW || + event.getCause() != EntityPotionEffectEvent.Cause.BEACON || + !(event.getEntity() instanceof Player player)) { + return; + } + + UUID uuid = player.getUniqueId(); + PotionEffect effect = event.getNewEffect(); + if (effect == null) { + PotionEffect oldEffect = event.getOldEffect(); + if (oldEffect != null) { + String name = oldEffect.getType().getName(); + plotListener.addEffect(uuid, name, -1); + } + } else { + long expiresAt = System.currentTimeMillis() + effect.getDuration() * 50L; //Convert ticks to milliseconds + String name = effect.getType().getName(); + plotListener.addEffect(uuid, name, expiresAt); + } + } + @EventHandler public void onVehicleEntityCollision(VehicleEntityCollisionEvent e) { if (e.getVehicle().getType() == EntityType.BOAT) { diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/SpigotListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/SpigotListener.java new file mode 100644 index 000000000..5d91bc513 --- /dev/null +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/SpigotListener.java @@ -0,0 +1,57 @@ +/* + * PlotSquared, a land and world management plugin for Minecraft. + * Copyright (C) IntellectualSites + * Copyright (C) IntellectualSites team and contributors + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +package com.plotsquared.bukkit.listener; + +import com.plotsquared.bukkit.util.BukkitUtil; +import com.plotsquared.core.location.Location; +import com.plotsquared.core.plot.Plot; +import com.plotsquared.core.plot.flag.FlagContainer; +import com.plotsquared.core.plot.flag.implementations.BeaconEffectsFlag; +import org.bukkit.entity.Entity; +import org.bukkit.event.EventHandler; +import org.bukkit.event.Listener; +import org.bukkit.event.entity.EntityPotionEffectEvent; +import org.checkerframework.checker.nullness.qual.NonNull; + +/** + * Fallback listener for paper events on spigot + */ +public class SpigotListener implements Listener { + + @EventHandler(ignoreCancelled = true) + public void onEffect(@NonNull EntityPotionEffectEvent event) { + if (event.getCause() != EntityPotionEffectEvent.Cause.BEACON) { + return; + } + + Entity entity = event.getEntity(); + Location location = BukkitUtil.adapt(entity.getLocation()); + Plot plot = location.getPlot(); + if (plot == null) { + return; + } + + FlagContainer container = plot.getFlagContainer(); + BeaconEffectsFlag effectsEnabled = container.getFlag(BeaconEffectsFlag.class); + if (effectsEnabled != null && !effectsEnabled.getValue()) { + event.setCancelled(true); + } + } + +} diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/player/BukkitPlayer.java b/Bukkit/src/main/java/com/plotsquared/bukkit/player/BukkitPlayer.java index 6dcaa9dd7..1bcd3750f 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/player/BukkitPlayer.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/player/BukkitPlayer.java @@ -47,13 +47,13 @@ import org.bukkit.event.EventException; import org.bukkit.event.player.PlayerTeleportEvent; import org.bukkit.permissions.PermissionAttachmentInfo; import org.bukkit.plugin.RegisteredListener; +import org.bukkit.potion.PotionEffectType; import org.checkerframework.checker.index.qual.NonNegative; import org.checkerframework.checker.nullness.qual.NonNull; import java.util.Arrays; import java.util.Set; import java.util.UUID; -import java.util.stream.Collectors; import static com.sk89q.worldedit.world.gamemode.GameModes.ADVENTURE; import static com.sk89q.worldedit.world.gamemode.GameModes.CREATIVE; @@ -348,6 +348,14 @@ public class BukkitPlayer extends PlotPlayer { return BukkitUtil.BUKKIT_AUDIENCES.player(this.player); } + @Override + public void removeEffect(@NonNull String name) { + PotionEffectType type = PotionEffectType.getByName(name); + if (type != null) { + player.removePotionEffect(type); + } + } + @Override public boolean canSee(final PlotPlayer other) { if (other instanceof ConsolePlayer) { diff --git a/Core/src/main/java/com/plotsquared/core/configuration/Settings.java b/Core/src/main/java/com/plotsquared/core/configuration/Settings.java index 9276edca1..4e5ac9bc5 100644 --- a/Core/src/main/java/com/plotsquared/core/configuration/Settings.java +++ b/Core/src/main/java/com/plotsquared/core/configuration/Settings.java @@ -808,6 +808,8 @@ public class Settings extends Config { ); @Comment("Whether PlotSquared should hook into MvDWPlaceholderAPI or not") public static boolean USE_MVDWAPI = true; + @Comment("Prevent cross plot beacon effects") + public static boolean DISABLE_BEACON_EFFECT_OVERFLOW = true; } diff --git a/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java b/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java index a3a9f49e6..548e5f02e 100644 --- a/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java +++ b/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java @@ -67,10 +67,13 @@ import com.sk89q.worldedit.world.item.ItemType; import com.sk89q.worldedit.world.item.ItemTypes; import net.kyori.adventure.text.minimessage.MiniMessage; import net.kyori.adventure.text.minimessage.Template; +import org.checkerframework.checker.nullness.qual.NonNull; import org.checkerframework.checker.nullness.qual.Nullable; +import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; +import java.util.List; import java.util.Map; import java.util.Optional; import java.util.UUID; @@ -82,6 +85,7 @@ public class PlotListener { private final HashMap feedRunnable = new HashMap<>(); private final HashMap healRunnable = new HashMap<>(); + private final Map> playerEffects = new HashMap<>(); private final EventDispatcher eventDispatcher; @@ -131,6 +135,17 @@ public class PlotListener { } } } + + if (!playerEffects.isEmpty()) { + long currentTime = System.currentTimeMillis(); + for (Iterator>> iterator = + playerEffects.entrySet().iterator(); iterator.hasNext(); ) { + Map.Entry> entry = iterator.next(); + List effects = entry.getValue(); + effects.removeIf(effect -> currentTime > effect.expiresAt); + if (effects.isEmpty()) iterator.remove(); + } + } }, TaskTime.seconds(1L)); } @@ -360,6 +375,17 @@ public class PlotListener { try (final MetaDataAccess lastPlot = player.accessTemporaryMetaData(PlayerMetaDataKeys.TEMPORARY_LAST_PLOT)) { final Plot previous = lastPlot.remove(); this.eventDispatcher.callLeave(player, plot); + + List effects = playerEffects.remove(player.getUUID()); + if (effects != null) { + long currentTime = System.currentTimeMillis(); + effects.forEach(effect -> { + if (currentTime <= effect.expiresAt) { + player.removeEffect(effect.name); + } + }); + } + if (plot.hasOwner()) { PlotArea pw = plot.getArea(); if (pw == null) { @@ -468,6 +494,23 @@ public class PlotListener { public void logout(UUID uuid) { feedRunnable.remove(uuid); healRunnable.remove(uuid); + playerEffects.remove(uuid); + } + + /** + * Marks an effect as a status effect that will be removed on leaving a plot + * @param uuid The uuid of the player the effect belongs to + * @param name The name of the status effect + * @param expiresAt The time when the effect expires + * @since TODO + */ + public void addEffect(@NonNull UUID uuid, @NonNull String name, long expiresAt) { + List effects = playerEffects.getOrDefault(uuid, new ArrayList<>()); + effects.removeIf(effect -> effect.name.equals(name)); + if (expiresAt != -1) { + effects.add(new StatusEffect(name, expiresAt)); + } + playerEffects.put(uuid, effects); } private static class Interval { @@ -485,4 +528,13 @@ public class PlotListener { } + private record StatusEffect(@NonNull String name, long expiresAt) { + + private StatusEffect(@NonNull String name, long expiresAt) { + this.name = name; + this.expiresAt = expiresAt; + } + + } + } diff --git a/Core/src/main/java/com/plotsquared/core/player/ConsolePlayer.java b/Core/src/main/java/com/plotsquared/core/player/ConsolePlayer.java index fcf2bcfd2..dde0017cc 100644 --- a/Core/src/main/java/com/plotsquared/core/player/ConsolePlayer.java +++ b/Core/src/main/java/com/plotsquared/core/player/ConsolePlayer.java @@ -246,6 +246,10 @@ public class ConsolePlayer extends PlotPlayer { return PlotSquared.platform().consoleAudience(); } + @Override + public void removeEffect(@NonNull String name) { + } + @Override public boolean canSee(final PlotPlayer other) { return true; diff --git a/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java b/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java index 80d2fc769..4b2f90708 100644 --- a/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java +++ b/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java @@ -1016,6 +1016,14 @@ public abstract class PlotPlayer

implements CommandCaller, OfflinePlotPlayer, return this.lockRepository; } + /** + * Removes any effects present of the given type. + * + * @param name the name of the type to remove + * @since TODO + */ + public abstract void removeEffect(@NonNull String name); + @FunctionalInterface public interface PlotPlayerConverter { diff --git a/Core/src/main/java/com/plotsquared/core/plot/flag/GlobalFlagContainer.java b/Core/src/main/java/com/plotsquared/core/plot/flag/GlobalFlagContainer.java index 5a9d05d2a..734c31396 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/flag/GlobalFlagContainer.java +++ b/Core/src/main/java/com/plotsquared/core/plot/flag/GlobalFlagContainer.java @@ -23,6 +23,7 @@ import com.plotsquared.core.plot.flag.implementations.AnalysisFlag; import com.plotsquared.core.plot.flag.implementations.AnimalAttackFlag; import com.plotsquared.core.plot.flag.implementations.AnimalCapFlag; import com.plotsquared.core.plot.flag.implementations.AnimalInteractFlag; +import com.plotsquared.core.plot.flag.implementations.BeaconEffectsFlag; import com.plotsquared.core.plot.flag.implementations.BlockBurnFlag; import com.plotsquared.core.plot.flag.implementations.BlockIgnitionFlag; import com.plotsquared.core.plot.flag.implementations.BlockedCmdsFlag; @@ -137,6 +138,7 @@ public final class GlobalFlagContainer extends FlagContainer { this.addFlag(AnimalAttackFlag.ANIMAL_ATTACK_FALSE); this.addFlag(AnimalInteractFlag.ANIMAL_INTERACT_FALSE); this.addFlag(BlockBurnFlag.BLOCK_BURN_FALSE); + this.addFlag(BeaconEffectsFlag.BEACON_EFFECT_TRUE); this.addFlag(BlockIgnitionFlag.BLOCK_IGNITION_TRUE); this.addFlag(ChatFlag.CHAT_FLAG_TRUE); this.addFlag(CopperOxideFlag.COPPER_OXIDE_FALSE); diff --git a/Core/src/main/java/com/plotsquared/core/plot/flag/implementations/BeaconEffectsFlag.java b/Core/src/main/java/com/plotsquared/core/plot/flag/implementations/BeaconEffectsFlag.java new file mode 100644 index 000000000..6876f3965 --- /dev/null +++ b/Core/src/main/java/com/plotsquared/core/plot/flag/implementations/BeaconEffectsFlag.java @@ -0,0 +1,39 @@ +/* + * PlotSquared, a land and world management plugin for Minecraft. + * Copyright (C) IntellectualSites + * Copyright (C) IntellectualSites team and contributors + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +package com.plotsquared.core.plot.flag.implementations; + +import com.plotsquared.core.configuration.caption.TranslatableCaption; +import com.plotsquared.core.plot.flag.types.BooleanFlag; +import org.checkerframework.checker.nullness.qual.NonNull; + +public class BeaconEffectsFlag extends BooleanFlag { + + public static final BeaconEffectsFlag BEACON_EFFECT_TRUE = new BeaconEffectsFlag(true); + public static final BeaconEffectsFlag BEACON_EFFECT_FALSE = new BeaconEffectsFlag(false); + + private BeaconEffectsFlag(boolean value){ + super(value, TranslatableCaption.of("flags.flag_description_beacon_effect")); + } + + @Override + protected BeaconEffectsFlag flagOf(@NonNull final Boolean value) { + return value ? BEACON_EFFECT_TRUE : BEACON_EFFECT_FALSE; + } + +} diff --git a/Core/src/main/resources/lang/messages_en.json b/Core/src/main/resources/lang/messages_en.json index 397bb0933..a83554064 100644 --- a/Core/src/main/resources/lang/messages_en.json +++ b/Core/src/main/resources/lang/messages_en.json @@ -618,6 +618,7 @@ "flags.flag_description_prevent_creative_copy": "Prevents people from copying item NBT data in the plot unless they're added as members.", "flags.flag_description_leaf_decay": "Set to `false` to prevent leaves from decaying.", "flags.flag_description_projectiles": "Prevents guests from shooting projectiles on the plot when set to false.", + "flags.flag_description_beacon_effect": "Enables beacon effects on the plot.", "flags.flag_error_boolean": "Flag value must be a boolean (true | false).", "flags.flag_error_enum": "Must be one of: ", "flags.flag_error_integer": "Flag value must be a whole positive number.", From efc248dcdb385c9ed5195334948c01d3ca546568 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 12 Sep 2022 11:19:07 +0200 Subject: [PATCH 052/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.14 (#3794) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index d7b946442..f53e660de 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.13")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.14")) } dependencies { From 81a3f1098d17ff4c8ce1fbb25136ea8b3e781008 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 21 Sep 2022 16:18:08 +0200 Subject: [PATCH 053/111] Update dependency org.junit.jupiter:junit-jupiter to v5.9.1 (#3807) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index f53e660de..424729342 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -70,7 +70,7 @@ subprojects { dependencies { // Tests - testImplementation("org.junit.jupiter:junit-jupiter:5.9.0") + testImplementation("org.junit.jupiter:junit-jupiter:5.9.1") } plugins.withId("java") { From 9b0b071c0c97e2e014517544729906507bc86f36 Mon Sep 17 00:00:00 2001 From: resi23 Date: Wed, 21 Sep 2022 16:18:18 +0200 Subject: [PATCH 054/111] Add GLOW_BERRIES to VineGrowFlag (#3803) --- .../java/com/plotsquared/bukkit/listener/BlockEventListener.java | 1 + 1 file changed, 1 insertion(+) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index 7347b724d..a08097100 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -442,6 +442,7 @@ public class BlockEventListener implements Listener { case "TWISTING_VINES": case "CAVE_VINES": case "VINE": + case "GLOW_BERRIES": if (!plot.getFlag(VineGrowFlag.class)) { plot.debug("Vine could not grow because vine-grow = false"); event.setCancelled(true); From 8deeef4f7d742ab729732439be67cb2cf37f1465 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Wed, 21 Sep 2022 16:18:34 +0200 Subject: [PATCH 055/111] Add allay to animals (#3788) add allay to animals --- .../src/main/java/com/plotsquared/bukkit/util/BukkitUtil.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/util/BukkitUtil.java b/Bukkit/src/main/java/com/plotsquared/bukkit/util/BukkitUtil.java index 53123c895..fa174b6b5 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/util/BukkitUtil.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/util/BukkitUtil.java @@ -58,6 +58,7 @@ import org.bukkit.block.BlockFace; import org.bukkit.block.Sign; import org.bukkit.block.data.Directional; import org.bukkit.block.data.type.WallSign; +import org.bukkit.entity.Allay; import org.bukkit.entity.Ambient; import org.bukkit.entity.Animals; import org.bukkit.entity.AreaEffectCloud; @@ -437,6 +438,9 @@ public class BukkitUtil extends WorldUtil { allowedInterfaces.add(Animals.class); allowedInterfaces.add(WaterMob.class); allowedInterfaces.add(Ambient.class); + if (PlotSquared.platform().serverVersion()[1] >= 19) { + allowedInterfaces.add(Allay.class); + } } case "tameable" -> allowedInterfaces.add(Tameable.class); case "vehicle" -> allowedInterfaces.add(Vehicle.class); From 60d266b2d7880b3a4fabadf9e979b30d898a7511 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 21 Sep 2022 16:28:17 +0200 Subject: [PATCH 056/111] Release 6.10.0 --- .../main/java/com/plotsquared/core/listener/PlotListener.java | 2 +- Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java | 2 +- build.gradle.kts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java b/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java index 548e5f02e..6c837a2c6 100644 --- a/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java +++ b/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java @@ -502,7 +502,7 @@ public class PlotListener { * @param uuid The uuid of the player the effect belongs to * @param name The name of the status effect * @param expiresAt The time when the effect expires - * @since TODO + * @since 6.10.0 */ public void addEffect(@NonNull UUID uuid, @NonNull String name, long expiresAt) { List effects = playerEffects.getOrDefault(uuid, new ArrayList<>()); diff --git a/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java b/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java index 4b2f90708..3594f5727 100644 --- a/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java +++ b/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java @@ -1020,7 +1020,7 @@ public abstract class PlotPlayer

implements CommandCaller, OfflinePlotPlayer, * Removes any effects present of the given type. * * @param name the name of the type to remove - * @since TODO + * @since 6.10.0 */ public abstract void removeEffect(@NonNull String name); diff --git a/build.gradle.kts b/build.gradle.kts index 424729342..34edf31de 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.9.5-SNAPSHOT" +version = "6.10.0" subprojects { group = rootProject.group From 520bb64ecad8103db369ccc338a9a094288e5ffc Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 21 Sep 2022 16:29:17 +0200 Subject: [PATCH 057/111] Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 34edf31de..ced0c8bca 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.0" +version = "6.10.1-SNAPSHOT" subprojects { group = rootProject.group From 8b8fd6aab755cba3b79648ed0b880fe30de03c48 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 22 Sep 2022 22:26:11 +0200 Subject: [PATCH 058/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.15 (#3809) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index ced0c8bca..6c0fac814 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.14")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.15")) } dependencies { From 3446b913cd2d9aa7b8b6147162fb002f333a026b Mon Sep 17 00:00:00 2001 From: resi23 Date: Wed, 28 Sep 2022 10:53:44 +0200 Subject: [PATCH 059/111] plots.auto.mega fix for #3815 (#3816) Co-authored-by: Resi --- Core/src/main/java/com/plotsquared/core/command/Auto.java | 1 + 1 file changed, 1 insertion(+) diff --git a/Core/src/main/java/com/plotsquared/core/command/Auto.java b/Core/src/main/java/com/plotsquared/core/command/Auto.java index c59edbd64..60ed4bfea 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Auto.java +++ b/Core/src/main/java/com/plotsquared/core/command/Auto.java @@ -251,6 +251,7 @@ public class Auto extends SubCommand { TranslatableCaption.of("permission.no_permission"), Template.of("node", String.valueOf(Permission.PERMISSION_AUTO_MEGA)) ); + return false; } if (!force && sizeX * sizeZ > Settings.Claim.MAX_AUTO_AREA) { player.sendMessage( From d1a85982fb109f770ef3a041f6b5017358acbefc Mon Sep 17 00:00:00 2001 From: Schuwi Date: Sat, 1 Oct 2022 11:37:24 +0200 Subject: [PATCH 060/111] Fix "set block timer" error after "/plot download" with legacy-webinterface setting (#3812) Add missing `Plot.removeRunning` call to Download --- Core/src/main/java/com/plotsquared/core/command/Download.java | 1 + 1 file changed, 1 insertion(+) diff --git a/Core/src/main/java/com/plotsquared/core/command/Download.java b/Core/src/main/java/com/plotsquared/core/command/Download.java index 5b23919ff..15cf82851 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Download.java +++ b/Core/src/main/java/com/plotsquared/core/command/Download.java @@ -181,6 +181,7 @@ public class Download extends SubCommand { schematicHandler.upload(compoundTag, null, null, new RunnableVal<>() { @Override public void run(URL value) { + plot.removeRunning(); player.sendMessage( TranslatableCaption.of("web.generation_link_success"), Template.of("download", value.toString()), From 35abae99ca773358af6d03fbb9ad3e19e0d325e1 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Sun, 2 Oct 2022 22:22:08 +0200 Subject: [PATCH 061/111] Improve feedback for invalid patterns (#3818) improve feedback for invalid patterns --- .../core/generator/ClassicPlotWorld.java | 31 +++++++++++++++---- 1 file changed, 25 insertions(+), 6 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/ClassicPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/ClassicPlotWorld.java index 6b49b075c..190856e06 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/ClassicPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/ClassicPlotWorld.java @@ -28,13 +28,17 @@ import com.plotsquared.core.inject.annotations.WorldConfig; import com.plotsquared.core.plot.BlockBucket; import com.plotsquared.core.plot.PlotId; import com.plotsquared.core.queue.GlobalBlockQueue; +import com.sk89q.worldedit.function.pattern.Pattern; import com.sk89q.worldedit.world.block.BlockTypes; +import org.apache.logging.log4j.LogManager; +import org.apache.logging.log4j.Logger; import org.checkerframework.checker.nullness.qual.NonNull; import javax.annotation.Nullable; @SuppressWarnings("WeakerAccess") public abstract class ClassicPlotWorld extends SquarePlotWorld { + private static final Logger LOGGER = LogManager.getLogger("PlotSquared/" + ClassicPlotWorld.class.getSimpleName()); public int ROAD_HEIGHT = 62; public int PLOT_HEIGHT = 62; @@ -121,15 +125,15 @@ public abstract class ClassicPlotWorld extends SquarePlotWorld { super.loadConfiguration(config); this.PLOT_BEDROCK = config.getBoolean("plot.bedrock"); this.PLOT_HEIGHT = Math.min(getMaxGenHeight(), config.getInt("plot.height")); - this.MAIN_BLOCK = new BlockBucket(config.getString("plot.filling")); - this.TOP_BLOCK = new BlockBucket(config.getString("plot.floor")); - this.WALL_BLOCK = new BlockBucket(config.getString("wall.block")); + this.MAIN_BLOCK = createCheckedBlockBucket(config.getString("plot.filling"), MAIN_BLOCK); + this.TOP_BLOCK = createCheckedBlockBucket(config.getString("plot.floor"), TOP_BLOCK); + this.WALL_BLOCK = createCheckedBlockBucket(config.getString("wall.block"), WALL_BLOCK); this.ROAD_HEIGHT = Math.min(getMaxGenHeight(), config.getInt("road.height")); - this.ROAD_BLOCK = new BlockBucket(config.getString("road.block")); - this.WALL_FILLING = new BlockBucket(config.getString("wall.filling")); + this.ROAD_BLOCK = createCheckedBlockBucket(config.getString("road.block"), ROAD_BLOCK); + this.WALL_FILLING = createCheckedBlockBucket(config.getString("wall.filling"), WALL_FILLING); this.PLACE_TOP_BLOCK = config.getBoolean("wall.place_top_block"); this.WALL_HEIGHT = Math.min(getMaxGenHeight() - (PLACE_TOP_BLOCK ? 1 : 0), config.getInt("wall.height")); - this.CLAIMED_WALL_BLOCK = new BlockBucket(config.getString("wall.block_claimed")); + this.CLAIMED_WALL_BLOCK = createCheckedBlockBucket(config.getString("wall.block_claimed"), CLAIMED_WALL_BLOCK); } int schematicStartHeight() { @@ -140,4 +144,19 @@ public abstract class ClassicPlotWorld extends SquarePlotWorld { return Math.min(WALL_HEIGHT, plotRoadMin); } + private static BlockBucket createCheckedBlockBucket(String input, BlockBucket def) { + final BlockBucket bucket = new BlockBucket(input); + Pattern pattern = null; + try { + pattern = bucket.toPattern(); + } catch (Exception ignore) { + } + if (pattern == null) { + LOGGER.error("Failed to parse pattern '{}', check your worlds.yml", input); + LOGGER.error("Falling back to {}", def); + return def; + } + return bucket; + } + } From 1b717c9b10f5d6ba31b9b595a0b04c0debef09b8 Mon Sep 17 00:00:00 2001 From: Pierre Maurice Schwang Date: Mon, 3 Oct 2022 21:50:41 +0200 Subject: [PATCH 062/111] Only show visible players in `/plot near` (#3819) feat: check visibility of player in `/plot near` --- Core/src/main/java/com/plotsquared/core/command/Near.java | 7 ++++++- Core/src/main/java/com/plotsquared/core/plot/Plot.java | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Near.java b/Core/src/main/java/com/plotsquared/core/command/Near.java index 449be991b..840d54e7d 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Near.java +++ b/Core/src/main/java/com/plotsquared/core/command/Near.java @@ -26,6 +26,7 @@ import com.plotsquared.core.util.task.RunnableVal2; import com.plotsquared.core.util.task.RunnableVal3; import net.kyori.adventure.text.minimessage.Template; +import java.util.List; import java.util.concurrent.CompletableFuture; @CommandDeclaration(command = "near", @@ -48,9 +49,13 @@ public class Near extends Command { final Plot plot = check(player.getCurrentPlot(), TranslatableCaption.of("errors.not_in_plot")); player.sendMessage( TranslatableCaption.of("near.plot_near"), - Template.of("list", StringMan.join(plot.getPlayersInPlot(), ", ")) + Template.of("list", StringMan.join(getPlayersInPlotVisible(plot, player), ", ")) ); return CompletableFuture.completedFuture(true); } + private List> getPlayersInPlotVisible(Plot plot, PlotPlayer executor) { + return plot.getPlayersInPlot().stream().filter(executor::canSee).toList(); + } + } diff --git a/Core/src/main/java/com/plotsquared/core/plot/Plot.java b/Core/src/main/java/com/plotsquared/core/plot/Plot.java index 1f91da15a..fd3e68046 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/Plot.java +++ b/Core/src/main/java/com/plotsquared/core/plot/Plot.java @@ -457,7 +457,7 @@ public class Plot { * that could alter the de facto owner of the plot. * * @return The plot owner of this particular (sub-)plot - * as stored in the database, if one exists. Else, null. + * as stored in the database, if one exists. Else, null. */ public @Nullable UUID getOwnerAbs() { return this.owner; From 5786e8cc7a5657e06b34d7b4978a2df5033d715f Mon Sep 17 00:00:00 2001 From: StealWonders <6114858+StealWonders@users.noreply.github.com> Date: Mon, 3 Oct 2022 21:51:05 +0200 Subject: [PATCH 063/111] refactor: replace guava's Iterables with Java's stream API (#3823) --- .../bukkit/listener/ForceFieldListener.java | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ForceFieldListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ForceFieldListener.java index 32c0ce853..8c4b5b9b6 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ForceFieldListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ForceFieldListener.java @@ -18,7 +18,6 @@ */ package com.plotsquared.bukkit.listener; -import com.google.common.collect.Iterables; import com.plotsquared.bukkit.player.BukkitPlayer; import com.plotsquared.bukkit.util.BukkitUtil; import com.plotsquared.core.location.Location; @@ -39,8 +38,11 @@ public class ForceFieldListener { private static Set> getNearbyPlayers(Player player, Plot plot) { Set> players = new HashSet<>(); - for (Player nearPlayer : Iterables - .filter(player.getNearbyEntities(5d, 5d, 5d), Player.class)) { + for (Player nearPlayer : player.getNearbyEntities(5d, 5d, 5d).stream() + .filter(entity -> entity instanceof Player) + .map(entity -> (Player) entity) + .toList() + ) { PlotPlayer plotPlayer; if ((plotPlayer = BukkitUtil.adapt(nearPlayer)) == null || !plot .equals(plotPlayer.getCurrentPlot())) { @@ -54,8 +56,11 @@ public class ForceFieldListener { } private static PlotPlayer hasNearbyPermitted(Player player, Plot plot) { - for (Player nearPlayer : Iterables - .filter(player.getNearbyEntities(5d, 5d, 5d), Player.class)) { + for (Player nearPlayer : player.getNearbyEntities(5d, 5d, 5d).stream() + .filter(entity -> entity instanceof Player) + .map(entity -> (Player) entity) + .toList() + ) { PlotPlayer plotPlayer; if ((plotPlayer = BukkitUtil.adapt(nearPlayer)) == null || !plot .equals(plotPlayer.getCurrentPlot())) { From e53d2ac44928126a6157edf5f60a6c939c1fb395 Mon Sep 17 00:00:00 2001 From: StealWonders <6114858+StealWonders@users.noreply.github.com> Date: Mon, 3 Oct 2022 21:51:17 +0200 Subject: [PATCH 064/111] Update the plot sign when a plot has been purchased (#3822) --- Core/src/main/java/com/plotsquared/core/command/Buy.java | 1 + 1 file changed, 1 insertion(+) diff --git a/Core/src/main/java/com/plotsquared/core/command/Buy.java b/Core/src/main/java/com/plotsquared/core/command/Buy.java index 089bfb1bf..e8d585884 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Buy.java +++ b/Core/src/main/java/com/plotsquared/core/command/Buy.java @@ -126,6 +126,7 @@ public class Buy extends Command { plot.removeFlag(event.getFlag()); } plot.setOwner(player.getUUID()); + plot.getPlotModificationManager().setSign(player.getName()); player.sendMessage( TranslatableCaption.of("working.claimed"), Template.of("plot", plot.getId().toString()) From 316dd926679e3e5e9f9a8de20838dc5b9448acc7 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 4 Oct 2022 19:30:44 +0200 Subject: [PATCH 065/111] Release 6.10.1 --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 6c0fac814..45ed9d292 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.1-SNAPSHOT" +version = "6.10.1" subprojects { group = rootProject.group From 33c11fdee90ce7007c6153fead568fa337a3ef2d Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 4 Oct 2022 19:31:27 +0200 Subject: [PATCH 066/111] Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 45ed9d292..d3231d291 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.1" +version = "6.10.2-SNAPSHOT" subprojects { group = rootProject.group From 25e6aecf135937c809892eb10756e0deae24614a Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 4 Oct 2022 22:54:56 +0200 Subject: [PATCH 067/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.16 (#3825) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index d3231d291..fca26f9b1 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.15")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.16")) } dependencies { From d4c3ceaf2b6b510e29864bdc83af7fc54c970eca Mon Sep 17 00:00:00 2001 From: BlockyTheDev <86119630+BlockyTheDev@users.noreply.github.com> Date: Sat, 8 Oct 2022 15:10:57 +0200 Subject: [PATCH 068/111] Move license into jar during compile process (#3826) --- Core/build.gradle.kts | 7 + Core/src/main/resources/LICENSE | 674 -------------------------------- 2 files changed, 7 insertions(+), 674 deletions(-) delete mode 100644 Core/src/main/resources/LICENSE diff --git a/Core/build.gradle.kts b/Core/build.gradle.kts index d5103d1a6..aa7e541db 100644 --- a/Core/build.gradle.kts +++ b/Core/build.gradle.kts @@ -54,6 +54,13 @@ tasks.processResources { "date" to rootProject.grgit.head().dateTime.format(DateTimeFormatter.ofPattern("yy.MM.dd")) ) } + + doLast { + copy { + from(File("$rootDir/LICENSE")) + into("$buildDir/resources/main/") + } + } } tasks { diff --git a/Core/src/main/resources/LICENSE b/Core/src/main/resources/LICENSE deleted file mode 100644 index f288702d2..000000000 --- a/Core/src/main/resources/LICENSE +++ /dev/null @@ -1,674 +0,0 @@ - GNU GENERAL PUBLIC LICENSE - Version 3, 29 June 2007 - - Copyright (C) 2007 Free Software Foundation, Inc. - Everyone is permitted to copy and distribute verbatim copies - of this license document, but changing it is not allowed. - - Preamble - - The GNU General Public License is a free, copyleft license for -software and other kinds of works. - - The licenses for most software and other practical works are designed -to take away your freedom to share and change the works. By contrast, -the GNU General Public License is intended to guarantee your freedom to -share and change all versions of a program--to make sure it remains free -software for all its users. We, the Free Software Foundation, use the -GNU General Public License for most of our software; it applies also to -any other work released this way by its authors. You can apply it to -your programs, too. - - When we speak of free software, we are referring to freedom, not -price. Our General Public Licenses are designed to make sure that you -have the freedom to distribute copies of free software (and charge for -them if you wish), that you receive source code or can get it if you -want it, that you can change the software or use pieces of it in new -free programs, and that you know you can do these things. - - To protect your rights, we need to prevent others from denying you -these rights or asking you to surrender the rights. Therefore, you have -certain responsibilities if you distribute copies of the software, or if -you modify it: responsibilities to respect the freedom of others. - - For example, if you distribute copies of such a program, whether -gratis or for a fee, you must pass on to the recipients the same -freedoms that you received. You must make sure that they, too, receive -or can get the source code. And you must show them these terms so they -know their rights. - - Developers that use the GNU GPL protect your rights with two steps: -(1) assert copyright on the software, and (2) offer you this License -giving you legal permission to copy, distribute and/or modify it. - - For the developers' and authors' protection, the GPL clearly explains -that there is no warranty for this free software. For both users' and -authors' sake, the GPL requires that modified versions be marked as -changed, so that their problems will not be attributed erroneously to -authors of previous versions. - - Some devices are designed to deny users access to install or run -modified versions of the software inside them, although the manufacturer -can do so. This is fundamentally incompatible with the aim of -protecting users' freedom to change the software. The systematic -pattern of such abuse occurs in the area of products for individuals to -use, which is precisely where it is most unacceptable. Therefore, we -have designed this version of the GPL to prohibit the practice for those -products. If such problems arise substantially in other domains, we -stand ready to extend this provision to those domains in future versions -of the GPL, as needed to protect the freedom of users. - - Finally, every program is threatened constantly by software patents. -States should not allow patents to restrict development and use of -software on general-purpose computers, but in those that do, we wish to -avoid the special danger that patents applied to a free program could -make it effectively proprietary. To prevent this, the GPL assures that -patents cannot be used to render the program non-free. - - The precise terms and conditions for copying, distribution and -modification follow. - - TERMS AND CONDITIONS - - 0. Definitions. - - "This License" refers to version 3 of the GNU General Public License. - - "Copyright" also means copyright-like laws that apply to other kinds of -works, such as semiconductor masks. - - "The Program" refers to any copyrightable work licensed under this -License. Each licensee is addressed as "you". "Licensees" and -"recipients" may be individuals or organizations. - - To "modify" a work means to copy from or adapt all or part of the work -in a fashion requiring copyright permission, other than the making of an -exact copy. The resulting work is called a "modified version" of the -earlier work or a work "based on" the earlier work. - - A "covered work" means either the unmodified Program or a work based -on the Program. - - To "propagate" a work means to do anything with it that, without -permission, would make you directly or secondarily liable for -infringement under applicable copyright law, except executing it on a -computer or modifying a private copy. Propagation includes copying, -distribution (with or without modification), making available to the -public, and in some countries other activities as well. - - To "convey" a work means any kind of propagation that enables other -parties to make or receive copies. Mere interaction with a user through -a computer network, with no transfer of a copy, is not conveying. - - An interactive user interface displays "Appropriate Legal Notices" -to the extent that it includes a convenient and prominently visible -feature that (1) displays an appropriate copyright notice, and (2) -tells the user that there is no warranty for the work (except to the -extent that warranties are provided), that licensees may convey the -work under this License, and how to view a copy of this License. If -the interface presents a list of user commands or options, such as a -menu, a prominent item in the list meets this criterion. - - 1. Source Code. - - The "source code" for a work means the preferred form of the work -for making modifications to it. "Object code" means any non-source -form of a work. - - A "Standard Interface" means an interface that either is an official -standard defined by a recognized standards body, or, in the case of -interfaces specified for a particular programming language, one that -is widely used among developers working in that language. - - The "System Libraries" of an executable work include anything, other -than the work as a whole, that (a) is included in the normal form of -packaging a Major Component, but which is not part of that Major -Component, and (b) serves only to enable use of the work with that -Major Component, or to implement a Standard Interface for which an -implementation is available to the public in source code form. A -"Major Component", in this context, means a major essential component -(kernel, window system, and so on) of the specific operating system -(if any) on which the executable work runs, or a compiler used to -produce the work, or an object code interpreter used to run it. - - The "Corresponding Source" for a work in object code form means all -the source code needed to generate, install, and (for an executable -work) run the object code and to modify the work, including scripts to -control those activities. However, it does not include the work's -System Libraries, or general-purpose tools or generally available free -programs which are used unmodified in performing those activities but -which are not part of the work. For example, Corresponding Source -includes interface definition files associated with source files for -the work, and the source code for shared libraries and dynamically -linked subprograms that the work is specifically designed to require, -such as by intimate data communication or control flow between those -subprograms and other parts of the work. - - The Corresponding Source need not include anything that users -can regenerate automatically from other parts of the Corresponding -Source. - - The Corresponding Source for a work in source code form is that -same work. - - 2. Basic Permissions. - - All rights granted under this License are granted for the term of -copyright on the Program, and are irrevocable provided the stated -conditions are met. This License explicitly affirms your unlimited -permission to run the unmodified Program. The output from running a -covered work is covered by this License only if the output, given its -content, constitutes a covered work. This License acknowledges your -rights of fair use or other equivalent, as provided by copyright law. - - You may make, run and propagate covered works that you do not -convey, without conditions so long as your license otherwise remains -in force. You may convey covered works to others for the sole purpose -of having them make modifications exclusively for you, or provide you -with facilities for running those works, provided that you comply with -the terms of this License in conveying all material for which you do -not control copyright. Those thus making or running the covered works -for you must do so exclusively on your behalf, under your direction -and control, on terms that prohibit them from making any copies of -your copyrighted material outside their relationship with you. - - Conveying under any other circumstances is permitted solely under -the conditions stated below. Sublicensing is not allowed; section 10 -makes it unnecessary. - - 3. Protecting Users' Legal Rights From Anti-Circumvention Law. - - No covered work shall be deemed part of an effective technological -measure under any applicable law fulfilling obligations under article -11 of the WIPO copyright treaty adopted on 20 December 1996, or -similar laws prohibiting or restricting circumvention of such -measures. - - When you convey a covered work, you waive any legal power to forbid -circumvention of technological measures to the extent such circumvention -is effected by exercising rights under this License with respect to -the covered work, and you disclaim any intention to limit operation or -modification of the work as a means of enforcing, against the work's -users, your or third parties' legal rights to forbid circumvention of -technological measures. - - 4. Conveying Verbatim Copies. - - You may convey verbatim copies of the Program's source code as you -receive it, in any medium, provided that you conspicuously and -appropriately publish on each copy an appropriate copyright notice; -keep intact all notices stating that this License and any -non-permissive terms added in accord with section 7 apply to the code; -keep intact all notices of the absence of any warranty; and give all -recipients a copy of this License along with the Program. - - You may charge any price or no price for each copy that you convey, -and you may offer support or warranty protection for a fee. - - 5. Conveying Modified Source Versions. - - You may convey a work based on the Program, or the modifications to -produce it from the Program, in the form of source code under the -terms of section 4, provided that you also meet all of these conditions: - - a) The work must carry prominent notices stating that you modified - it, and giving a relevant date. - - b) The work must carry prominent notices stating that it is - released under this License and any conditions added under section - 7. This requirement modifies the requirement in section 4 to - "keep intact all notices". - - c) You must license the entire work, as a whole, under this - License to anyone who comes into possession of a copy. This - License will therefore apply, along with any applicable section 7 - additional terms, to the whole of the work, and all its parts, - regardless of how they are packaged. This License gives no - permission to license the work in any other way, but it does not - invalidate such permission if you have separately received it. - - d) If the work has interactive user interfaces, each must display - Appropriate Legal Notices; however, if the Program has interactive - interfaces that do not display Appropriate Legal Notices, your - work need not make them do so. - - A compilation of a covered work with other separate and independent -works, which are not by their nature extensions of the covered work, -and which are not combined with it such as to form a larger program, -in or on a volume of a storage or distribution medium, is called an -"aggregate" if the compilation and its resulting copyright are not -used to limit the access or legal rights of the compilation's users -beyond what the individual works permit. Inclusion of a covered work -in an aggregate does not cause this License to apply to the other -parts of the aggregate. - - 6. Conveying Non-Source Forms. - - You may convey a covered work in object code form under the terms -of sections 4 and 5, provided that you also convey the -machine-readable Corresponding Source under the terms of this License, -in one of these ways: - - a) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by the - Corresponding Source fixed on a durable physical medium - customarily used for software interchange. - - b) Convey the object code in, or embodied in, a physical product - (including a physical distribution medium), accompanied by a - written offer, valid for at least three years and valid for as - long as you offer spare parts or customer support for that product - model, to give anyone who possesses the object code either (1) a - copy of the Corresponding Source for all the software in the - product that is covered by this License, on a durable physical - medium customarily used for software interchange, for a price no - more than your reasonable cost of physically performing this - conveying of source, or (2) access to copy the - Corresponding Source from a network server at no charge. - - c) Convey individual copies of the object code with a copy of the - written offer to provide the Corresponding Source. This - alternative is allowed only occasionally and noncommercially, and - only if you received the object code with such an offer, in accord - with subsection 6b. - - d) Convey the object code by offering access from a designated - place (gratis or for a charge), and offer equivalent access to the - Corresponding Source in the same way through the same place at no - further charge. You need not require recipients to copy the - Corresponding Source along with the object code. If the place to - copy the object code is a network server, the Corresponding Source - may be on a different server (operated by you or a third party) - that supports equivalent copying facilities, provided you maintain - clear directions next to the object code saying where to find the - Corresponding Source. Regardless of what server hosts the - Corresponding Source, you remain obligated to ensure that it is - available for as long as needed to satisfy these requirements. - - e) Convey the object code using peer-to-peer transmission, provided - you inform other peers where the object code and Corresponding - Source of the work are being offered to the general public at no - charge under subsection 6d. - - A separable portion of the object code, whose source code is excluded -from the Corresponding Source as a System Library, need not be -included in conveying the object code work. - - A "User Product" is either (1) a "consumer product", which means any -tangible personal property which is normally used for personal, family, -or household purposes, or (2) anything designed or sold for incorporation -into a dwelling. In determining whether a product is a consumer product, -doubtful cases shall be resolved in favor of coverage. For a particular -product received by a particular user, "normally used" refers to a -typical or common use of that class of product, regardless of the status -of the particular user or of the way in which the particular user -actually uses, or expects or is expected to use, the product. A product -is a consumer product regardless of whether the product has substantial -commercial, industrial or non-consumer uses, unless such uses represent -the only significant mode of use of the product. - - "Installation Information" for a User Product means any methods, -procedures, authorization keys, or other information required to install -and execute modified versions of a covered work in that User Product from -a modified version of its Corresponding Source. The information must -suffice to ensure that the continued functioning of the modified object -code is in no case prevented or interfered with solely because -modification has been made. - - If you convey an object code work under this section in, or with, or -specifically for use in, a User Product, and the conveying occurs as -part of a transaction in which the right of possession and use of the -User Product is transferred to the recipient in perpetuity or for a -fixed term (regardless of how the transaction is characterized), the -Corresponding Source conveyed under this section must be accompanied -by the Installation Information. But this requirement does not apply -if neither you nor any third party retains the ability to install -modified object code on the User Product (for example, the work has -been installed in ROM). - - The requirement to provide Installation Information does not include a -requirement to continue to provide support service, warranty, or updates -for a work that has been modified or installed by the recipient, or for -the User Product in which it has been modified or installed. Access to a -network may be denied when the modification itself materially and -adversely affects the operation of the network or violates the rules and -protocols for communication across the network. - - Corresponding Source conveyed, and Installation Information provided, -in accord with this section must be in a format that is publicly -documented (and with an implementation available to the public in -source code form), and must require no special password or key for -unpacking, reading or copying. - - 7. Additional Terms. - - "Additional permissions" are terms that supplement the terms of this -License by making exceptions from one or more of its conditions. -Additional permissions that are applicable to the entire Program shall -be treated as though they were included in this License, to the extent -that they are valid under applicable law. If additional permissions -apply only to part of the Program, that part may be used separately -under those permissions, but the entire Program remains governed by -this License without regard to the additional permissions. - - When you convey a copy of a covered work, you may at your option -remove any additional permissions from that copy, or from any part of -it. (Additional permissions may be written to require their own -removal in certain cases when you modify the work.) You may place -additional permissions on material, added by you to a covered work, -for which you have or can give appropriate copyright permission. - - Notwithstanding any other provision of this License, for material you -add to a covered work, you may (if authorized by the copyright holders of -that material) supplement the terms of this License with terms: - - a) Disclaiming warranty or limiting liability differently from the - terms of sections 15 and 16 of this License; or - - b) Requiring preservation of specified reasonable legal notices or - author attributions in that material or in the Appropriate Legal - Notices displayed by works containing it; or - - c) Prohibiting misrepresentation of the origin of that material, or - requiring that modified versions of such material be marked in - reasonable ways as different from the original version; or - - d) Limiting the use for publicity purposes of names of licensors or - authors of the material; or - - e) Declining to grant rights under trademark law for use of some - trade names, trademarks, or service marks; or - - f) Requiring indemnification of licensors and authors of that - material by anyone who conveys the material (or modified versions of - it) with contractual assumptions of liability to the recipient, for - any liability that these contractual assumptions directly impose on - those licensors and authors. - - All other non-permissive additional terms are considered "further -restrictions" within the meaning of section 10. If the Program as you -received it, or any part of it, contains a notice stating that it is -governed by this License along with a term that is a further -restriction, you may remove that term. If a license document contains -a further restriction but permits relicensing or conveying under this -License, you may add to a covered work material governed by the terms -of that license document, provided that the further restriction does -not survive such relicensing or conveying. - - If you add terms to a covered work in accord with this section, you -must place, in the relevant source files, a statement of the -additional terms that apply to those files, or a notice indicating -where to find the applicable terms. - - Additional terms, permissive or non-permissive, may be stated in the -form of a separately written license, or stated as exceptions; -the above requirements apply either way. - - 8. Termination. - - You may not propagate or modify a covered work except as expressly -provided under this License. Any attempt otherwise to propagate or -modify it is void, and will automatically terminate your rights under -this License (including any patent licenses granted under the third -paragraph of section 11). - - However, if you cease all violation of this License, then your -license from a particular copyright holder is reinstated (a) -provisionally, unless and until the copyright holder explicitly and -finally terminates your license, and (b) permanently, if the copyright -holder fails to notify you of the violation by some reasonable means -prior to 60 days after the cessation. - - Moreover, your license from a particular copyright holder is -reinstated permanently if the copyright holder notifies you of the -violation by some reasonable means, this is the first time you have -received notice of violation of this License (for any work) from that -copyright holder, and you cure the violation prior to 30 days after -your receipt of the notice. - - Termination of your rights under this section does not terminate the -licenses of parties who have received copies or rights from you under -this License. If your rights have been terminated and not permanently -reinstated, you do not qualify to receive new licenses for the same -material under section 10. - - 9. Acceptance Not Required for Having Copies. - - You are not required to accept this License in order to receive or -run a copy of the Program. Ancillary propagation of a covered work -occurring solely as a consequence of using peer-to-peer transmission -to receive a copy likewise does not require acceptance. However, -nothing other than this License grants you permission to propagate or -modify any covered work. These actions infringe copyright if you do -not accept this License. Therefore, by modifying or propagating a -covered work, you indicate your acceptance of this License to do so. - - 10. Automatic Licensing of Downstream Recipients. - - Each time you convey a covered work, the recipient automatically -receives a license from the original licensors, to run, modify and -propagate that work, subject to this License. You are not responsible -for enforcing compliance by third parties with this License. - - An "entity transaction" is a transaction transferring control of an -organization, or substantially all assets of one, or subdividing an -organization, or merging organizations. If propagation of a covered -work results from an entity transaction, each party to that -transaction who receives a copy of the work also receives whatever -licenses to the work the party's predecessor in interest had or could -give under the previous paragraph, plus a right to possession of the -Corresponding Source of the work from the predecessor in interest, if -the predecessor has it or can get it with reasonable efforts. - - You may not impose any further restrictions on the exercise of the -rights granted or affirmed under this License. For example, you may -not impose a license fee, royalty, or other charge for exercise of -rights granted under this License, and you may not initiate litigation -(including a cross-claim or counterclaim in a lawsuit) alleging that -any patent claim is infringed by making, using, selling, offering for -sale, or importing the Program or any portion of it. - - 11. Patents. - - A "contributor" is a copyright holder who authorizes use under this -License of the Program or a work on which the Program is based. The -work thus licensed is called the contributor's "contributor version". - - A contributor's "essential patent claims" are all patent claims -owned or controlled by the contributor, whether already acquired or -hereafter acquired, that would be infringed by some manner, permitted -by this License, of making, using, or selling its contributor version, -but do not include claims that would be infringed only as a -consequence of further modification of the contributor version. For -purposes of this definition, "control" includes the right to grant -patent sublicenses in a manner consistent with the requirements of -this License. - - Each contributor grants you a non-exclusive, worldwide, royalty-free -patent license under the contributor's essential patent claims, to -make, use, sell, offer for sale, import and otherwise run, modify and -propagate the contents of its contributor version. - - In the following three paragraphs, a "patent license" is any express -agreement or commitment, however denominated, not to enforce a patent -(such as an express permission to practice a patent or covenant not to -sue for patent infringement). To "grant" such a patent license to a -party means to make such an agreement or commitment not to enforce a -patent against the party. - - If you convey a covered work, knowingly relying on a patent license, -and the Corresponding Source of the work is not available for anyone -to copy, free of charge and under the terms of this License, through a -publicly available network server or other readily accessible means, -then you must either (1) cause the Corresponding Source to be so -available, or (2) arrange to deprive yourself of the benefit of the -patent license for this particular work, or (3) arrange, in a manner -consistent with the requirements of this License, to extend the patent -license to downstream recipients. "Knowingly relying" means you have -actual knowledge that, but for the patent license, your conveying the -covered work in a country, or your recipient's use of the covered work -in a country, would infringe one or more identifiable patents in that -country that you have reason to believe are valid. - - If, pursuant to or in connection with a single transaction or -arrangement, you convey, or propagate by procuring conveyance of, a -covered work, and grant a patent license to some of the parties -receiving the covered work authorizing them to use, propagate, modify -or convey a specific copy of the covered work, then the patent license -you grant is automatically extended to all recipients of the covered -work and works based on it. - - A patent license is "discriminatory" if it does not include within -the scope of its coverage, prohibits the exercise of, or is -conditioned on the non-exercise of one or more of the rights that are -specifically granted under this License. You may not convey a covered -work if you are a party to an arrangement with a third party that is -in the business of distributing software, under which you make payment -to the third party based on the extent of your activity of conveying -the work, and under which the third party grants, to any of the -parties who would receive the covered work from you, a discriminatory -patent license (a) in connection with copies of the covered work -conveyed by you (or copies made from those copies), or (b) primarily -for and in connection with specific products or compilations that -contain the covered work, unless you entered into that arrangement, -or that patent license was granted, prior to 28 March 2007. - - Nothing in this License shall be construed as excluding or limiting -any implied license or other defenses to infringement that may -otherwise be available to you under applicable patent law. - - 12. No Surrender of Others' Freedom. - - If conditions are imposed on you (whether by court order, agreement or -otherwise) that contradict the conditions of this License, they do not -excuse you from the conditions of this License. If you cannot convey a -covered work so as to satisfy simultaneously your obligations under this -License and any other pertinent obligations, then as a consequence you may -not convey it at all. For example, if you agree to terms that obligate you -to collect a royalty for further conveying from those to whom you convey -the Program, the only way you could satisfy both those terms and this -License would be to refrain entirely from conveying the Program. - - 13. Use with the GNU Affero General Public License. - - Notwithstanding any other provision of this License, you have -permission to link or combine any covered work with a work licensed -under version 3 of the GNU Affero General Public License into a single -combined work, and to convey the resulting work. The terms of this -License will continue to apply to the part which is the covered work, -but the special requirements of the GNU Affero General Public License, -section 13, concerning interaction through a network will apply to the -combination as such. - - 14. Revised Versions of this License. - - The Free Software Foundation may publish revised and/or new versions of -the GNU General Public License from time to time. Such new versions will -be similar in spirit to the present version, but may differ in detail to -address new problems or concerns. - - Each version is given a distinguishing version number. If the -Program specifies that a certain numbered version of the GNU General -Public License "or any later version" applies to it, you have the -option of following the terms and conditions either of that numbered -version or of any later version published by the Free Software -Foundation. If the Program does not specify a version number of the -GNU General Public License, you may choose any version ever published -by the Free Software Foundation. - - If the Program specifies that a proxy can decide which future -versions of the GNU General Public License can be used, that proxy's -public statement of acceptance of a version permanently authorizes you -to choose that version for the Program. - - Later license versions may give you additional or different -permissions. However, no additional obligations are imposed on any -author or copyright holder as a result of your choosing to follow a -later version. - - 15. Disclaimer of Warranty. - - THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY -APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT -HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY -OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, -THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR -PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM -IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF -ALL NECESSARY SERVICING, REPAIR OR CORRECTION. - - 16. Limitation of Liability. - - IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING -WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS -THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY -GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE -USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF -DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD -PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), -EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF -SUCH DAMAGES. - - 17. Interpretation of Sections 15 and 16. - - If the disclaimer of warranty and limitation of liability provided -above cannot be given local legal effect according to their terms, -reviewing courts shall apply local law that most closely approximates -an absolute waiver of all civil liability in connection with the -Program, unless a warranty or assumption of liability accompanies a -copy of the Program in return for a fee. - - END OF TERMS AND CONDITIONS - - How to Apply These Terms to Your New Programs - - If you develop a new program, and you want it to be of the greatest -possible use to the public, the best way to achieve this is to make it -free software which everyone can redistribute and change under these terms. - - To do so, attach the following notices to the program. It is safest -to attach them to the start of each source file to most effectively -state the exclusion of warranty; and each file should have at least -the "copyright" line and a pointer to where the full notice is found. - - - Copyright (C) - - This program is free software: you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation, either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see . - -Also add information on how to contact you by electronic and paper mail. - - If the program does terminal interaction, make it output a short -notice like this when it starts in an interactive mode: - - Copyright (C) - This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. - This is free software, and you are welcome to redistribute it - under certain conditions; type `show c' for details. - -The hypothetical commands `show w' and `show c' should show the appropriate -parts of the General Public License. Of course, your program's commands -might be different; for a GUI interface, you would use an "about box". - - You should also get your employer (if you work as a programmer) or school, -if any, to sign a "copyright disclaimer" for the program, if necessary. -For more information on this, and how to apply and follow the GNU GPL, see -. - - The GNU General Public License does not permit incorporating your program -into proprietary programs. If your program is a subroutine library, you -may consider it more useful to permit linking proprietary applications with -the library. If this is what you want to do, use the GNU Lesser General -Public License instead of this License. But first, please read -. From caef3a923b091f2c744f9161c9a9d0eb4fde1d9e Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Sat, 8 Oct 2022 15:11:16 +0200 Subject: [PATCH 069/111] Deprecate PlotId#copy (#3821) --- .../java/com/plotsquared/core/command/DatabaseCommand.java | 2 +- Core/src/main/java/com/plotsquared/core/plot/Plot.java | 6 +++--- Core/src/main/java/com/plotsquared/core/plot/PlotId.java | 4 +++- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/DatabaseCommand.java b/Core/src/main/java/com/plotsquared/core/command/DatabaseCommand.java index 73b678e5b..76c1c8dc5 100644 --- a/Core/src/main/java/com/plotsquared/core/command/DatabaseCommand.java +++ b/Core/src/main/java/com/plotsquared/core/command/DatabaseCommand.java @@ -176,7 +176,7 @@ public class DatabaseCommand extends SubCommand { ); worldFile.renameTo(newFile); } - plot.setId(newId.copy()); + plot.setId(newId); plot.setArea(pa); plots.add(plot); continue; diff --git a/Core/src/main/java/com/plotsquared/core/plot/Plot.java b/Core/src/main/java/com/plotsquared/core/plot/Plot.java index fd3e68046..757f89012 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/Plot.java +++ b/Core/src/main/java/com/plotsquared/core/plot/Plot.java @@ -1836,8 +1836,8 @@ public class Plot { } // Swap cached final PlotId temp = PlotId.of(this.getId().getX(), this.getId().getY()); - this.id = plot.getId().copy(); - plot.id = temp.copy(); + this.id = plot.getId(); + plot.id = temp; this.area.removePlot(this.getId()); plot.area.removePlot(plot.getId()); this.area.addPlotAbs(this); @@ -1863,7 +1863,7 @@ public class Plot { return false; } this.area.removePlot(this.id); - this.id = plot.getId().copy(); + this.id = plot.getId(); this.area.addPlotAbs(this); DBFunc.movePlot(this, plot); TaskManager.runTaskLater(whenDone, TaskTime.ticks(1L)); diff --git a/Core/src/main/java/com/plotsquared/core/plot/PlotId.java b/Core/src/main/java/com/plotsquared/core/plot/PlotId.java index 552831c1f..4d0bb8fb7 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/PlotId.java +++ b/Core/src/main/java/com/plotsquared/core/plot/PlotId.java @@ -110,9 +110,11 @@ public final class PlotId { * Get a copy of the plot ID * * @return Plot ID copy + * @deprecated PlotId is immutable, copy is not required. */ + @Deprecated(forRemoval = true, since = "TODO") public @NonNull PlotId copy() { - return of(this.getX(), this.getY()); + return this; } /** From 49b19e0eaff2a1ed4c9a92a7b80e1861279ddc9d Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Sat, 8 Oct 2022 15:13:11 +0200 Subject: [PATCH 070/111] Check proper locations on PortalCreateEvent (#3834) check proper locations on PortalCreateEvent --- .../plotsquared/bukkit/listener/PlayerEventListener.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) 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 1af53b6ad..ca7130deb 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java @@ -1756,11 +1756,11 @@ public class PlayerEventListener implements Listener { maxZ = Math.max(state.getZ(), maxZ); } int y = event.getBlocks().get(0).getY(); // Don't need to worry about this too much - for (Location location : Set.of( // Use Set to lazily avoid duplicate locations - Location.at(world, minX, y, maxX), - Location.at(world, minZ, y, maxZ), + for (Location location : List.of( // We don't care about duplicate locations + Location.at(world, minX, y, minZ), Location.at(world, minX, y, maxZ), - Location.at(world, minZ, y, maxX) + Location.at(world, maxX, y, minZ), + Location.at(world, maxX, y, maxZ) )) { PlotArea area = location.getPlotArea(); if (area == null) { From 3effaefda703177d4089164ea91b76f9b4d4b048 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sun, 9 Oct 2022 16:40:51 +0200 Subject: [PATCH 071/111] chore: Announce releases on Discord (#3839) --- .../workflows/announce-release-on-discord.yml | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/announce-release-on-discord.yml diff --git a/.github/workflows/announce-release-on-discord.yml b/.github/workflows/announce-release-on-discord.yml new file mode 100644 index 000000000..4e0eeef84 --- /dev/null +++ b/.github/workflows/announce-release-on-discord.yml @@ -0,0 +1,25 @@ +name: Announce release on discord +on: + release: + types: [published] + +jobs: + send_announcement: + runs-on: ubuntu-latest + steps: + - name: send custom message with args + env: + DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }} + DISCORD_USERNAME: PlotSquared Release + DISCORD_AVATAR: https://raw.githubusercontent.com/IntellectualSites/Assets/main/plugins/PlotSquared/PlotSquared.png + uses: Ilshidur/action-discord@0.3.2 + with: + args: | + "<@&525015541815967744> <@&679322738552471574> <@&699293353862496266>" + "" + "<:plotsquared:730750385886593039> **PlotSquared ${{ github.event.release.tag_name }} has been released!**" + "" + "Click here to view changelog: https://github.com/IntellectualSites/PlotSquared/releases/tag/${{ github.event.release.tag_name }}" + "" + "The download is available at:" + "- Spigot: " From d5445cfbef50fa505ef3748c113058333d2271f0 Mon Sep 17 00:00:00 2001 From: BlockyTheDev <86119630+BlockyTheDev@users.noreply.github.com> Date: Mon, 10 Oct 2022 18:41:25 +0200 Subject: [PATCH 072/111] Don't kill owned road entities (leashed / named) (#3829) --- .../java/com/plotsquared/bukkit/BukkitPlatform.java | 13 ++++++++----- .../plotsquared/core/configuration/Settings.java | 2 ++ 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java index b19130c1c..b44707348 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java @@ -849,11 +849,11 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl // managed elsewhere continue; case "SHULKER": - if (Settings.Enabled_Components.KILL_ROAD_MOBS) { + if (Settings.Enabled_Components.KILL_ROAD_MOBS && (Settings.Enabled_Components.KILL_NAMED_ROAD_MOBS || entity.getCustomName() == null)) { LivingEntity livingEntity = (LivingEntity) entity; List meta = entity.getMetadata("shulkerPlot"); if (!meta.isEmpty()) { - if (livingEntity.isLeashed()) { + if (livingEntity.isLeashed() && !Settings.Enabled_Components.KILL_OWNED_ROAD_MOBS) { continue; } List keep = entity.getMetadata("keep"); @@ -973,7 +973,9 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl || !entity.hasMetadata("keep")) { Entity passenger = entity.getPassenger(); if ((Settings.Enabled_Components.KILL_OWNED_ROAD_MOBS - || !(passenger instanceof Player)) && entity.getMetadata("keep").isEmpty()) { + || !((passenger instanceof Player) || livingEntity.isLeashed())) + && (Settings.Enabled_Components.KILL_NAMED_ROAD_MOBS || entity.getCustomName() == null) + && entity.getMetadata("keep").isEmpty()) { if (entity.hasMetadata("ps-tmp-teleport")) { continue; } @@ -983,8 +985,9 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl } } else { Entity passenger = entity.getPassenger(); - if ((Settings.Enabled_Components.KILL_OWNED_ROAD_MOBS - || !(passenger instanceof Player)) && entity.getMetadata("keep").isEmpty()) { + if ((Settings.Enabled_Components.KILL_OWNED_ROAD_MOBS || !(passenger instanceof Player)) + && (Settings.Enabled_Components.KILL_NAMED_ROAD_MOBS && entity.getCustomName() != null) + && entity.getMetadata("keep").isEmpty()) { if (entity.hasMetadata("ps-tmp-teleport")) { continue; } diff --git a/Core/src/main/java/com/plotsquared/core/configuration/Settings.java b/Core/src/main/java/com/plotsquared/core/configuration/Settings.java index 4e5ac9bc5..025c779ee 100644 --- a/Core/src/main/java/com/plotsquared/core/configuration/Settings.java +++ b/Core/src/main/java/com/plotsquared/core/configuration/Settings.java @@ -759,6 +759,8 @@ public class Settings extends Config { @Comment("Also kill any road mobs that are being ridden, or are leashed") public static boolean KILL_OWNED_ROAD_MOBS = false; + @Comment("Also kill any road mobs that are named") + public static boolean KILL_NAMED_ROAD_MOBS = false; @Comment("Kill items on roads (Stick, Paper, etc.)") public static boolean KILL_ROAD_ITEMS = false; @Comment("Kill vehicles on roads (Boat, Minecart, etc.)") From b740d5854c1fbf62eff167a91ca1f28c2bb3dcef Mon Sep 17 00:00:00 2001 From: Pierre Maurice Schwang Date: Mon, 10 Oct 2022 18:41:35 +0200 Subject: [PATCH 073/111] Support MiniMessage in plot-title flag (#3835) --- Core/src/main/java/com/plotsquared/core/util/StringMan.java | 5 +++-- Core/src/test/java/com/plotsquared/core/plot/FlagTest.java | 2 +- .../test/java/com/plotsquared/core/util/StringManTest.java | 4 +++- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/util/StringMan.java b/Core/src/main/java/com/plotsquared/core/util/StringMan.java index 8fb2f2940..32a594ea2 100644 --- a/Core/src/main/java/com/plotsquared/core/util/StringMan.java +++ b/Core/src/main/java/com/plotsquared/core/util/StringMan.java @@ -36,7 +36,8 @@ import java.util.regex.Pattern; public class StringMan { - private static final Pattern STRING_SPLIT_PATTERN = Pattern.compile("(?\"[\\w ]+\")|(?\\w+)"); + // Stolen from https://stackoverflow.com/a/366532/12620913 | Debug: https://regex101.com/r/DudJLb/1 + private static final Pattern STRING_SPLIT_PATTERN = Pattern.compile("[^\\s\"]+|\"([^\"]*)\""); public static String replaceFromMap(String string, Map replacements) { StringBuilder sb = new StringBuilder(string); @@ -355,7 +356,7 @@ public class StringMan { var matcher = StringMan.STRING_SPLIT_PATTERN.matcher(message); List splitMessages = new ArrayList<>(); while (matcher.find()) { - splitMessages.add(matcher.group(0).replaceAll("\"", "")); + splitMessages.add(matcher.group(matcher.groupCount() - 1).replaceAll("\"", "")); } return splitMessages; } diff --git a/Core/src/test/java/com/plotsquared/core/plot/FlagTest.java b/Core/src/test/java/com/plotsquared/core/plot/FlagTest.java index d1a7b2797..9b02f34da 100644 --- a/Core/src/test/java/com/plotsquared/core/plot/FlagTest.java +++ b/Core/src/test/java/com/plotsquared/core/plot/FlagTest.java @@ -101,7 +101,7 @@ public class FlagTest { public void shouldSuccessfullyParseTitleFlagWithTitleEmptyAndSubTitleSingleWord() { Assertions.assertDoesNotThrow(() -> { var title = PlotTitleFlag.TITLE_FLAG_DEFAULT.parse("\"\" \"single\"").getValue(); - Assertions.assertEquals(" ", title.title()); + Assertions.assertEquals("", title.title()); Assertions.assertEquals("single", title.subtitle()); }, "Should not throw a FlagParseException"); } diff --git a/Core/src/test/java/com/plotsquared/core/util/StringManTest.java b/Core/src/test/java/com/plotsquared/core/util/StringManTest.java index 8c1eb2aa1..14927ce42 100644 --- a/Core/src/test/java/com/plotsquared/core/util/StringManTest.java +++ b/Core/src/test/java/com/plotsquared/core/util/StringManTest.java @@ -32,7 +32,9 @@ public class StringManTest { new Message("title", List.of("title")), new Message("title \"sub title\"", List.of("title", "sub title")), new Message("\"a title\" subtitle", List.of("a title", "subtitle")), - new Message("\"title\" \"subtitle\"", List.of("title", "subtitle")) + new Message("\"title\" \"subtitle\"", List.of("title", "subtitle")), + new Message("\"How bold of you\" \"to assume I like rainbows\"", + List.of("How bold of you", "to assume I like rainbows")) ); for (Message message : messages) { From 11dd013333103cd2c323d8c5dad5e404e444d61f Mon Sep 17 00:00:00 2001 From: Jordan Date: Thu, 13 Oct 2022 16:46:29 +0100 Subject: [PATCH 074/111] fix: Adjust schematic height logic when pasting and actually set air as well (#3840) --- .../core/generator/HybridPlotManager.java | 3 +- .../core/generator/HybridPlotWorld.java | 137 ++++++++++++------ 2 files changed, 97 insertions(+), 43 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotManager.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotManager.java index af155b971..ffbfc5de2 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotManager.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotManager.java @@ -174,8 +174,9 @@ public class HybridPlotManager extends ClassicPlotManager { for (int y = 0; y < blocks.length; y++) { if (blocks[y] != null) { queue.setBlock(x, minY + y, z, blocks[y]); - } else { + } else if (!isRoad) { // This is necessary, otherwise any blocks not specified in the schematic will remain after a clear + // Do not set air for road as this may cause cavernous roads when debugroadregen is used queue.setBlock(x, minY + y, z, airBlock); } } diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index 5fb6ad868..9fda5abb6 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -21,7 +21,6 @@ package com.plotsquared.core.generator; import com.google.inject.Inject; import com.google.inject.assistedinject.Assisted; import com.intellectualsites.annotations.DoNotUse; -import com.intellectualsites.annotations.NotPublic; import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.ConfigurationSection; import com.plotsquared.core.configuration.Settings; @@ -75,6 +74,9 @@ public class HybridPlotWorld extends ClassicPlotWorld { public short PATH_WIDTH_UPPER; public HashMap G_SCH; public HashMap G_SCH_B; + /** + * The Y level at which schematic generation will start, lowest of either road or plot schematic generation. + */ public int SCHEM_Y; private Location SIGN_LOCATION; private File root = null; @@ -267,34 +269,64 @@ public class HybridPlotWorld extends ClassicPlotWorld { int oddshift = (this.ROAD_WIDTH & 1); SCHEM_Y = schematicStartHeight(); + + // plotY and roadY are important to allow plot and/or road schematic "overflow" into each other without causing AIOOB + // exceptions when attempting either to set blocks to, or get block from G_SCH + // Default plot schematic start height, normalized to the minimum height schematics are pasted from. int plotY = PLOT_HEIGHT - SCHEM_Y; int minRoadWall = Settings.Schematics.USE_WALL_IN_ROAD_SCHEM_HEIGHT ? Math.min(ROAD_HEIGHT, WALL_HEIGHT) : ROAD_HEIGHT; + // Default road schematic start height, normalized to the minimum height schematics are pasted from. int roadY = minRoadWall - SCHEM_Y; - int worldHeight = getMaxGenHeight() - getMinGenHeight() + 1; + int worldGenHeight = getMaxGenHeight() - getMinGenHeight() + 1; + + int maxSchematicHeight = 0; + int plotSchemHeight = 0; // SCHEM_Y should be normalised to the plot "start" height if (schematic3 != null) { - if (schematic3.getClipboard().getDimensions().getY() == worldHeight) { - SCHEM_Y = plotY = 0; + plotSchemHeight = maxSchematicHeight = schematic3.getClipboard().getDimensions().getY(); + if (maxSchematicHeight == worldGenHeight) { + SCHEM_Y = getMinGenHeight(); + plotY = 0; } else if (!Settings.Schematics.PASTE_ON_TOP) { - SCHEM_Y = plotY = getMinBuildHeight() - getMinGenHeight(); + SCHEM_Y = getMinBuildHeight(); + plotY = 0; } } + int roadSchemHeight; + if (schematic1 != null) { - if (schematic1.getClipboard().getDimensions().getY() == worldHeight) { - SCHEM_Y = roadY = getMinGenHeight(); - if (schematic3 != null && schematic3.getClipboard().getDimensions().getY() != worldHeight - && !Settings.Schematics.PASTE_ON_TOP) { - plotY = PLOT_HEIGHT; + roadSchemHeight = schematic1.getClipboard().getDimensions().getY(); + maxSchematicHeight = Math.max(roadSchemHeight, maxSchematicHeight); + if (maxSchematicHeight == worldGenHeight) { + SCHEM_Y = getMinGenHeight(); + roadY = 0; // Road is the lowest schematic + if (schematic3 != null && schematic3.getClipboard().getDimensions().getY() != worldGenHeight) { + // Road is the lowest schematic. Normalize plotY to it. + if (Settings.Schematics.PASTE_ON_TOP) { + plotY = PLOT_HEIGHT - getMinGenHeight(); + } else { + plotY = getMinBuildHeight() - getMinGenHeight(); + } } } else if (!Settings.Schematics.PASTE_ROAD_ON_TOP) { - SCHEM_Y = roadY = getMinBuildHeight(); - if (schematic3 != null && schematic3.getClipboard().getDimensions().getY() != worldHeight - && !Settings.Schematics.PASTE_ON_TOP) { - plotY = PLOT_HEIGHT; + if (SCHEM_Y == getMinGenHeight()) { // Only possible if plot schematic is enabled + // Plot is still the lowest schematic, normalize roadY to it + roadY = getMinBuildHeight() - getMinGenHeight(); + } else if (schematic3 != null) { + SCHEM_Y = getMinBuildHeight(); + roadY = 0;// Road is the lowest schematic + if (Settings.Schematics.PASTE_ON_TOP) { + // Road is the lowest schematic. Normalize plotY to it. + plotY = PLOT_HEIGHT - getMinBuildHeight(); + } + maxSchematicHeight = Math.max(maxSchematicHeight, plotY + plotSchemHeight); } + } else { + roadY = minRoadWall - SCHEM_Y; + maxSchematicHeight = Math.max(maxSchematicHeight, roadY + roadSchemHeight); } } @@ -331,17 +363,15 @@ public class HybridPlotWorld extends ClassicPlotWorld { y + min.getBlockY(), z + min.getBlockZ() )); - if (!id.getBlockType().getMaterial().isAir()) { - schem3PopulationNeeded |= id.hasNbtData(); - addOverlayBlock( - (short) (x + shift + oddshift + centerShiftX), - (short) (y + plotY), - (short) (z + shift + oddshift + centerShiftZ), - id, - false, - h3 - ); - } + schem3PopulationNeeded |= id.hasNbtData(); + addOverlayBlock( + (short) (x + shift + oddshift + centerShiftX), + (short) (y + plotY), + (short) (z + shift + oddshift + centerShiftZ), + id, + false, + maxSchematicHeight + ); } if (blockArrayClipboard3.hasBiomes()) { BiomeType biome = blockArrayClipboard3.getBiome(BlockVector2.at( @@ -391,18 +421,23 @@ public class HybridPlotWorld extends ClassicPlotWorld { y + min.getBlockY(), z + min.getBlockZ() )); - if (!id.getBlockType().getMaterial().isAir()) { - schem1PopulationNeeded |= id.hasNbtData(); - addOverlayBlock((short) (x - shift), (short) (y + roadY), (short) (z + shift + oddshift), id, false, h1); - addOverlayBlock( - (short) (z + shift + oddshift), - (short) (y + roadY), - (short) (shift - x + (oddshift - 1)), - id, - true, - h1 - ); - } + schem1PopulationNeeded |= id.hasNbtData(); + addOverlayBlock( + (short) (x - shift), + (short) (y + roadY), + (short) (z + shift + oddshift), + id, + false, + maxSchematicHeight + ); + addOverlayBlock( + (short) (z + shift + oddshift), + (short) (y + roadY), + (short) (shift - x + (oddshift - 1)), + id, + true, + maxSchematicHeight + ); } if (blockArrayClipboard1.hasBiomes()) { BiomeType biome = blockArrayClipboard1.getBiome(BlockVector2.at(x + min.getBlockX(), z + min.getBlockZ())); @@ -430,10 +465,15 @@ public class HybridPlotWorld extends ClassicPlotWorld { y + min.getBlockY(), z + min.getBlockZ() )); - if (!id.getBlockType().getMaterial().isAir()) { - schem2PopulationNeeded |= id.hasNbtData(); - addOverlayBlock((short) (x - shift), (short) (y + roadY), (short) (z - shift), id, false, h2); - } + schem2PopulationNeeded |= id.hasNbtData(); + addOverlayBlock( + (short) (x - shift), + (short) (y + roadY), + (short) (z - shift), + id, + false, + maxSchematicHeight + ); } if (blockArrayClipboard2.hasBiomes()) { BiomeType biome = blockArrayClipboard2.getBiome(BlockVector2.at(x + min.getBlockX(), z + min.getBlockZ())); @@ -443,6 +483,10 @@ public class HybridPlotWorld extends ClassicPlotWorld { } } + /** + * @deprecated This method should not be available for public API usage and will be made private. + */ + @Deprecated(forRemoval = true, since = "TODO") public void addOverlayBlock(short x, short y, short z, BaseBlock id, boolean rotate, int height) { if (z < 0) { z += this.SIZE; @@ -462,13 +506,22 @@ public class HybridPlotWorld extends ClassicPlotWorld { if (y >= height) { if (y > lastOverlayHeightError) { lastOverlayHeightError = y; - LOGGER.error(String.format("Error adding overlay block. `y > height`. y=%s, height=%s", y, height)); + LOGGER.error( + "Error adding overlay block in world {}. `y > height`. y={}, height={}", + getWorldName(), + y, + height + ); } return; } existing[y] = id; } + /** + * @deprecated This method should not be available for public API usage and will be made private. + */ + @Deprecated(forRemoval = true, since = "TODO") public void addOverlayBiome(short x, short z, BiomeType id) { if (z < 0) { z += this.SIZE; From e244527538c1168af4247495dde63198f1cb835c Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Thu, 13 Oct 2022 19:16:19 +0200 Subject: [PATCH 075/111] Make more complex patterns work correctly (#3847) allow more complex patterns to work correctly --- .../main/java/com/plotsquared/bukkit/queue/GenChunk.java | 6 +++++- .../main/java/com/plotsquared/core/util/PatternUtil.java | 3 +-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java index 44ec39545..558a86f51 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/GenChunk.java @@ -183,7 +183,11 @@ public class GenChunk extends ScopedQueueCoordinator { @Override public boolean setBlock(int x, int y, int z, @NonNull Pattern pattern) { - return setBlock(x, y, z, PatternUtil.apply(Preconditions.checkNotNull(pattern, "Pattern may not be null"), x, y, z)); + final BaseBlock block = PatternUtil.apply(Preconditions.checkNotNull( + pattern, + "Pattern may not be null" + ), x + (chunkX << 4), y, z + (chunkZ << 4)); + return setBlock(x, y, z, block); } @Override diff --git a/Core/src/main/java/com/plotsquared/core/util/PatternUtil.java b/Core/src/main/java/com/plotsquared/core/util/PatternUtil.java index 26100f811..e90ac3595 100644 --- a/Core/src/main/java/com/plotsquared/core/util/PatternUtil.java +++ b/Core/src/main/java/com/plotsquared/core/util/PatternUtil.java @@ -29,7 +29,6 @@ import com.sk89q.worldedit.extension.input.ParserContext; import com.sk89q.worldedit.extension.platform.Actor; import com.sk89q.worldedit.function.pattern.BlockPattern; import com.sk89q.worldedit.function.pattern.Pattern; -import com.sk89q.worldedit.function.pattern.RandomPattern; import com.sk89q.worldedit.math.BlockVector3; import com.sk89q.worldedit.world.block.BaseBlock; import com.sk89q.worldedit.world.block.BlockState; @@ -44,7 +43,7 @@ public class PatternUtil { public static BaseBlock apply(@NonNull Pattern pattern, int x, int y, int z) { Preconditions.checkNotNull(pattern, "Pattern may not be null"); - if (pattern instanceof BlockPattern || pattern instanceof RandomPattern + if (pattern instanceof BlockPattern || pattern instanceof BlockState || pattern instanceof BlockType || pattern instanceof BaseBlock) { return pattern.applyBlock(BlockVector3.ZERO); From 308a5aa78135484a290ba943fcd80ca29ad0876e Mon Sep 17 00:00:00 2001 From: Jordan Date: Thu, 13 Oct 2022 18:17:27 +0100 Subject: [PATCH 076/111] Ensure all setBlock methods in BlockArrayCacheScopedQueueCoordinator apply the correct offset (#3843) - Fixes #3783 --- .../core/queue/BlockArrayCacheScopedQueueCoordinator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java b/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java index 243f5637f..c26d8ff16 100644 --- a/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java +++ b/Core/src/main/java/com/plotsquared/core/queue/BlockArrayCacheScopedQueueCoordinator.java @@ -116,7 +116,7 @@ public class BlockArrayCacheScopedQueueCoordinator extends ScopedQueueCoordinato x += offsetX; z += offsetZ; if (x >= scopeMinX && x < scopeMaxX && y >= minY && y <= maxY && z >= scopeMinZ && z < scopeMaxZ) { - blockStates[y - minY][x][z] = id.toImmutableState(); + blockStates[y - minY][x - scopeMinX][z - scopeMinZ] = id.toImmutableState(); } return false; } From 76c6be9ba731e681c7179a99594f2de983031f1c Mon Sep 17 00:00:00 2001 From: BlockyTheDev <86119630+BlockyTheDev@users.noreply.github.com> Date: Thu, 13 Oct 2022 19:19:20 +0200 Subject: [PATCH 077/111] Fix 'No resource for locale 'lang' found ' error (#3830) * Fix #3820 * Reword message and add link to completed translations * Fix #3820 * Reword message and add link to completed translations * Add line breaks for better code readability * Add line breaks for better code readability Co-authored-by: Alexander Brandes --- .../caption/load/ClassLoaderCaptionProvider.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/configuration/caption/load/ClassLoaderCaptionProvider.java b/Core/src/main/java/com/plotsquared/core/configuration/caption/load/ClassLoaderCaptionProvider.java index 53fb35473..14b4cd624 100644 --- a/Core/src/main/java/com/plotsquared/core/configuration/caption/load/ClassLoaderCaptionProvider.java +++ b/Core/src/main/java/com/plotsquared/core/configuration/caption/load/ClassLoaderCaptionProvider.java @@ -53,7 +53,10 @@ final class ClassLoaderCaptionProvider implements DefaultCaptionProvider { try { final InputStream stream = this.classLoader.getResourceAsStream(url); if (stream == null) { - LOGGER.warn("No resource for locale '{}' found", locale); + LOGGER.info("No resource for locale '{}' found in the plugin file." + + "Please ensure you have placed the latest version of the file messages_{}.json in the 'lang' folder." + + "You may be able to find completed translations at https://intellectualsites.crowdin.com/plotsquared", + locale, locale); return null; } try (final BufferedReader reader = new BufferedReader(new InputStreamReader(stream))) { From 9f3850000c2f08b43d7bd53fddf62909ef7c446c Mon Sep 17 00:00:00 2001 From: Jordan Date: Sat, 15 Oct 2022 14:26:14 +0100 Subject: [PATCH 078/111] fix: adjust nullability checks for shulkers in the kill road mobs task (#3842) - Fixes #3789 --- .../java/com/plotsquared/bukkit/BukkitPlatform.java | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java index b44707348..4355e9418 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitPlatform.java @@ -866,10 +866,8 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl com.plotsquared.core.location.Location pLoc = BukkitUtil.adapt(entity.getLocation()); PlotArea area = pLoc.getPlotArea(); if (area != null) { - PlotId currentPlotId = area.getPlotAbs(pLoc).getId(); - if (!originalPlotId.equals(currentPlotId) && (currentPlotId == null || !area.getPlot( - originalPlotId) - .equals(area.getPlot(currentPlotId)))) { + Plot currentPlot = area.getPlotAbs(pLoc); + if (currentPlot == null || !originalPlotId.equals(currentPlot.getId())) { if (entity.hasMetadata("ps-tmp-teleport")) { continue; } @@ -883,11 +881,11 @@ public final class BukkitPlatform extends JavaPlugin implements Listener, PlotPl com.plotsquared.core.location.Location pLoc = BukkitUtil.adapt(entity.getLocation()); PlotArea area = pLoc.getPlotArea(); if (area != null) { - PlotId currentPlotId = area.getPlotAbs(pLoc).getId(); - if (currentPlotId != null) { + Plot currentPlot = area.getPlotAbs(pLoc); + if (currentPlot != null) { entity.setMetadata( "shulkerPlot", - new FixedMetadataValue((Plugin) PlotSquared.platform(), currentPlotId) + new FixedMetadataValue((Plugin) PlotSquared.platform(), currentPlot.getId()) ); } } From e0762f63a83d263315e7eb373c3be3861947f6ef Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sat, 15 Oct 2022 16:04:30 +0200 Subject: [PATCH 079/111] chore: Replace paper reference in favor of bom --- Bukkit/build.gradle.kts | 2 +- gradle/libs.versions.toml | 4 ---- 2 files changed, 1 insertion(+), 5 deletions(-) diff --git a/Bukkit/build.gradle.kts b/Bukkit/build.gradle.kts index 5b9bcbf21..d56c2d74d 100644 --- a/Bukkit/build.gradle.kts +++ b/Bukkit/build.gradle.kts @@ -24,7 +24,7 @@ dependencies { implementation("org.bstats:bstats-bukkit") // Paper - compileOnly(libs.paper) + compileOnly("io.papermc.paper:paper-api") implementation("io.papermc:paperlib") // Plugins diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 83a136062..7b45d2462 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,6 +1,5 @@ [versions] # Platform expectations -paper = "1.18.1-R0.1-SNAPSHOT" guice = "5.1.0" spotbugs = "4.7.2" @@ -26,9 +25,6 @@ licenser = "0.6.1" nexus = "1.1.0" [libraries] -# Platform expectations -paper = { group = "io.papermc.paper", name = "paper-api", version.ref = "paper" } - # Platform expectations guice = { group = "com.google.inject", name = "guice", version.ref = "guice" } guiceassistedinject = { group = "com.google.inject.extensions", name = "guice-assistedinject", version.ref = "guice" } From 0ae8fc46b88f15416b9ecb20331b211c095339d2 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 17 Oct 2022 09:24:42 +0200 Subject: [PATCH 080/111] Update dependency com.github.spotbugs:spotbugs-annotations to v4.7.3 (#3851) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 7b45d2462..2bfdb818a 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,7 +1,7 @@ [versions] # Platform expectations guice = "5.1.0" -spotbugs = "4.7.2" +spotbugs = "4.7.3" # Plugins worldedit = "7.2.12" From b8b3098022302908e34bea203071dfd5cc6cf61d Mon Sep 17 00:00:00 2001 From: michizhou <33012425+michizhou@users.noreply.github.com> Date: Mon, 17 Oct 2022 00:31:48 -0700 Subject: [PATCH 081/111] feat: Move ExpireManager to Guice by removing legacy IMP references (#3845) * feat: Move ExpireManager to Guice by removing legacy IMP references * Mark ExpireManager IMP as deprecated and add comments * Add import for PlotPlatform for function reference * Add ExpireManager instance call and optimize performance --- .../main/java/com/plotsquared/core/PlotPlatform.java | 11 +++++++++++ .../main/java/com/plotsquared/core/PlotSquared.java | 9 +++++---- .../java/com/plotsquared/core/command/DebugExec.java | 9 ++++----- .../main/java/com/plotsquared/core/command/Done.java | 4 ++-- .../java/com/plotsquared/core/command/ListCmd.java | 3 +-- .../main/java/com/plotsquared/core/command/Trim.java | 5 ++--- .../com/plotsquared/core/listener/PlotListener.java | 5 ++--- .../java/com/plotsquared/core/player/PlotPlayer.java | 5 ++--- .../src/main/java/com/plotsquared/core/plot/Plot.java | 9 ++++----- .../core/plot/expiration/ExpireManager.java | 5 +++++ .../plotsquared/core/plot/expiration/ExpiryTask.java | 4 +++- .../com/plotsquared/core/util/EventDispatcher.java | 6 +++--- .../core/util/query/ExpiredPlotProvider.java | 4 ++-- 13 files changed, 46 insertions(+), 33 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java index 020c3c740..b601140f6 100644 --- a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java +++ b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java @@ -32,6 +32,7 @@ import com.plotsquared.core.inject.annotations.DefaultGenerator; import com.plotsquared.core.location.World; import com.plotsquared.core.permissions.PermissionHandler; import com.plotsquared.core.player.PlotPlayer; +import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.queue.GlobalBlockQueue; import com.plotsquared.core.util.ChunkManager; @@ -284,6 +285,16 @@ public interface PlotPlatform

extends LocaleHolder { return injector().getInstance(ChunkManager.class); } + /** + * Get the {@link ExpireManager} implementation for the platform + * + * @return Expire manager + * @since TODO + */ + default @NonNull ExpireManager expireManager() { + return injector().getInstance(ExpireManager.class); + } + /** * Get the {@link PlotAreaManager} implementation. * diff --git a/Core/src/main/java/com/plotsquared/core/PlotSquared.java b/Core/src/main/java/com/plotsquared/core/PlotSquared.java index 5f89c69c1..76156fc21 100644 --- a/Core/src/main/java/com/plotsquared/core/PlotSquared.java +++ b/Core/src/main/java/com/plotsquared/core/PlotSquared.java @@ -290,11 +290,11 @@ public class PlotSquared { public void startExpiryTasks() { if (Settings.Enabled_Components.PLOT_EXPIRY) { - ExpireManager.IMP = new ExpireManager(this.eventDispatcher); - ExpireManager.IMP.runAutomatedTask(); + ExpireManager expireManager = PlotSquared.platform().expireManager(); + expireManager.runAutomatedTask(); for (Settings.Auto_Clear settings : Settings.AUTO_CLEAR.getInstances()) { ExpiryTask task = new ExpiryTask(settings, this.getPlotAreaManager()); - ExpireManager.IMP.addTask(task); + expireManager.addTask(task); } } } @@ -645,7 +645,8 @@ public class PlotSquared { } else { list = new ArrayList<>(input); } - list.sort(Comparator.comparingLong(a -> ExpireManager.IMP.getTimestamp(a.getOwnerAbs()))); + ExpireManager expireManager = PlotSquared.platform().expireManager(); + list.sort(Comparator.comparingLong(a -> expireManager.getTimestamp(a.getOwnerAbs()))); return list; } diff --git a/Core/src/main/java/com/plotsquared/core/command/DebugExec.java b/Core/src/main/java/com/plotsquared/core/command/DebugExec.java index 7290a544c..9566bbc3c 100644 --- a/Core/src/main/java/com/plotsquared/core/command/DebugExec.java +++ b/Core/src/main/java/com/plotsquared/core/command/DebugExec.java @@ -19,6 +19,7 @@ package com.plotsquared.core.command; import com.google.inject.Inject; +import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.caption.StaticCaption; import com.plotsquared.core.configuration.caption.TranslatableCaption; import com.plotsquared.core.events.PlotFlagRemoveEvent; @@ -139,10 +140,8 @@ public class DebugExec extends SubCommand { return true; } case "start-expire" -> { - if (ExpireManager.IMP == null) { - ExpireManager.IMP = new ExpireManager(this.eventDispatcher); - } - if (ExpireManager.IMP.runAutomatedTask()) { + ExpireManager expireManager = PlotSquared.platform().expireManager() == null ? new ExpireManager(this.eventDispatcher) : PlotSquared.platform().expireManager(); + if (expireManager.runAutomatedTask()) { player.sendMessage(TranslatableCaption.of("debugexec.expiry_started")); } else { player.sendMessage(TranslatableCaption.of("debugexec.expiry_already_started")); @@ -150,7 +149,7 @@ public class DebugExec extends SubCommand { return true; } case "stop-expire" -> { - if (ExpireManager.IMP == null || !ExpireManager.IMP.cancelTask()) { + if (PlotSquared.platform().expireManager() == null || !PlotSquared.platform().expireManager().cancelTask()) { player.sendMessage(TranslatableCaption.of("debugexec.task_halted")); } else { player.sendMessage(TranslatableCaption.of("debugexec.task_cancelled")); diff --git a/Core/src/main/java/com/plotsquared/core/command/Done.java b/Core/src/main/java/com/plotsquared/core/command/Done.java index 6537daeef..c50bdfce9 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Done.java +++ b/Core/src/main/java/com/plotsquared/core/command/Done.java @@ -19,6 +19,7 @@ package com.plotsquared.core.command; import com.google.inject.Inject; +import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.Settings; import com.plotsquared.core.configuration.caption.TranslatableCaption; import com.plotsquared.core.events.PlotDoneEvent; @@ -29,7 +30,6 @@ import com.plotsquared.core.location.Location; import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.PlotPlayer; import com.plotsquared.core.plot.Plot; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.expiration.PlotAnalysis; import com.plotsquared.core.plot.flag.PlotFlag; import com.plotsquared.core.plot.flag.implementations.DoneFlag; @@ -94,7 +94,7 @@ public class Done extends SubCommand { Template.of("plot", plot.getId().toString()) ); final Settings.Auto_Clear doneRequirements = Settings.AUTO_CLEAR.get("done"); - if (ExpireManager.IMP == null || doneRequirements == null) { + if (PlotSquared.platform().expireManager() == null || doneRequirements == null) { finish(plot, player, true); plot.removeRunning(); } else { diff --git a/Core/src/main/java/com/plotsquared/core/command/ListCmd.java b/Core/src/main/java/com/plotsquared/core/command/ListCmd.java index b47a99e25..fcb161926 100644 --- a/Core/src/main/java/com/plotsquared/core/command/ListCmd.java +++ b/Core/src/main/java/com/plotsquared/core/command/ListCmd.java @@ -30,7 +30,6 @@ import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.PlotPlayer; import com.plotsquared.core.plot.Plot; import com.plotsquared.core.plot.PlotArea; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.flag.implementations.DoneFlag; import com.plotsquared.core.plot.flag.implementations.PriceFlag; import com.plotsquared.core.plot.flag.implementations.ServerPlotFlag; @@ -240,7 +239,7 @@ public class ListCmd extends SubCommand { ); return false; } - if (ExpireManager.IMP == null) { + if (PlotSquared.platform().expireManager() == null) { plotConsumer.accept(PlotQuery.newQuery().noPlots()); } else { plotConsumer.accept(PlotQuery.newQuery().expiredPlots()); diff --git a/Core/src/main/java/com/plotsquared/core/command/Trim.java b/Core/src/main/java/com/plotsquared/core/command/Trim.java index 09a5ff925..ca4603bd3 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Trim.java +++ b/Core/src/main/java/com/plotsquared/core/command/Trim.java @@ -25,7 +25,6 @@ import com.plotsquared.core.configuration.caption.TranslatableCaption; import com.plotsquared.core.location.Location; import com.plotsquared.core.player.PlotPlayer; import com.plotsquared.core.plot.Plot; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.queue.GlobalBlockQueue; import com.plotsquared.core.queue.QueueCoordinator; @@ -92,8 +91,8 @@ public class Trim extends SubCommand { } TranslatableCaption.of("trim.trim_starting"); final List plots = PlotQuery.newQuery().inWorld(world).asList(); - if (ExpireManager.IMP != null) { - plots.removeAll(ExpireManager.IMP.getPendingExpired()); + if (PlotSquared.platform().expireManager() != null) { + plots.removeAll(PlotSquared.platform().expireManager().getPendingExpired()); } result.value1 = new HashSet<>(PlotSquared.platform().worldUtil().getChunkChunks(world)); result.value2 = new HashSet<>(); diff --git a/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java b/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java index 6c837a2c6..0550d65eb 100644 --- a/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java +++ b/Core/src/main/java/com/plotsquared/core/listener/PlotListener.java @@ -36,7 +36,6 @@ import com.plotsquared.core.plot.PlotArea; import com.plotsquared.core.plot.PlotTitle; import com.plotsquared.core.plot.PlotWeather; import com.plotsquared.core.plot.comment.CommentManager; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.flag.GlobalFlagContainer; import com.plotsquared.core.plot.flag.PlotFlag; import com.plotsquared.core.plot.flag.implementations.DenyExitFlag; @@ -163,8 +162,8 @@ public class PlotListener { if ((last != null) && !last.getId().equals(plot.getId())) { plotExit(player, last); } - if (ExpireManager.IMP != null) { - ExpireManager.IMP.handleEntry(player, plot); + if (PlotSquared.platform().expireManager() != null) { + PlotSquared.platform().expireManager().handleEntry(player, plot); } lastPlot.set(plot); } diff --git a/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java b/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java index 3594f5727..f0d5cdfc3 100644 --- a/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java +++ b/Core/src/main/java/com/plotsquared/core/player/PlotPlayer.java @@ -42,7 +42,6 @@ import com.plotsquared.core.plot.PlotArea; import com.plotsquared.core.plot.PlotCluster; import com.plotsquared.core.plot.PlotId; import com.plotsquared.core.plot.PlotWeather; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.flag.implementations.DoneFlag; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.plot.world.SinglePlotArea; @@ -618,8 +617,8 @@ public abstract class PlotPlayer

implements CommandCaller, OfflinePlotPlayer, LOGGER.info("Plot {} was deleted + cleared due to {} getting banned", owned.getId(), getName()); } } - if (ExpireManager.IMP != null) { - ExpireManager.IMP.storeDate(getUUID(), System.currentTimeMillis()); + if (PlotSquared.platform().expireManager() != null) { + PlotSquared.platform().expireManager().storeDate(getUUID(), System.currentTimeMillis()); } PlotSquared.platform().playerManager().removePlayer(this); PlotSquared.platform().unregister(this); diff --git a/Core/src/main/java/com/plotsquared/core/plot/Plot.java b/Core/src/main/java/com/plotsquared/core/plot/Plot.java index 757f89012..098b95656 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/Plot.java +++ b/Core/src/main/java/com/plotsquared/core/plot/Plot.java @@ -40,7 +40,6 @@ import com.plotsquared.core.location.Location; import com.plotsquared.core.permissions.Permission; import com.plotsquared.core.player.ConsolePlayer; import com.plotsquared.core.player.PlotPlayer; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.expiration.PlotAnalysis; import com.plotsquared.core.plot.flag.FlagContainer; import com.plotsquared.core.plot.flag.GlobalFlagContainer; @@ -1105,8 +1104,8 @@ public class Plot { * @return A boolean indicating whether or not the operation succeeded */ public boolean setFlag(final @NonNull PlotFlag flag) { - if (flag instanceof KeepFlag && ExpireManager.IMP != null) { - ExpireManager.IMP.updateExpired(this); + if (flag instanceof KeepFlag && PlotSquared.platform().expireManager() != null) { + PlotSquared.platform().expireManager().updateExpired(this); } for (final Plot plot : this.getConnectedPlots()) { plot.getFlagContainer().addFlag(flag); @@ -2831,11 +2830,11 @@ public class Plot { Component members = PlayerManager.getPlayerList(this.getMembers(), player); Component denied = PlayerManager.getPlayerList(this.getDenied(), player); String seen; - if (Settings.Enabled_Components.PLOT_EXPIRY && ExpireManager.IMP != null) { + if (Settings.Enabled_Components.PLOT_EXPIRY && PlotSquared.platform().expireManager() != null) { if (this.isOnline()) { seen = TranslatableCaption.of("info.now").getComponent(player); } else { - int time = (int) (ExpireManager.IMP.getAge(this, false) / 1000); + int time = (int) (PlotSquared.platform().expireManager().getAge(this, false) / 1000); if (time != 0) { seen = TimeUtil.secToTime(time); } else { diff --git a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java index d8d565de9..f5a23039a 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java +++ b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java @@ -18,6 +18,7 @@ */ package com.plotsquared.core.plot.expiration; +import com.plotsquared.core.PlotPlatform; import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.caption.Caption; import com.plotsquared.core.configuration.caption.Templates; @@ -60,6 +61,10 @@ import java.util.concurrent.ConcurrentLinkedDeque; public class ExpireManager { + /** + * @deprecated Use {@link PlotPlatform#expireManager()} instead + */ + @Deprecated(forRemoval = true, since = "TODO") public static ExpireManager IMP; private final ConcurrentHashMap dates_cache; private final ConcurrentHashMap account_age_cache; diff --git a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpiryTask.java b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpiryTask.java index b1205d6da..e65ed1aaf 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpiryTask.java +++ b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpiryTask.java @@ -18,6 +18,7 @@ */ package com.plotsquared.core.plot.expiration; +import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.Settings; import com.plotsquared.core.plot.Plot; import com.plotsquared.core.plot.PlotArea; @@ -72,8 +73,9 @@ public class ExpiryTask { min = false; diff = plots.size() - settings.REQUIRED_PLOTS; } + ExpireManager expireManager = PlotSquared.platform().expireManager(); List entireList = - plots.stream().map(plot -> ExpireManager.IMP.getAge(plot, settings.DELETE_IF_OWNER_IS_UNKNOWN)) + plots.stream().map(plot -> expireManager.getAge(plot, settings.DELETE_IF_OWNER_IS_UNKNOWN)) .collect(Collectors.toList()); List top = new ArrayList<>(diff + 1); if (diff > 1000) { 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 e91c7b35b..b2d858b4d 100644 --- a/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java +++ b/Core/src/main/java/com/plotsquared/core/util/EventDispatcher.java @@ -20,6 +20,7 @@ package com.plotsquared.core.util; import com.google.common.eventbus.EventBus; import com.intellectualsites.annotations.DoNotUse; +import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.Settings; import com.plotsquared.core.configuration.caption.TranslatableCaption; import com.plotsquared.core.events.PlayerAutoPlotEvent; @@ -59,7 +60,6 @@ import com.plotsquared.core.plot.Plot; import com.plotsquared.core.plot.PlotArea; import com.plotsquared.core.plot.PlotId; import com.plotsquared.core.plot.Rating; -import com.plotsquared.core.plot.expiration.ExpireManager; import com.plotsquared.core.plot.flag.PlotFlag; import com.plotsquared.core.plot.flag.implementations.DeviceInteractFlag; import com.plotsquared.core.plot.flag.implementations.MiscPlaceFlag; @@ -300,8 +300,8 @@ public class EventDispatcher { if (player == null) { return; //possible future warning message to figure out where we are retrieving null } - if (ExpireManager.IMP != null) { - ExpireManager.IMP.handleJoin(player); + if (PlotSquared.platform().expireManager() != null) { + PlotSquared.platform().expireManager().handleJoin(player); } if (this.worldEdit != null) { if (player.getAttribute("worldedit")) { diff --git a/Core/src/main/java/com/plotsquared/core/util/query/ExpiredPlotProvider.java b/Core/src/main/java/com/plotsquared/core/util/query/ExpiredPlotProvider.java index 622983e13..1fac18f2c 100644 --- a/Core/src/main/java/com/plotsquared/core/util/query/ExpiredPlotProvider.java +++ b/Core/src/main/java/com/plotsquared/core/util/query/ExpiredPlotProvider.java @@ -18,8 +18,8 @@ */ package com.plotsquared.core.util.query; +import com.plotsquared.core.PlotSquared; import com.plotsquared.core.plot.Plot; -import com.plotsquared.core.plot.expiration.ExpireManager; import java.util.Collection; @@ -27,7 +27,7 @@ class ExpiredPlotProvider implements PlotProvider { @Override public Collection getPlots() { - return ExpireManager.IMP.getPendingExpired(); + return PlotSquared.platform().expireManager().getPendingExpired(); } } From fe5e3d5f6d2c08f4f303c72b69292676388c433f Mon Sep 17 00:00:00 2001 From: Pierre Maurice Schwang Date: Tue, 18 Oct 2022 10:17:34 +0200 Subject: [PATCH 082/111] Annotate ExpireManager with @Inject (#3852) fix: annotate ExpireManager with @Inject --- .../main/java/com/plotsquared/core/command/DebugExec.java | 5 ++--- .../com/plotsquared/core/plot/expiration/ExpireManager.java | 2 ++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/DebugExec.java b/Core/src/main/java/com/plotsquared/core/command/DebugExec.java index 9566bbc3c..51e8ad8fe 100644 --- a/Core/src/main/java/com/plotsquared/core/command/DebugExec.java +++ b/Core/src/main/java/com/plotsquared/core/command/DebugExec.java @@ -140,8 +140,7 @@ public class DebugExec extends SubCommand { return true; } case "start-expire" -> { - ExpireManager expireManager = PlotSquared.platform().expireManager() == null ? new ExpireManager(this.eventDispatcher) : PlotSquared.platform().expireManager(); - if (expireManager.runAutomatedTask()) { + if (PlotSquared.platform().expireManager().runAutomatedTask()) { player.sendMessage(TranslatableCaption.of("debugexec.expiry_started")); } else { player.sendMessage(TranslatableCaption.of("debugexec.expiry_already_started")); @@ -149,7 +148,7 @@ public class DebugExec extends SubCommand { return true; } case "stop-expire" -> { - if (PlotSquared.platform().expireManager() == null || !PlotSquared.platform().expireManager().cancelTask()) { + if (!PlotSquared.platform().expireManager().cancelTask()) { player.sendMessage(TranslatableCaption.of("debugexec.task_halted")); } else { player.sendMessage(TranslatableCaption.of("debugexec.task_cancelled")); diff --git a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java index f5a23039a..24897af82 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java +++ b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java @@ -18,6 +18,7 @@ */ package com.plotsquared.core.plot.expiration; +import com.google.inject.Inject; import com.plotsquared.core.PlotPlatform; import com.plotsquared.core.PlotSquared; import com.plotsquared.core.configuration.caption.Caption; @@ -76,6 +77,7 @@ public class ExpireManager { */ private int running; + @Inject public ExpireManager(final @NonNull EventDispatcher eventDispatcher) { this.tasks = new ArrayDeque<>(); this.dates_cache = new ConcurrentHashMap<>(); From de4e91ff62ccafef2d74c2f63c6960d12ea99615 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 18 Oct 2022 23:12:27 +0200 Subject: [PATCH 083/111] Release 6.10.2 --- Core/src/main/java/com/plotsquared/core/PlotPlatform.java | 2 +- .../java/com/plotsquared/core/generator/HybridPlotWorld.java | 4 ++-- Core/src/main/java/com/plotsquared/core/plot/PlotId.java | 2 +- .../com/plotsquared/core/plot/expiration/ExpireManager.java | 2 +- build.gradle.kts | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java index b601140f6..958468098 100644 --- a/Core/src/main/java/com/plotsquared/core/PlotPlatform.java +++ b/Core/src/main/java/com/plotsquared/core/PlotPlatform.java @@ -289,7 +289,7 @@ public interface PlotPlatform

extends LocaleHolder { * Get the {@link ExpireManager} implementation for the platform * * @return Expire manager - * @since TODO + * @since 6.10.2 */ default @NonNull ExpireManager expireManager() { return injector().getInstance(ExpireManager.class); diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index 9fda5abb6..22b1a2f5e 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -486,7 +486,7 @@ public class HybridPlotWorld extends ClassicPlotWorld { /** * @deprecated This method should not be available for public API usage and will be made private. */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.10.2") public void addOverlayBlock(short x, short y, short z, BaseBlock id, boolean rotate, int height) { if (z < 0) { z += this.SIZE; @@ -521,7 +521,7 @@ public class HybridPlotWorld extends ClassicPlotWorld { /** * @deprecated This method should not be available for public API usage and will be made private. */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.10.2") public void addOverlayBiome(short x, short z, BiomeType id) { if (z < 0) { z += this.SIZE; diff --git a/Core/src/main/java/com/plotsquared/core/plot/PlotId.java b/Core/src/main/java/com/plotsquared/core/plot/PlotId.java index 4d0bb8fb7..62077ccb9 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/PlotId.java +++ b/Core/src/main/java/com/plotsquared/core/plot/PlotId.java @@ -112,7 +112,7 @@ public final class PlotId { * @return Plot ID copy * @deprecated PlotId is immutable, copy is not required. */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.10.2") public @NonNull PlotId copy() { return this; } diff --git a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java index 24897af82..0863112f8 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java +++ b/Core/src/main/java/com/plotsquared/core/plot/expiration/ExpireManager.java @@ -65,7 +65,7 @@ public class ExpireManager { /** * @deprecated Use {@link PlotPlatform#expireManager()} instead */ - @Deprecated(forRemoval = true, since = "TODO") + @Deprecated(forRemoval = true, since = "6.10.2") public static ExpireManager IMP; private final ConcurrentHashMap dates_cache; private final ConcurrentHashMap account_age_cache; diff --git a/build.gradle.kts b/build.gradle.kts index fca26f9b1..58a3f8e25 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.2-SNAPSHOT" +version = "6.10.2" subprojects { group = rootProject.group From 4947450ff0d22467fbc4352eed6eec1ff51c690d Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Tue, 18 Oct 2022 23:14:03 +0200 Subject: [PATCH 084/111] Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 58a3f8e25..cdba97ad2 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.2" +version = "6.10.3-SNAPSHOT" subprojects { group = rootProject.group From c8d356783a9adcbebc22d177a57f861b0f1ab3c7 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Thu, 20 Oct 2022 10:23:56 +0200 Subject: [PATCH 085/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.17 (#3853) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index cdba97ad2..f3048865c 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.16")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.17")) } dependencies { From db2d590e8e9a3205f74edbc176155bac0027947a Mon Sep 17 00:00:00 2001 From: Jordan Date: Sun, 23 Oct 2022 20:22:21 +0100 Subject: [PATCH 086/111] fix: account for mismatched road-schematic heights (#3854) --- .../java/com/plotsquared/core/generator/HybridPlotWorld.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index 22b1a2f5e..6138f5325 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -298,7 +298,10 @@ public class HybridPlotWorld extends ClassicPlotWorld { int roadSchemHeight; if (schematic1 != null) { - roadSchemHeight = schematic1.getClipboard().getDimensions().getY(); + roadSchemHeight = Math.max( + schematic1.getClipboard().getDimensions().getY(), + schematic2.getClipboard().getDimensions().getY() + ); maxSchematicHeight = Math.max(roadSchemHeight, maxSchematicHeight); if (maxSchematicHeight == worldGenHeight) { SCHEM_Y = getMinGenHeight(); From 985fae65b65fb9f31be58cb7c8062e9d220e52ee Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 2 Nov 2022 09:34:33 +0100 Subject: [PATCH 087/111] =?UTF-8?q?=C3=82Release=206.10.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index f3048865c..ce15de8a2 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.3-SNAPSHOT" +version = "6.10.3" subprojects { group = rootProject.group From 8330f37d8ae427dc0edbaacfff6f1253cde0b236 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 2 Nov 2022 09:35:57 +0100 Subject: [PATCH 088/111] Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index ce15de8a2..db2909ea9 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.3" +version = "6.10.4-SNAPSHOT" subprojects { group = rootProject.group From 28bd9936804593ea7cd99d95cf3d797b864da83a Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sun, 6 Nov 2022 11:13:29 +0100 Subject: [PATCH 089/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.18 (#3864) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index db2909ea9..3348e357f 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.17")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.18")) } dependencies { From 55c8a590e75ab030eb57443a80086f6a51118bc4 Mon Sep 17 00:00:00 2001 From: Jordan Date: Sat, 12 Nov 2022 16:10:21 +0000 Subject: [PATCH 090/111] Fix item thrower/owner can be null (#3866) fix: item thrower/owner can be nuill - Fixes #3862 --- .../plotsquared/bukkit/listener/BlockEventListener117.java | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java index 2d23515ad..040bdc0d2 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java @@ -104,6 +104,12 @@ public class BlockEventListener117 implements Listener { if (entity instanceof Item item) { UUID itemThrower = item.getThrower(); if (plot != null) { + if (itemThrower == null && (itemThrower = item.getOwner()) == null) { + plot.debug( + "A thrown item couldn't trigger sculk sensors because misc-interact = false and the item's owner could not be resolved."); + event.setCancelled(true); + return; + } if (!plot.isAdded(itemThrower)) { if (!plot.isAdded(itemThrower)) { plot.debug("A thrown item couldn't trigger sculk sensors because misc-interact = false"); From 25ce7a83f134921c1fc2c69f5d92ecb23edf1761 Mon Sep 17 00:00:00 2001 From: Jordan Date: Sun, 13 Nov 2022 10:57:41 +0000 Subject: [PATCH 091/111] feat: check merge limits when completing auto-merge (#3868) - Closes #3748 --- Core/src/main/java/com/plotsquared/core/command/Auto.java | 8 ++++++++ .../src/main/java/com/plotsquared/core/command/Merge.java | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Auto.java b/Core/src/main/java/com/plotsquared/core/command/Auto.java index 60ed4bfea..8c428c56e 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Auto.java +++ b/Core/src/main/java/com/plotsquared/core/command/Auto.java @@ -142,6 +142,14 @@ public class Auto extends SubCommand { } } } + int maxMerge = Permissions.hasPermissionRange(player, Permission.PERMISSION_MERGE, Settings.Limit.MAX_PLOTS); + if (sizeX * sizeZ > maxMerge) { + player.sendMessage( + TranslatableCaption.of("permission.no_permission"), + Template.of("node", Permission.PERMISSION_MERGE + "." + (sizeX * sizeZ)) + ); + return false; + } return true; } diff --git a/Core/src/main/java/com/plotsquared/core/command/Merge.java b/Core/src/main/java/com/plotsquared/core/command/Merge.java index 8c9976197..d548e95a3 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Merge.java +++ b/Core/src/main/java/com/plotsquared/core/command/Merge.java @@ -124,7 +124,7 @@ public class Merge extends SubCommand { return false; } final int size = plot.getConnectedPlots().size(); - int max = Permissions.hasPermissionRange(player, "plots.merge", Settings.Limit.MAX_PLOTS); + int max = Permissions.hasPermissionRange(player, Permission.PERMISSION_MERGE, Settings.Limit.MAX_PLOTS); PlotMergeEvent event = this.eventDispatcher.callMerge(plot, direction, max, player); if (event.getEventResult() == Result.DENY) { From 52bb561689a13bbfe04cf52244455369976d6f41 Mon Sep 17 00:00:00 2001 From: Jordan Date: Mon, 14 Nov 2022 15:47:24 +0000 Subject: [PATCH 092/111] fix: attempt to recover from IllegalStateException when restoring block tags (#3838) - Fixes #3801 --- .../bukkit/queue/LimitedRegionWrapperQueue.java | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/LimitedRegionWrapperQueue.java b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/LimitedRegionWrapperQueue.java index d61372536..46161d4c4 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/queue/LimitedRegionWrapperQueue.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/queue/LimitedRegionWrapperQueue.java @@ -44,6 +44,7 @@ public class LimitedRegionWrapperQueue extends DelegateQueueCoordinator { private static final Logger LOGGER = LogManager.getLogger("PlotSquared/" + LimitedRegionWrapperQueue.class.getSimpleName()); private final LimitedRegion limitedRegion; + private boolean useOtherRestoreTagMethod = false; /** * @since 6.9.0 @@ -65,10 +66,18 @@ public class LimitedRegionWrapperQueue extends DelegateQueueCoordinator { CompoundTag tag = id.getNbtData(); StateWrapper sw = new StateWrapper(tag); try { - sw.restoreTag(limitedRegion.getBlockState(x, y, z).getBlock()); + if (useOtherRestoreTagMethod && getWorld() != null) { + sw.restoreTag(getWorld().getName(), x, y, z); + } else { + sw.restoreTag(limitedRegion.getBlockState(x, y, z).getBlock()); + } } catch (IllegalArgumentException e) { LOGGER.error("Error attempting to populate tile entity into the world at location {},{},{}", x, y, z, e); return false; + } catch (IllegalStateException e) { + useOtherRestoreTagMethod = true; + LOGGER.warn("IllegalStateException attempting to populate tile entity into the world at location {},{},{}. " + + "Possibly on <=1.17.1, switching to secondary method.", x, y, z, e); } } return result; From 2147012beb38a4dedb86aeca772cadd05f828329 Mon Sep 17 00:00:00 2001 From: Jordan Date: Mon, 14 Nov 2022 21:58:05 +0000 Subject: [PATCH 093/111] chore: deprecate paper 1.13 listener as P2 effectively doesn't support 1.13 (#3872) --- .../com/plotsquared/bukkit/listener/PaperListener113.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java index 722e58347..c7e1509c0 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java @@ -48,6 +48,10 @@ import org.bukkit.event.EventHandler; import org.bukkit.event.block.BlockPlaceEvent; import org.checkerframework.checker.nullness.qual.NonNull; +/** + * @deprecated P2 effectively no longer supports 1.13 + */ +@Deprecated(forRemoval = true, since = "TODO") public class PaperListener113 extends PaperListener { @Inject From b5bc1988e59ad5fcd53334c9243f5218363b38bd Mon Sep 17 00:00:00 2001 From: Jordan Date: Tue, 15 Nov 2022 18:07:38 +0000 Subject: [PATCH 094/111] feature: implement road flags as widely as seems reasonable (#3870) * feature: implement road flags as widely as seems reasonable - Closes #3047 - Any further road flag implementations would be very specific from what I can gather, and thus the gist of #3047 is now implemented * Add javadoc since tag Co-authored-by: Alexander Brandes * Create util class for method Co-authored-by: Alexander Brandes --- .../bukkit/listener/BlockEventListener.java | 13 +++-- .../listener/BlockEventListener117.java | 4 +- .../bukkit/listener/EntityEventListener.java | 3 +- .../bukkit/listener/PaperListener.java | 9 +++- .../bukkit/listener/PlayerEventListener.java | 51 +++++++++--------- .../listener/ProjectileEventListener.java | 17 ++++-- .../plotsquared/core/util/PlotFlagUtil.java | 53 +++++++++++++++++++ 7 files changed, 112 insertions(+), 38 deletions(-) create mode 100644 Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index a08097100..61365db8c 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -56,6 +56,7 @@ import com.plotsquared.core.plot.flag.types.BlockTypeWrapper; import com.plotsquared.core.plot.flag.types.BooleanFlag; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.util.Permissions; +import com.plotsquared.core.util.PlotFlagUtil; import com.plotsquared.core.util.task.TaskManager; import com.plotsquared.core.util.task.TaskTime; import com.sk89q.worldedit.WorldEdit; @@ -166,7 +167,7 @@ public class BlockEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && !area.getRoadFlag(RedstoneFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, RedstoneFlag.class, false)) { event.setNewCurrent(0); } return; @@ -1084,7 +1085,10 @@ public class BlockEventListener implements Listener { return; } if (plot == null) { - if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_ROAD)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, BlockIgnitionFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_BUILD_ROAD + )) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_BUILD_ROAD)) @@ -1092,7 +1096,10 @@ public class BlockEventListener implements Listener { event.setCancelled(true); } } else if (!plot.hasOwner()) { - if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_UNOWNED)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, BlockIgnitionFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_BUILD_UNOWNED + )) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_BUILD_UNOWNED)) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java index 040bdc0d2..d4b71a7b2 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener117.java @@ -26,6 +26,7 @@ import com.plotsquared.core.plot.Plot; import com.plotsquared.core.plot.PlotArea; import com.plotsquared.core.plot.flag.implementations.CopperOxideFlag; import com.plotsquared.core.plot.flag.implementations.MiscInteractFlag; +import com.plotsquared.core.util.PlotFlagUtil; import org.bukkit.Material; import org.bukkit.block.Block; import org.bukkit.entity.Entity; @@ -91,7 +92,8 @@ public class BlockEventListener117 implements Listener { } Plot plot = location.getOwnedPlot(); - if (plot == null || !plot.getFlag(MiscInteractFlag.class)) { + if (plot == null && !PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, MiscInteractFlag.class, true) || plot != null && !plot.getFlag( + MiscInteractFlag.class)) { if (plotPlayer != null) { if (plot != null) { if (!plot.isAdded(plotPlayer.getUUID())) { diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntityEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntityEventListener.java index bc28460e2..3e32a9816 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntityEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/EntityEventListener.java @@ -38,6 +38,7 @@ import com.plotsquared.core.plot.flag.implementations.InvincibleFlag; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.util.EventDispatcher; import com.plotsquared.core.util.Permissions; +import com.plotsquared.core.util.PlotFlagUtil; import com.sk89q.worldedit.bukkit.BukkitAdapter; import com.sk89q.worldedit.world.block.BlockType; import org.bukkit.Material; @@ -261,7 +262,7 @@ public class EntityEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && area.getRoadFlag(InvincibleFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, InvincibleFlag.class, true)) { event.setCancelled(true); } return; diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java index 54cc21a41..3ad3a6227 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener.java @@ -44,6 +44,7 @@ import com.plotsquared.core.plot.flag.implementations.ProjectilesFlag; import com.plotsquared.core.plot.flag.types.BooleanFlag; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.util.Permissions; +import com.plotsquared.core.util.PlotFlagUtil; import net.kyori.adventure.text.minimessage.Template; import org.bukkit.Chunk; import org.bukkit.block.Block; @@ -326,14 +327,18 @@ public class PaperListener implements Listener { return; } Location location = BukkitUtil.adapt(entity.getLocation()); - if (!this.plotAreaManager.hasPlotArea(location.getWorldName())) { + PlotArea area = location.getPlotArea(); + if (area == null) { return; } PlotPlayer pp = BukkitUtil.adapt((Player) shooter); Plot plot = location.getOwnedPlot(); if (plot == null) { - if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_PROJECTILE_ROAD)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, ProjectilesFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_PROJECTILE_ROAD + )) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_PROJECTILE_ROAD)) 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 ca7130deb..fbe26e676 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PlayerEventListener.java @@ -68,6 +68,7 @@ import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.util.EventDispatcher; import com.plotsquared.core.util.MathMan; import com.plotsquared.core.util.Permissions; +import com.plotsquared.core.util.PlotFlagUtil; import com.plotsquared.core.util.PremiumVerification; import com.plotsquared.core.util.entity.EntityCategories; import com.plotsquared.core.util.task.TaskManager; @@ -889,8 +890,7 @@ public class PlayerEventListener implements Listener { } } else { PlotArea area = pp.getPlotAreaAbs(); - if (area != null && area.isRoadFlags() && area - .getRoadFlag(PreventCreativeCopyFlag.class)) { + if (area != null && PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, PreventCreativeCopyFlag.class, true)) { final ItemStack newStack = new ItemStack(newItem.getType(), newItem.getAmount()); event.setCursor(newStack); @@ -998,8 +998,10 @@ public class PlayerEventListener implements Listener { Plot plot = location.getPlotAbs(); BukkitPlayer pp = BukkitUtil.adapt(e.getPlayer()); if (plot == null) { - if (!area.isRoadFlags() && !area.getRoadFlag(MiscInteractFlag.class) && !Permissions - .hasPermission(pp, Permission.PERMISSION_ADMIN_INTERACT_ROAD)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, MiscInteractFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_INTERACT_ROAD + )) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_INTERACT_ROAD)) @@ -1009,9 +1011,7 @@ public class PlayerEventListener implements Listener { } else { if (Settings.Done.RESTRICT_BUILDING && DoneFlag.isDone(plot)) { if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_BUILD_OTHER)) { - pp.sendMessage( - TranslatableCaption.of("done.building_restricted") - ); + pp.sendMessage(TranslatableCaption.of("done.building_restricted")); e.setCancelled(true); return; } @@ -1594,7 +1594,10 @@ public class PlayerEventListener implements Listener { BukkitPlayer pp = BukkitUtil.adapt(p); Plot plot = area.getPlot(location); if (plot == null) { - if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_DESTROY_VEHICLE_ROAD)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, VehicleBreakFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_DESTROY_VEHICLE_ROAD + )) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_DESTROY_VEHICLE_ROAD)) @@ -1642,7 +1645,7 @@ public class PlayerEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && !area.getRoadFlag(ItemDropFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, ItemDropFlag.class, false)) { event.setCancelled(true); } return; @@ -1668,7 +1671,7 @@ public class PlayerEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && area.getRoadFlag(DropProtectionFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, DropProtectionFlag.class, true)) { event.setCancelled(true); } return; @@ -1690,17 +1693,15 @@ public class PlayerEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && area.getRoadFlag(KeepInventoryFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, KeepInventoryFlag.class, true)) { event.setCancelled(true); } return; } if (plot.getFlag(KeepInventoryFlag.class)) { - if (plot.getFlag(KeepInventoryFlag.class)) { - plot.debug(event.getEntity().getName() + " kept their inventory because of keep-inventory = true"); - event.getDrops().clear(); - event.setKeepInventory(true); - } + plot.debug(event.getEntity().getName() + " kept their inventory because of keep-inventory = true"); + event.getDrops().clear(); + event.setKeepInventory(true); } } @@ -1725,16 +1726,14 @@ public class PlayerEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && area.getRoadFlag(DenyPortalTravelFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, DenyPortalTravelFlag.class, true)) { event.setCancelled(true); } return; } if (plot.getFlag(DenyPortalTravelFlag.class)) { - if (plot.getFlag(DenyPortalTravelFlag.class)) { - plot.debug(event.getPlayer().getName() + " did not travel thru a portal because of deny-portal-travel = true"); - event.setCancelled(true); - } + plot.debug(event.getPlayer().getName() + " did not travel thru a portal because of deny-portal-travel = true"); + event.setCancelled(true); } } @@ -1772,7 +1771,7 @@ public class PlayerEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && area.getRoadFlag(DenyPortalsFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, DenyPortalsFlag.class, true)) { event.setCancelled(true); return; } @@ -1801,16 +1800,14 @@ public class PlayerEventListener implements Listener { } Plot plot = location.getOwnedPlot(); if (plot == null) { - if (area.isRoadFlags() && area.getRoadFlag(LecternReadBookFlag.class)) { + if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, LecternReadBookFlag.class, true)) { event.setCancelled(true); } return; } if (plot.getFlag(LecternReadBookFlag.class)) { - if (plot.getFlag(LecternReadBookFlag.class)) { - plot.debug(event.getPlayer().getName() + " could not take the book because of lectern-read-book = true"); - event.setCancelled(true); - } + plot.debug(event.getPlayer().getName() + " could not take the book because of lectern-read-book = true"); + event.setCancelled(true); } } diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java index 743649a80..2703c8cd9 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/ProjectileEventListener.java @@ -31,6 +31,7 @@ import com.plotsquared.core.plot.PlotHandler; import com.plotsquared.core.plot.flag.implementations.ProjectilesFlag; import com.plotsquared.core.plot.world.PlotAreaManager; import com.plotsquared.core.util.Permissions; +import com.plotsquared.core.util.PlotFlagUtil; import net.kyori.adventure.text.minimessage.Template; import org.bukkit.entity.Entity; import org.bukkit.entity.LivingEntity; @@ -97,14 +98,18 @@ public class ProjectileEventListener implements Listener { return; } Location location = BukkitUtil.adapt(entity.getLocation()); - if (!this.plotAreaManager.hasPlotArea(location.getWorldName())) { + PlotArea area = location.getPlotArea(); + if (area == null) { return; } PlotPlayer pp = BukkitUtil.adapt((Player) shooter); Plot plot = location.getOwnedPlot(); if (plot == null) { - if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_PROJECTILE_ROAD)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, ProjectilesFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_PROJECTILE_ROAD + )) { pp.sendMessage( TranslatableCaption.of("permission.no_permission_event"), Template.of("node", String.valueOf(Permission.PERMISSION_ADMIN_PROJECTILE_ROAD)) @@ -154,6 +159,8 @@ public class ProjectileEventListener implements Listener { if (plot.isAdded(((Player) shooter).getUniqueId()) || plot.getFlag(ProjectilesFlag.class)) { return; } + } else if (PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, ProjectilesFlag.class, true)) { + return; } entity.remove(); @@ -163,7 +170,10 @@ public class ProjectileEventListener implements Listener { PlotPlayer pp = BukkitUtil.adapt((Player) shooter); if (plot == null) { - if (!Permissions.hasPermission(pp, Permission.PERMISSION_ADMIN_PROJECTILE_UNOWNED)) { + if (!PlotFlagUtil.isAreaRoadFlagsAndFlagEquals(area, ProjectilesFlag.class, true) && !Permissions.hasPermission( + pp, + Permission.PERMISSION_ADMIN_PROJECTILE_UNOWNED + )) { entity.remove(); event.setCancelled(true); } @@ -194,7 +204,6 @@ public class ProjectileEventListener implements Listener { if (sPlot == null || !PlotHandler.sameOwners(plot, sPlot)) { entity.remove(); event.setCancelled(true); - return; } } } diff --git a/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java b/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java new file mode 100644 index 000000000..c2eb2d596 --- /dev/null +++ b/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java @@ -0,0 +1,53 @@ +/* + * PlotSquared, a land and world management plugin for Minecraft. + * Copyright (C) IntellectualSites + * Copyright (C) IntellectualSites team and contributors + * + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +package com.plotsquared.core.util; + +import com.plotsquared.core.plot.PlotArea; +import com.plotsquared.core.plot.flag.PlotFlag; + +import java.util.Objects; + +/** + * Util class for generic methods relating to plot flags. + * + * @since TODO + */ +public final class PlotFlagUtil { + + private PlotFlagUtil() { + //No-op + } + + /** + * Check if the value of a {@link PlotFlag} matches the given value. If + * road flags are disabled for the given plot area, returns false. + * + * @param flagClass boolean flag to get value of + * @param value boolean value to check flag value against + * @param The flag value type + * @return true if road flag value matches with road flags enabled + * @since TODO + */ + public static boolean isAreaRoadFlagsAndFlagEquals( + PlotArea area, final Class> flagClass, T value + ) { + return area.isRoadFlags() && Objects.equals(area.getRoadFlag(flagClass), value); + } + +} From ee8902154a6fc3a2e5204e5374f70e7def87a9fb Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 16 Nov 2022 11:26:03 +0100 Subject: [PATCH 095/111] Release 6.10.4 --- .../com/plotsquared/bukkit/listener/PaperListener113.java | 2 +- .../src/main/java/com/plotsquared/core/util/PlotFlagUtil.java | 4 ++-- build.gradle.kts | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java index c7e1509c0..635f736e7 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/PaperListener113.java @@ -51,7 +51,7 @@ import org.checkerframework.checker.nullness.qual.NonNull; /** * @deprecated P2 effectively no longer supports 1.13 */ -@Deprecated(forRemoval = true, since = "TODO") +@Deprecated(forRemoval = true, since = "6.10.4") public class PaperListener113 extends PaperListener { @Inject diff --git a/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java b/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java index c2eb2d596..d66339336 100644 --- a/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java +++ b/Core/src/main/java/com/plotsquared/core/util/PlotFlagUtil.java @@ -26,7 +26,7 @@ import java.util.Objects; /** * Util class for generic methods relating to plot flags. * - * @since TODO + * @since 6.10.4 */ public final class PlotFlagUtil { @@ -42,7 +42,7 @@ public final class PlotFlagUtil { * @param value boolean value to check flag value against * @param The flag value type * @return true if road flag value matches with road flags enabled - * @since TODO + * @since 6.10.4 */ public static boolean isAreaRoadFlagsAndFlagEquals( PlotArea area, final Class> flagClass, T value diff --git a/build.gradle.kts b/build.gradle.kts index 3348e357f..0ea06ea24 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.4-SNAPSHOT" +version = "6.10.4" subprojects { group = rootProject.group From 11906ef1c9b7d7e8de8b32624bc250d19cf0d662 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Wed, 16 Nov 2022 11:30:23 +0100 Subject: [PATCH 096/111] Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 0ea06ea24..d560ac9f3 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.4" +version = "6.10.5-SNAPSHOT" subprojects { group = rootProject.group From 6baf339ecbf1ab58a5109faa95f013a7c5d3a6d0 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 16 Nov 2022 18:35:03 +0100 Subject: [PATCH 097/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.19 (#3874) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index d560ac9f3..19abc5844 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.18")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.19")) } dependencies { From c1543f034ce98e6d12cff8f8bae05016ba0d9865 Mon Sep 17 00:00:00 2001 From: Jordan Date: Thu, 17 Nov 2022 17:23:44 +0000 Subject: [PATCH 098/111] feat: improve handling of null issues in plot analysis (#3867) --- .../core/generator/HybridUtils.java | 78 ++++++++++--------- 1 file changed, 43 insertions(+), 35 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java b/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java index cc00345bd..0def7d9cb 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridUtils.java @@ -234,44 +234,52 @@ public class HybridUtils { Set types = new HashSet<>(); for (int yIndex = 0; yIndex < height; yIndex++) { BlockState old = oldBlocks[yIndex][x][z]; // Nullable - try { - BlockState now = newBlocks[yIndex][x][z]; // Not null - if (!now.equals(old) && !(old == null && now.getBlockType().equals(BlockTypes.AIR))) { - changes[i]++; - } - if (now.getBlockType().getMaterial().isAir()) { - air[i]++; - } else { - // check vertices - // modifications_adjacent - if (x > 0 && z > 0 && yIndex > 0 && x < width - 1 && z < length - 1 && yIndex < (height - 1)) { - if (newBlocks[yIndex - 1][x][z].getBlockType().getMaterial().isAir()) { - faces[i]++; - } - if (newBlocks[yIndex][x - 1][z].getBlockType().getMaterial().isAir()) { - faces[i]++; - } - if (newBlocks[yIndex][x][z - 1].getBlockType().getMaterial().isAir()) { - faces[i]++; - } - if (newBlocks[yIndex + 1][x][z].getBlockType().getMaterial().isAir()) { - faces[i]++; - } - if (newBlocks[yIndex][x + 1][z].getBlockType().getMaterial().isAir()) { - faces[i]++; - } - if (newBlocks[yIndex][x][z + 1].getBlockType().getMaterial().isAir()) { - faces[i]++; - } + BlockState now = newBlocks[yIndex][x][z]; // Not null + if (now == null) { + throw new NullPointerException(String.format( + "\"now\" block null attempting to perform plot analysis. Indexes: x=%d of %d, yIndex=%d" + + " of %d, z=%d of %d", + x, + width, + yIndex, + height, + z, + length + )); + } + if (!now.equals(old) && !(old == null && now.getBlockType().equals(BlockTypes.AIR))) { + changes[i]++; + } + if (now.getBlockType().getMaterial().isAir()) { + air[i]++; + } else { + // check vertices + // modifications_adjacent + if (x > 0 && z > 0 && yIndex > 0 && x < width - 1 && z < length - 1 && yIndex < (height - 1)) { + if (newBlocks[yIndex - 1][x][z].getBlockType().getMaterial().isAir()) { + faces[i]++; } + if (newBlocks[yIndex][x - 1][z].getBlockType().getMaterial().isAir()) { + faces[i]++; + } + if (newBlocks[yIndex][x][z - 1].getBlockType().getMaterial().isAir()) { + faces[i]++; + } + if (newBlocks[yIndex + 1][x][z].getBlockType().getMaterial().isAir()) { + faces[i]++; + } + if (newBlocks[yIndex][x + 1][z].getBlockType().getMaterial().isAir()) { + faces[i]++; + } + if (newBlocks[yIndex][x][z + 1].getBlockType().getMaterial().isAir()) { + faces[i]++; + } + } - if (!now.equals(now.getBlockType().getDefaultState())) { - data[i]++; - } - types.add(now.getBlockType()); + if (!now.equals(now.getBlockType().getDefaultState())) { + data[i]++; } - } catch (NullPointerException e) { - e.printStackTrace(); + types.add(now.getBlockType()); } } variety[i] = types.size(); From c973ee8649939d4a31cbe513486a5392b8bf48ab Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Sun, 20 Nov 2022 10:58:04 +0100 Subject: [PATCH 099/111] Revert "feat: check merge limits when completing auto-merge (#3868)" - Fixes a bug in 6.10.4 (#3876) Revert "feat: check merge limits when completing auto-merge (#3868)" This reverts commit 25ce7a83f134921c1fc2c69f5d92ecb23edf1761. --- Core/src/main/java/com/plotsquared/core/command/Auto.java | 8 -------- .../src/main/java/com/plotsquared/core/command/Merge.java | 2 +- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Auto.java b/Core/src/main/java/com/plotsquared/core/command/Auto.java index 8c428c56e..60ed4bfea 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Auto.java +++ b/Core/src/main/java/com/plotsquared/core/command/Auto.java @@ -142,14 +142,6 @@ public class Auto extends SubCommand { } } } - int maxMerge = Permissions.hasPermissionRange(player, Permission.PERMISSION_MERGE, Settings.Limit.MAX_PLOTS); - if (sizeX * sizeZ > maxMerge) { - player.sendMessage( - TranslatableCaption.of("permission.no_permission"), - Template.of("node", Permission.PERMISSION_MERGE + "." + (sizeX * sizeZ)) - ); - return false; - } return true; } diff --git a/Core/src/main/java/com/plotsquared/core/command/Merge.java b/Core/src/main/java/com/plotsquared/core/command/Merge.java index d548e95a3..8c9976197 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Merge.java +++ b/Core/src/main/java/com/plotsquared/core/command/Merge.java @@ -124,7 +124,7 @@ public class Merge extends SubCommand { return false; } final int size = plot.getConnectedPlots().size(); - int max = Permissions.hasPermissionRange(player, Permission.PERMISSION_MERGE, Settings.Limit.MAX_PLOTS); + int max = Permissions.hasPermissionRange(player, "plots.merge", Settings.Limit.MAX_PLOTS); PlotMergeEvent event = this.eventDispatcher.callMerge(plot, direction, max, player); if (event.getEventResult() == Result.DENY) { From 90ebd5d5ed1db0cb5d509b230bc64075df82642c Mon Sep 17 00:00:00 2001 From: Jordan Date: Fri, 25 Nov 2022 10:48:33 +0000 Subject: [PATCH 100/111] feat: add a permission to override-allow a merge if the other plot's owner is offline (#3844) --- .../com/plotsquared/core/command/Merge.java | 23 ++++++++++++++++++- .../core/permissions/Permission.java | 1 + 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/Core/src/main/java/com/plotsquared/core/command/Merge.java b/Core/src/main/java/com/plotsquared/core/command/Merge.java index 8c9976197..6da21063b 100644 --- a/Core/src/main/java/com/plotsquared/core/command/Merge.java +++ b/Core/src/main/java/com/plotsquared/core/command/Merge.java @@ -282,7 +282,28 @@ public class Merge extends SubCommand { run.run(); } } - if (!force && !isOnline) { + if (force || !isOnline) { + if (force || Permissions.hasPermission(player, Permission.PERMISSION_ADMIN_COMMAND_MERGE_OTHER_OFFLINE)) { + if (plot.getPlotModificationManager().autoMerge(direction, maxSize - size, uuids.iterator().next(), player, terrain)) { + if (this.econHandler.isEnabled(plotArea) && price > 0d) { + if (!force && this.econHandler.getMoney(player) < price) { + player.sendMessage( + TranslatableCaption.of("economy.cannot_afford_merge"), + Template.of("money", this.econHandler.format(price)) + ); + return false; + } + this.econHandler.withdrawMoney(player, price); + player.sendMessage( + TranslatableCaption.of("economy.removed_balance"), + Template.of("money", this.econHandler.format(price)) + ); + } + player.sendMessage(TranslatableCaption.of("merge.success_merge")); + eventDispatcher.callPostMerge(player, plot); + return true; + } + } player.sendMessage(TranslatableCaption.of("merge.no_available_automerge")); return false; } diff --git a/Core/src/main/java/com/plotsquared/core/permissions/Permission.java b/Core/src/main/java/com/plotsquared/core/permissions/Permission.java index ffd8f3d5a..8899f233d 100644 --- a/Core/src/main/java/com/plotsquared/core/permissions/Permission.java +++ b/Core/src/main/java/com/plotsquared/core/permissions/Permission.java @@ -162,6 +162,7 @@ public enum Permission { PERMISSION_LIST_AREA("plots.list.area"), PERMISSION_ADMIN_COMMAND_LOAD("plots.admin.command.load"), PERMISSION_ADMIN_COMMAND_MERGE("plots.admin.command.merge"), + PERMISSION_ADMIN_COMMAND_MERGE_OTHER_OFFLINE("plots.admin.command.merge.other.offline"), PERMISSION_ADMIN_COMMAND_SET_OWNER("plots.admin.command.setowner"), PERMISSION_COMMENT("plots.comment"), PERMISSION_INBOX("plots.inbox"), From e6338976dde63045275d8e464314ce9e0dc89092 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Fri, 25 Nov 2022 19:20:37 +0100 Subject: [PATCH 101/111] Update dependency gradle to v7.6 (#3880) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/wrapper/gradle-wrapper.jar | Bin 60756 -> 61574 bytes gradle/wrapper/gradle-wrapper.properties | 3 ++- gradlew | 12 ++++++++---- gradlew.bat | 1 + 4 files changed, 11 insertions(+), 5 deletions(-) diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar index 249e5832f090a2944b7473328c07c9755baa3196..943f0cbfa754578e88a3dae77fce6e3dea56edbf 100644 GIT binary patch delta 36524 zcmZ6yQ*&aJ*i+pKn$=zKxk7ICNNX(G9gnUwow3iT2Ov?s|4Q$^qH|&1~>6K_f6Q@z)!W6o~05E1}7HS1}Bv=ef%?3Rc##Sb1)XzucCDxr#(Nfxotv ze%V_W`66|_=BK{+dN$WOZ#V$@kI(=7e7*Y3BMEum`h#%BJi{7P9=hz5ij2k_KbUm( zhz-iBt4RTzAPma)PhcHhjxYjxR6q^N4p+V6h&tZxbs!p4m8noJ?|i)9ATc@)IUzb~ zw2p)KDi7toTFgE%JA2d_9aWv7{xD{EzTGPb{V6+C=+O-u@I~*@9Q;(P9sE>h-v@&g ztSnY;?gI0q;XWPTrOm!4!5|uwJYJVPNluyu5}^SCc1ns-U#GrGqZ1B#qCcJbqoMAc zF$xB#F!(F?RcUqZtueR`*#i7DQ2CF?hhYV&goK!o`U?+H{F-15he}`xQ!)+H>0!QM z`)D&7s@{0}iVkz$(t{mqBKP?~W4b@KcuDglktFy&<2_z)F8Q~73;QcP`+pO=L}4yjlzNuLzuvnVAO``skBd=rV%VWQTd0x6_%ddY*G(AJt06`GHq zJVxl`G*RiYAeT=`Cf(SUN$kUE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0KD{zrLi>YiGD?tplqwb^^?5^R zVQ^cR0OXiN=z=hi7TJuLFi2sdpeA8(lc@(S34_Zb8UWQ#grZQ0DFe2NZ9rT!i0zk! zwn=~iWf;)=cS6mQY*T(f2O?tGW*=4r$j+g`R~RjV6cDkW!pHy^3F1NffE2tc{%(%w zm(Y>*=>0|@ZDFM2IyNYEkQZzoB*3dO*7?XAjS|Aeqrm}OQTPSK!EEhdBwMI3qF%)T z`iN(P<_0(OvUNm(!Vm^BMgFiTn*z!Z8s^Y=qOh!OD>@{%cx%@^TZDAx?4|M410{SqTm#yXk zaz`+b=5}`aRS}nw5iBoT5F>pQ18p_@)vqMSmLEVitr{UQQs>C103t_s%W)9UbHqcy zz^Dz(!8^|pFEd3p00#ocNRWUdU^yy-mN6oPaYsxXkQvwF(gFL&y&zFP&x%v8 z2tZGupne~qFrm+d22K+yavbDi921x!@l`4^Z79|cbezQi6w3rkKKaX(1QZqt`Vs=} zvov82nkJ4U-Ju9x9${_LgxOpx$k8~DoS$tRAir=BIB5d^p>tTXMv((>^gNPf9hjRW zL5-KeK)MDvjhubYDOspG4Ma}4K=d2zWm$0{aynBxpr|aiYcstb{1^|PEdhwm5+T3ZU#=){oFze(jcj+Sc^#n7qTxTE3w{>*{h6KdY89A1M}#@vzJ3Fc VwlMN}`%er%aGR6olj~j${vQ;P=LY}) diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index ae04661ee..f398c33c4 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip +networkTimeout=10000 zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew index a69d9cb6c..65dcd68d6 100755 --- a/gradlew +++ b/gradlew @@ -55,7 +55,7 @@ # Darwin, MinGW, and NonStop. # # (3) This script is generated from the Groovy template -# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt +# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt # within the Gradle project. # # You can find Gradle at https://github.com/gradle/gradle/. @@ -80,10 +80,10 @@ do esac done -APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit - -APP_NAME="Gradle" +# This is normally unused +# shellcheck disable=SC2034 APP_BASE_NAME=${0##*/} +APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' @@ -143,12 +143,16 @@ fi if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then case $MAX_FD in #( max*) + # In POSIX sh, ulimit -H is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 MAX_FD=$( ulimit -H -n ) || warn "Could not query maximum file descriptor limit" esac case $MAX_FD in #( '' | soft) :;; #( *) + # In POSIX sh, ulimit -n is undefined. That's why the result is checked to see if it worked. + # shellcheck disable=SC3045 ulimit -n "$MAX_FD" || warn "Could not set maximum file descriptor limit to $MAX_FD" esac diff --git a/gradlew.bat b/gradlew.bat index 53a6b238d..6689b85be 100644 --- a/gradlew.bat +++ b/gradlew.bat @@ -26,6 +26,7 @@ if "%OS%"=="Windows_NT" setlocal set DIRNAME=%~dp0 if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused set APP_BASE_NAME=%~n0 set APP_HOME=%DIRNAME% From 2067cc16707620220b2eacbeb1f660f7102582ce Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 28 Nov 2022 11:18:06 +0100 Subject: [PATCH 102/111] Release 6.10.5 --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 19abc5844..9ad6a73dd 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.5-SNAPSHOT" +version = "6.10.5" subprojects { group = rootProject.group From 70cb1cd1009f8658b69663e0ca0fa69ea88f3365 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Mon, 28 Nov 2022 11:18:56 +0100 Subject: [PATCH 103/111] Back to snapshot for development --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 9ad6a73dd..47c069ced 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -19,7 +19,7 @@ plugins { } group = "com.plotsquared" -version = "6.10.5" +version = "6.10.6-SNAPSHOT" subprojects { group = rootProject.group From 3a8fae47a00e6fa0bfdc50e93190c9f8b2606626 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 28 Nov 2022 15:23:44 +0100 Subject: [PATCH 104/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.20 (#3882) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 47c069ced..4b1db113d 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.19")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.20")) } dependencies { From f3bc504a6fdc78f11d05e1d2e8146ba9319a1d20 Mon Sep 17 00:00:00 2001 From: Jordan Date: Fri, 2 Dec 2022 12:39:38 +0000 Subject: [PATCH 105/111] refactor: adjust specific Nullable annotations used (#3869) --- .../bukkit/generator/LegacyBlockStatePopulator.java | 3 +-- .../bukkit/util/fawe/FaweRegionManager.java | 12 ++++-------- .../bukkit/util/fawe/FaweSchematicHandler.java | 6 +++--- .../configuration/caption/ClickStripTransform.java | 5 ++--- .../plotsquared/core/generator/HybridPlotWorld.java | 6 +++--- .../java/com/plotsquared/core/plot/PlotTitle.java | 3 ++- 6 files changed, 15 insertions(+), 20 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/generator/LegacyBlockStatePopulator.java b/Bukkit/src/main/java/com/plotsquared/bukkit/generator/LegacyBlockStatePopulator.java index eb8ad0201..d9482c5f2 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/generator/LegacyBlockStatePopulator.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/generator/LegacyBlockStatePopulator.java @@ -33,7 +33,6 @@ import org.bukkit.Chunk; import org.bukkit.World; import org.bukkit.generator.BlockPopulator; import org.checkerframework.checker.nullness.qual.NonNull; -import org.jetbrains.annotations.NotNull; import java.util.Random; @@ -51,7 +50,7 @@ final class LegacyBlockStatePopulator extends BlockPopulator { } @Override - public void populate(@NotNull final World world, @NotNull final Random random, @NotNull final Chunk source) { + public void populate(@NonNull final World world, @NonNull final Random random, @NonNull final Chunk source) { int chunkMinX = source.getX() << 4; int chunkMinZ = source.getZ() << 4; PlotArea area = Location.at(world.getName(), chunkMinX, 0, chunkMinZ).getPlotArea(); diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweRegionManager.java b/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweRegionManager.java index 1751710bb..0272a49e4 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweRegionManager.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweRegionManager.java @@ -36,8 +36,7 @@ import com.sk89q.worldedit.function.pattern.Pattern; import com.sk89q.worldedit.regions.CuboidRegion; import com.sk89q.worldedit.world.biome.BiomeType; import org.checkerframework.checker.nullness.qual.NonNull; -import org.jetbrains.annotations.NotNull; -import org.jetbrains.annotations.Nullable; +import org.checkerframework.checker.nullness.qual.Nullable; import java.util.Set; @@ -46,10 +45,7 @@ public class FaweRegionManager extends BukkitRegionManager { private final FaweDelegateRegionManager delegate = new FaweDelegateRegionManager(); @Inject - public FaweRegionManager( - @NonNull WorldUtil worldUtil, @NonNull GlobalBlockQueue blockQueue, @NonNull - ProgressSubscriberFactory subscriberFactory - ) { + public FaweRegionManager(WorldUtil worldUtil, GlobalBlockQueue blockQueue, ProgressSubscriberFactory subscriberFactory) { super(worldUtil, blockQueue, subscriberFactory); } @@ -76,9 +72,9 @@ public class FaweRegionManager extends BukkitRegionManager { @Override public boolean handleClear( - @NotNull Plot plot, + @NonNull Plot plot, @Nullable Runnable whenDone, - @NotNull PlotManager manager, + @NonNull PlotManager manager, final @Nullable PlotPlayer player ) { if (!Settings.FAWE_Components.CLEAR || !(manager instanceof HybridPlotManager)) { diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweSchematicHandler.java b/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweSchematicHandler.java index 9b909439a..c1b2bbd7e 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweSchematicHandler.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/util/fawe/FaweSchematicHandler.java @@ -29,7 +29,7 @@ import com.plotsquared.core.util.SchematicHandler; import com.plotsquared.core.util.WorldUtil; import com.plotsquared.core.util.task.RunnableVal; import com.sk89q.jnbt.CompoundTag; -import org.jetbrains.annotations.NotNull; +import org.checkerframework.checker.nullness.qual.NonNull; import java.io.InputStream; import java.net.URL; @@ -40,7 +40,7 @@ public class FaweSchematicHandler extends SchematicHandler { private final FaweDelegateSchematicHandler delegate = new FaweDelegateSchematicHandler(); @Inject - public FaweSchematicHandler(@NotNull WorldUtil worldUtil, @NotNull ProgressSubscriberFactory subscriberFactory) { + public FaweSchematicHandler(WorldUtil worldUtil, ProgressSubscriberFactory subscriberFactory) { super(worldUtil, subscriberFactory); } @@ -75,7 +75,7 @@ public class FaweSchematicHandler extends SchematicHandler { } @Override - public Schematic getSchematic(@NotNull InputStream is) { + public Schematic getSchematic(@NonNull InputStream is) { return delegate.getSchematic(is); } diff --git a/Core/src/main/java/com/plotsquared/core/configuration/caption/ClickStripTransform.java b/Core/src/main/java/com/plotsquared/core/configuration/caption/ClickStripTransform.java index 470f1b914..2ebdf2c87 100644 --- a/Core/src/main/java/com/plotsquared/core/configuration/caption/ClickStripTransform.java +++ b/Core/src/main/java/com/plotsquared/core/configuration/caption/ClickStripTransform.java @@ -21,16 +21,15 @@ package com.plotsquared.core.configuration.caption; import net.kyori.adventure.text.Component; import net.kyori.adventure.text.event.ClickEvent; import org.checkerframework.checker.nullness.qual.NonNull; -import org.jetbrains.annotations.NotNull; import java.util.EnumSet; import java.util.Set; final class ClickStripTransform implements ComponentTransform { - private final Set actionsToStrip; + private final Set actionsToStrip; - public ClickStripTransform(final Set actionsToStrip) { + public ClickStripTransform(final Set actionsToStrip) { this.actionsToStrip = EnumSet.copyOf(actionsToStrip); } diff --git a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java index 6138f5325..532cc691a 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java +++ b/Core/src/main/java/com/plotsquared/core/generator/HybridPlotWorld.java @@ -93,10 +93,10 @@ public class HybridPlotWorld extends ClassicPlotWorld { @Inject public HybridPlotWorld( @Assisted("world") final String worldName, - @Nullable @Assisted("id") final String id, + @javax.annotation.Nullable @Assisted("id") final String id, @Assisted final @NonNull IndependentPlotGenerator generator, - @Nullable @Assisted("min") final PlotId min, - @Nullable @Assisted("max") final PlotId max, + @javax.annotation.Nullable @Assisted("min") final PlotId min, + @javax.annotation.Nullable @Assisted("max") final PlotId max, @WorldConfig final @NonNull YamlConfiguration worldConfiguration, final @NonNull GlobalBlockQueue blockQueue ) { diff --git a/Core/src/main/java/com/plotsquared/core/plot/PlotTitle.java b/Core/src/main/java/com/plotsquared/core/plot/PlotTitle.java index 58ec05999..fe4302d0b 100644 --- a/Core/src/main/java/com/plotsquared/core/plot/PlotTitle.java +++ b/Core/src/main/java/com/plotsquared/core/plot/PlotTitle.java @@ -18,7 +18,8 @@ */ package com.plotsquared.core.plot; -import javax.annotation.Nullable; +import org.checkerframework.checker.nullness.qual.Nullable; + import java.util.Objects; public class PlotTitle { From 15e63378a73068b943cfa65d24667ccfd8a43e02 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Sun, 11 Dec 2022 08:39:32 +0100 Subject: [PATCH 106/111] Update worldedit to v7.2.13 (#3889) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 2bfdb818a..4fabf3d9d 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -4,7 +4,7 @@ guice = "5.1.0" spotbugs = "4.7.3" # Plugins -worldedit = "7.2.12" +worldedit = "7.2.13" placeholderapi = "2.11.2" luckperms = "5.4" essentialsx = "2.19.7" From ea1f35b45a26c91c139059ab23be7dce2f34fcda Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 13 Dec 2022 22:44:29 +0100 Subject: [PATCH 107/111] Update dependency cloud.commandframework:cloud-services to v1.8.0 (#3891) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 4fabf3d9d..652758547 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -13,7 +13,7 @@ mvdwapi = "3.1.1" # Third party prtree = "2.0.0" aopalliance = "1.0" -cloud-services = "1.7.1" +cloud-services = "1.8.0" arkitektonika = "2.1.1" squirrelid = "0.3.1" http4j = "1.3" From 2a40a6b35ecafb0eccd5277998cf4496f0d6ba8f Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Tue, 13 Dec 2022 22:45:51 +0100 Subject: [PATCH 108/111] Update dependency com.intellectualsites.bom:bom-1.18.x to v1.21 (#3890) Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> --- build.gradle.kts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle.kts b/build.gradle.kts index 4b1db113d..810e2be6e 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -65,7 +65,7 @@ subprojects { } dependencies { - implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.20")) + implementation(platform("com.intellectualsites.bom:bom-1.18.x:1.21")) } dependencies { From 120bf371963b27daab21aff35be5e4885a6f7568 Mon Sep 17 00:00:00 2001 From: Hraponssi Date: Fri, 23 Dec 2022 11:08:38 +0200 Subject: [PATCH 109/111] Fix dispensers loading Legacy Material Support (#3894) Fixes https://github.com/IntellectualSites/PlotSquared/issues/3883 --- .../plotsquared/bukkit/listener/BlockEventListener.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java index 61365db8c..dded70e62 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -71,6 +71,7 @@ import org.bukkit.block.Block; import org.bukkit.block.BlockFace; import org.bukkit.block.BlockState; import org.bukkit.block.data.BlockData; +import org.bukkit.block.data.type.Dispenser; import org.bukkit.entity.Entity; import org.bukkit.entity.Fireball; import org.bukkit.entity.Player; @@ -100,7 +101,6 @@ import org.bukkit.event.block.EntityBlockFormEvent; import org.bukkit.event.block.LeavesDecayEvent; import org.bukkit.event.block.SpongeAbsorbEvent; import org.bukkit.event.world.StructureGrowEvent; -import org.bukkit.material.Directional; import org.bukkit.projectiles.BlockProjectileSource; import org.bukkit.util.Vector; import org.checkerframework.checker.nullness.qual.NonNull; @@ -926,6 +926,9 @@ public class BlockEventListener implements Listener { @EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void onBlockDispense(BlockDispenseEvent event) { + if (!this.plotAreaManager.hasPlotArea(event.getBlock().getWorld().getName())) { + return; + } Material type = event.getItem().getType(); switch (type.toString()) { case "SHULKER_BOX", "WHITE_SHULKER_BOX", "ORANGE_SHULKER_BOX", "MAGENTA_SHULKER_BOX", "LIGHT_BLUE_SHULKER_BOX", @@ -937,7 +940,7 @@ public class BlockEventListener implements Listener { if (event.getBlock().getType() == Material.DROPPER) { return; } - BlockFace targetFace = ((Directional) event.getBlock().getState().getData()).getFacing(); + BlockFace targetFace = ((Dispenser) event.getBlock().getBlockData()).getFacing(); Location location = BukkitUtil.adapt(event.getBlock().getRelative(targetFace).getLocation()); if (location.isPlotRoad()) { event.setCancelled(true); From 742d78a505455dc8fca0ecea83dd629b8f6682f0 Mon Sep 17 00:00:00 2001 From: Alexander Brandes Date: Fri, 23 Dec 2022 13:41:58 +0100 Subject: [PATCH 110/111] Add 1.19.3 to the issue template --- .github/ISSUE_TEMPLATE/bug_report.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/ISSUE_TEMPLATE/bug_report.yml b/.github/ISSUE_TEMPLATE/bug_report.yml index 3067cc238..ddc9a2a87 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.yml +++ b/.github/ISSUE_TEMPLATE/bug_report.yml @@ -27,6 +27,7 @@ body: description: Which server version version you using? If your server version is not listed, it is not supported. Update to a supported version first. multiple: false options: + - '1.19.3' - '1.19.2' - '1.19.1' - '1.19' From 339ca8e30fda26f2f1fa2522d692872cd02ad701 Mon Sep 17 00:00:00 2001 From: Hannes Greule Date: Wed, 4 Jan 2023 12:35:12 +0100 Subject: [PATCH 111/111] Fix wrong plot id calculation for negative coordinates (#3898) --- .../core/generator/SquarePlotManager.java | 46 ++++--------------- 1 file changed, 10 insertions(+), 36 deletions(-) diff --git a/Core/src/main/java/com/plotsquared/core/generator/SquarePlotManager.java b/Core/src/main/java/com/plotsquared/core/generator/SquarePlotManager.java index 205ee06ad..6ca53e2cd 100644 --- a/Core/src/main/java/com/plotsquared/core/generator/SquarePlotManager.java +++ b/Core/src/main/java/com/plotsquared/core/generator/SquarePlotManager.java @@ -114,26 +114,14 @@ public abstract class SquarePlotManager extends GridPlotManager { end = pathWidthLower + squarePlotWorld.PLOT_WIDTH; } int size = squarePlotWorld.PLOT_WIDTH + squarePlotWorld.ROAD_WIDTH; - int idx; - if (x < 0) { - idx = x / size; - x = size + (x % size); - } else { - idx = (x / size) + 1; - x = x % size; - } - int idz; - if (z < 0) { - idz = z / size; - z = size + (z % size); - } else { - idz = (z / size) + 1; - z = z % size; - } - if (z <= pathWidthLower || z > end || x <= pathWidthLower || x > end) { + int dx = Math.floorDiv(x, size) + 1; + int rx = Math.floorMod(x, size); + int dz = Math.floorDiv(z, size) + 1; + int rz = Math.floorMod(z, size); + if (rz <= pathWidthLower || rz > end || rx <= pathWidthLower || rx > end) { return null; } else { - return PlotId.of(idx, idz); + return PlotId.of(dx, dz); } } @@ -180,24 +168,10 @@ public abstract class SquarePlotManager extends GridPlotManager { } end = pathWidthLower + squarePlotWorld.PLOT_WIDTH; } - int dx; - int rx; - if (x < 0) { - dx = x / size; - rx = size + (x % size); - } else { - dx = (x / size) + 1; - rx = x % size; - } - int dz; - int rz; - if (z < 0) { - dz = z / size; - rz = size + (z % size); - } else { - dz = (z / size) + 1; - rz = z % size; - } + int dx = Math.floorDiv(x, size) + 1; + int rx = Math.floorMod(x, size); + int dz = Math.floorDiv(z, size) + 1; + int rz = Math.floorMod(z, size); PlotId id = PlotId.of(dx, dz); boolean[] merged = new boolean[]{rz <= pathWidthLower, rx > end, rz > end, rx <= pathWidthLower}; int hash = HashUtil.hash(merged);