diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/listeners/PlayerEvents.java b/Bukkit/src/main/java/com/plotsquared/bukkit/listeners/PlayerEvents.java index ec553699a..ba5ac0a61 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listeners/PlayerEvents.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listeners/PlayerEvents.java @@ -898,8 +898,19 @@ public class PlayerEvents extends PlotListener implements Listener { if (plot != null) { if (Flags.DISABLE_PHYSICS.isFalse(plot)) { event.setCancelled(true); + return; } else if (!area.contains(fLocation.getX(), fLocation.getZ()) || !Objects.equals(plot, area.getOwnedPlot(fLocation))) { event.setCancelled(true); + return; + } + if (Flags.LIQUID_FLOW.isFalse(plot)) { + switch (to.getType()) { + case WATER: + case STATIONARY_WATER: + case LAVA: + case STATIONARY_LAVA: + event.setCancelled(true); + } } } else if (!area.contains(fLocation.getX(), fLocation.getZ()) || !Objects.equals(plot, area.getOwnedPlot(fLocation))) { event.setCancelled(true); diff --git a/Core/src/main/java/com/intellectualcrafters/plot/flag/Flags.java b/Core/src/main/java/com/intellectualcrafters/plot/flag/Flags.java index 1b86ff8f8..f107152f4 100644 --- a/Core/src/main/java/com/intellectualcrafters/plot/flag/Flags.java +++ b/Core/src/main/java/com/intellectualcrafters/plot/flag/Flags.java @@ -47,6 +47,7 @@ public final class Flags { public static final BooleanFlag VINE_GROW = new BooleanFlag("vine-grow"); public static final BooleanFlag MYCEL_GROW = new BooleanFlag("mycel-grow"); public static final BooleanFlag DISABLE_PHYSICS = new BooleanFlag("disable-physics"); + public static final BooleanFlag LIQUID_FLOW = new BooleanFlag("liquid-flow"); public static final BooleanFlag SNOW_MELT = new BooleanFlag("snow-melt"); public static final BooleanFlag ICE_MELT = new BooleanFlag("ice-melt"); public static final BooleanFlag FIRE_SPREAD = new BooleanFlag("fire-spread");