mirror of
https://github.com/TotalFreedomMC/TF-PlotSquared.git
synced 2025-02-12 03:59:22 +00:00
Fixed piston retract (finally)
This commit is contained in:
parent
2634853050
commit
271cc026d4
1 changed files with 2 additions and 1 deletions
|
@ -546,7 +546,8 @@ public class PlayerEvents extends com.intellectualcrafters.plot.listeners.PlotLi
|
|||
}
|
||||
Plot plot = MainUtil.getPlot(loc);
|
||||
if (plot != null) {
|
||||
Location bloc = BukkitUtil.getLocation(block.getLocation().subtract(block.getRelative(event.getDirection()).getRelative(event.getDirection()).getLocation()));
|
||||
BlockFace dir = event.getDirection();
|
||||
Location bloc = BukkitUtil.getLocation(block.getLocation().subtract(dir.getModX() * 2, dir.getModY() * 2, dir.getModZ() * 2));
|
||||
Plot newPlot = MainUtil.getPlot(bloc);
|
||||
if (!plot.equals(newPlot)) {
|
||||
event.setCancelled(true);
|
||||
|
|
Loading…
Reference in a new issue