From ab121c7eee9bd194328b0aea11577136445c26ae Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Sun, 26 Jul 2020 21:12:32 +0200 Subject: [PATCH] Fixes https://github.com/IntellectualSites/PlotSquaredSuggestions/issues/133 --- .../bukkit/listener/BlockEventListener.java | 12 +++++++----- 1 file changed, 7 insertions(+), 5 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 32408f41e..fcd5d6951 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/listener/BlockEventListener.java @@ -425,26 +425,28 @@ public class BlockEventListener implements Listener { if (plot == null) { return; } - switch (event.getSource().getType()) { - case GRASS_BLOCK: + switch (event.getSource().getType().toString()) { + case "GRASS_BLOCK": if (!plot.getFlag(GrassGrowFlag.class)) { plot.debug("Grass could not grow because grass-grow = false"); event.setCancelled(true); } break; - case MYCELIUM: + case "MYCELIUM": if (!plot.getFlag(MycelGrowFlag.class)) { plot.debug("Mycelium could not grow because mycel-grow = false"); event.setCancelled(true); } break; - case VINE: + case "WEEPING_VINES": + case "TWISTING_VINES": + case "VINE": if (!plot.getFlag(VineGrowFlag.class)) { plot.debug("Vine could not grow because vine-grow = false"); event.setCancelled(true); } break; - case KELP: + case "KELP": if (!plot.getFlag(KelpGrowFlag.class)) { plot.debug("Kelp could not grow because kelp-grow = false"); event.setCancelled(true);