Skip to content

Commit

Permalink
Do not check interactions outside plot areas (#4515)
Browse files Browse the repository at this point in the history
  • Loading branch information
SirYwell authored Oct 13, 2024
1 parent 5642061 commit 641e384
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -371,7 +371,10 @@ public boolean checkPlayerBlockEvent(
Location location, BlockType blockType, boolean notifyPerms
) {
PlotArea area = location.getPlotArea();
assert area != null;
// the interaction target location might be outside a plot area
if (area == null) {
return true;
}
if (!area.buildRangeContainsY(location.getY()) && !player.hasPermission(Permission.PERMISSION_ADMIN_BUILD_HEIGHT_LIMIT)) {
player.sendMessage(
TranslatableCaption.of("height.height_limit"),
Expand Down

0 comments on commit 641e384

Please sign in to comment.