mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-22 21:26:45 +01:00
UUID caching + Interact event
Fixed an issue where UUID handler would not recognize * as the "everyone uuid" if it took the shortcut for faster UUID caching. Fixed #301 an issue with fire protection (Bukkit has a strange way of dealing with this)
This commit is contained in:
parent
d6500873cf
commit
c9c669a8c2
@ -759,9 +759,6 @@ public class PlayerEvents extends com.intellectualcrafters.plot.listeners.PlotLi
|
||||
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
|
||||
public void onInteract(final PlayerInteractEvent event) {
|
||||
Action action = event.getAction();
|
||||
if (action == Action.LEFT_CLICK_BLOCK) {
|
||||
return;
|
||||
}
|
||||
final Block block = event.getClickedBlock();
|
||||
if (block == null) {
|
||||
return;
|
||||
@ -780,7 +777,7 @@ public class PlayerEvents extends com.intellectualcrafters.plot.listeners.PlotLi
|
||||
if (Permissions.hasPermission(pp, "plots.admin.interact.unowned")) {
|
||||
return;
|
||||
}
|
||||
if (action != Action.PHYSICAL) {
|
||||
if (action != Action.PHYSICAL && action != Action.LEFT_CLICK_BLOCK) {
|
||||
MainUtil.sendMessage(pp, C.NO_PERMISSION, "plots.admin.interact.unowned");
|
||||
}
|
||||
event.setCancelled(true);
|
||||
@ -795,7 +792,7 @@ public class PlayerEvents extends com.intellectualcrafters.plot.listeners.PlotLi
|
||||
if (Permissions.hasPermission(pp, "plots.admin.interact.other")) {
|
||||
return;
|
||||
}
|
||||
if (action != Action.PHYSICAL) {
|
||||
if (action != Action.PHYSICAL && action != Action.LEFT_CLICK_BLOCK) {
|
||||
MainUtil.sendMessage(pp, C.NO_PERMISSION, "plots.admin.interact.other");
|
||||
}
|
||||
event.setCancelled(true);
|
||||
@ -808,7 +805,7 @@ public class PlayerEvents extends com.intellectualcrafters.plot.listeners.PlotLi
|
||||
return;
|
||||
}
|
||||
if (MainUtil.isPlotArea(loc)) {
|
||||
if (action != Action.PHYSICAL) {
|
||||
if (action != Action.PHYSICAL && action != Action.LEFT_CLICK_BLOCK) {
|
||||
MainUtil.sendMessage(pp, C.NO_PERMISSION, "plots.admin.interact.road");
|
||||
}
|
||||
event.setCancelled(true);
|
||||
|
@ -136,6 +136,7 @@ public class UUIDHandler {
|
||||
}
|
||||
}
|
||||
}
|
||||
add(new StringWrapper("*"), DBFunc.everyone);
|
||||
PlotSquared.log(C.PREFIX.s() + "&6Cached a total of: " + UUIDHandler.uuidMap.size() + " UUIDs");
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user