Skip to content

Commit

Permalink
Changed conditions for calling plotEntry
Browse files Browse the repository at this point in the history
  • Loading branch information
Fameless9 committed May 24, 2024
1 parent e3462fc commit c581e1f
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -533,11 +533,9 @@ public void onTeleport(PlayerTeleportEvent event) {
// to is identical to the plot's home location, and untrusted-visit is true
// i.e. untrusted-visit can override deny-teleport
// this is acceptable, because otherwise it wouldn't make sense to have both flags set
if (result) {
if (result || (plot.getFlag(UntrustedVisitFlag.class) && plot.getHomeSynchronous().equals(BukkitUtil.adaptComplete(to)))) {
plotListener.plotEntry(pp, plot);
} else if (!(plot.getFlag(UntrustedVisitFlag.class) && plot
.getHomeSynchronous()
.equals(BukkitUtil.adaptComplete(to)))) {
} else {
pp.sendMessage(
TranslatableCaption.of("deny.no_enter"),
TagResolver.resolver("plot", Tag.inserting(Component.text(plot.toString())))
Expand Down

0 comments on commit c581e1f

Please sign in to comment.