From aa8d8a3028c5309ec4cd645695ddda2595572e95 Mon Sep 17 00:00:00 2001 From: NorbiPeti Date: Tue, 27 Aug 2019 02:54:28 +0200 Subject: [PATCH] Adding distance in the message --- plugin.yml | 2 +- .../components/townyfactions/TownyFactionsComponent.java | 2 +- target/classes/plugin.yml | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/plugin.yml b/plugin.yml index 5dd8f6a..af04016 100644 --- a/plugin.yml +++ b/plugin.yml @@ -15,4 +15,4 @@ commands: description: A set of commands designed for R and D softdepend: [Factions] -depend: [ButtonCore] \ No newline at end of file +depend: [ChromaCore] \ No newline at end of file diff --git a/src/main/java/buttondevteam/presents/components/townyfactions/TownyFactionsComponent.java b/src/main/java/buttondevteam/presents/components/townyfactions/TownyFactionsComponent.java index b6cda94..ad9ebb5 100644 --- a/src/main/java/buttondevteam/presents/components/townyfactions/TownyFactionsComponent.java +++ b/src/main/java/buttondevteam/presents/components/townyfactions/TownyFactionsComponent.java @@ -56,7 +56,7 @@ public class TownyFactionsComponent extends Component implements int distance = max * amount; if (distance().get() >= distance) { event.setCancelled(true); - event.getSender().sendMessage("§cYou are too close to a town!"); + event.getSender().sendMessage("§cYou are too close to a town! " + distance + " chunks away, " + distance().get() + " is allowed."); } } } diff --git a/target/classes/plugin.yml b/target/classes/plugin.yml index d2e613f..af04016 100644 --- a/target/classes/plugin.yml +++ b/target/classes/plugin.yml @@ -15,3 +15,4 @@ commands: description: A set of commands designed for R and D softdepend: [Factions] +depend: [ChromaCore] \ No newline at end of file