diff --git a/pom.xml b/pom.xml index 3a3fb51ce..23880f021 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ KingdomProgrammers Medieval-Factions - v3.6.2-beta-2 + v3.6.2 jar Medieval Factions diff --git a/src/main/java/dansplugins/factionsystem/MedievalFactions.java b/src/main/java/dansplugins/factionsystem/MedievalFactions.java index 70eada839..523b68941 100644 --- a/src/main/java/dansplugins/factionsystem/MedievalFactions.java +++ b/src/main/java/dansplugins/factionsystem/MedievalFactions.java @@ -16,7 +16,7 @@ public class MedievalFactions extends JavaPlugin { private static MedievalFactions instance; - private String version = "v3.6.2-beta-2"; + private String version = "v3.6.2"; public static MedievalFactions getInstance() { return instance; diff --git a/src/main/java/dansplugins/factionsystem/eventhandlers/InteractionHandler.java b/src/main/java/dansplugins/factionsystem/eventhandlers/InteractionHandler.java index 763911f8e..8df66347d 100644 --- a/src/main/java/dansplugins/factionsystem/eventhandlers/InteractionHandler.java +++ b/src/main/java/dansplugins/factionsystem/eventhandlers/InteractionHandler.java @@ -74,12 +74,18 @@ public void handle(BlockBreakEvent event) { } removeLock(event.getBlock(), PersistentData.getInstance().getLockedBlocks()); - // if block was a door if (isDoor(event.getBlock())) { // remove locks above and below the original block as well - removeLock(event.getBlock().getRelative(BlockFace.UP)); - removeLock(event.getBlock().getRelative(BlockFace.DOWN)); + Block relativeUp = event.getBlock().getRelative(BlockFace.UP); + Block relativeDown = event.getBlock().getRelative(BlockFace.DOWN); + if (isDoor(relativeUp)) { + removeLock(relativeUp); + } + if (isDoor(relativeDown)) { + removeLock(relativeDown); + } + return; } } diff --git a/src/main/resources/plugin.yml b/src/main/resources/plugin.yml index 03282c8ed..c3d5f0cc7 100644 --- a/src/main/resources/plugin.yml +++ b/src/main/resources/plugin.yml @@ -1,5 +1,5 @@ name: MedievalFactions -version: 3.6.2-beta-2 +version: 3.6.2 author: KingdomProgrammers main: dansplugins.factionsystem.MedievalFactions api-version: 1.13