mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-09-28 04:17:32 +02:00
Removing of duplicated send-message action
This commit is contained in:
parent
8642d22ae1
commit
5eec25bdff
@ -164,13 +164,6 @@ public class BlockEventListener implements Listener {
|
|||||||
if (plot != null) {
|
if (plot != null) {
|
||||||
if (area.notifyIfOutsideBuildArea(pp, location.getY())) {
|
if (area.notifyIfOutsideBuildArea(pp, location.getY())) {
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
pp.sendMessage(
|
|
||||||
TranslatableCaption.of("height.height_limit"),
|
|
||||||
TagResolver.builder()
|
|
||||||
.tag("minheight", Tag.inserting(Component.text(area.getMinBuildHeight())))
|
|
||||||
.tag("maxheight", Tag.inserting(Component.text(area.getMaxBuildHeight())))
|
|
||||||
.build()
|
|
||||||
);
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!plot.hasOwner()) {
|
if (!plot.hasOwner()) {
|
||||||
@ -262,13 +255,6 @@ public class BlockEventListener implements Listener {
|
|||||||
}
|
}
|
||||||
} else if (area.notifyIfOutsideBuildArea(plotPlayer, location.getY())) {
|
} else if (area.notifyIfOutsideBuildArea(plotPlayer, location.getY())) {
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
plotPlayer.sendMessage(
|
|
||||||
TranslatableCaption.of("height.height_limit"),
|
|
||||||
TagResolver.builder()
|
|
||||||
.tag("minheight", Tag.inserting(Component.text(area.getMinBuildHeight())))
|
|
||||||
.tag("maxheight", Tag.inserting(Component.text(area.getMaxBuildHeight())))
|
|
||||||
.build()
|
|
||||||
);
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!plot.hasOwner()) {
|
if (!plot.hasOwner()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user