mirror of
https://github.com/EarthMC/QuickShop-Reremake.git
synced 2026-11-24 17:39:52 -05:00
fix last commit again
Former-commit-id: 958875eed9b430bf7c976573c7d0174517496948
This commit is contained in:
1 parent
e9617b857d
commit
16bb24ea88
2 files changed
+16
No files matched your search
@@ -64,6 +64,14 @@ public class BlockListener implements Listener {
|
||||
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true)
|
||||
public void onBreak(BlockBreakEvent e) {
|
||||
Block b = e.getBlock();
|
||||
if(b instanceof Sign) {
|
||||
Sign sign = (Sign)b;
|
||||
if(sign.getLine(0).equals(plugin.getConfig().getString("lockette.private"))||sign.getLine(0).equals(plugin.getConfig().getString("lockette.more_users"))){
|
||||
//Ignore break lockette sign
|
||||
plugin.getLogger().info("Skipped a dead-lock shop sign.(Lockette)");
|
||||
return;
|
||||
}
|
||||
}
|
||||
Player p = e.getPlayer();
|
||||
// If the shop was a chest
|
||||
if (b.getState() instanceof InventoryHolder) {
|
||||
|
||||
@@ -83,6 +83,14 @@ public class LockListener implements Listener {
|
||||
@EventHandler(priority = EventPriority.LOW, ignoreCancelled = true)
|
||||
public void onBreak(BlockBreakEvent e) {
|
||||
Block b = e.getBlock();
|
||||
if(b instanceof Sign) {
|
||||
Sign sign = (Sign)b;
|
||||
if(sign.getLine(0).equals(plugin.getConfig().getString("lockette.private"))||sign.getLine(0).equals(plugin.getConfig().getString("lockette.more_users"))){
|
||||
//Ignore break lockette sign
|
||||
plugin.getLogger().info("Skipped a dead-lock shop sign.(Lockette)");
|
||||
return;
|
||||
}
|
||||
}
|
||||
Player p = e.getPlayer();
|
||||
// If the chest was a chest
|
||||
if (Util.canBeShop(b)) {
|
||||
|
||||
Reference in new issue
Block a user