mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-22 13:16:45 +01:00
Fix deny-exit flag
This commit is contained in:
parent
c98f2b4261
commit
eb1c3263ec
@ -179,7 +179,7 @@ public class PlotListener {
|
||||
}
|
||||
|
||||
public static boolean plotExit(final PlotPlayer player, Plot plot) {
|
||||
player.deleteMeta("lastplot");
|
||||
Object previous = player.deleteMeta("lastplot");
|
||||
EventUtil.manager.callLeave(player, plot);
|
||||
if (plot.hasOwner()) {
|
||||
PlotArea pw = plot.getArea();
|
||||
@ -187,6 +187,9 @@ public class PlotListener {
|
||||
return true;
|
||||
}
|
||||
if (Flags.DENY_EXIT.isTrue(plot)) {
|
||||
if (previous != null) {
|
||||
player.setMeta("lastplot", previous);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
if (plot.getFlag(Flags.GAMEMODE).isPresent() || plot.getFlag(Flags.GUEST_GAMEMODE).isPresent()) {
|
||||
|
Loading…
Reference in New Issue
Block a user