/** * Called when the sign is destroyed. * * @throws PermissionsException if player is not allowed to break the sign. */ public void destroy(Player breakingPlayer) throws PermissionsException { plugin .permissions .getBest() .throwIfCannot(breakingPlayer, "break." + getActionType(breakingPlayer)); SignManager.getInstance(plugin).removeChestLocation(signLocation); }
/** * Set the location of the chest for this sign. * * <p>If the chest location is set interactively, be sure to call {@link * #preSetChestLocation(Player)} to make sure the player has permission first. */ public void setChestLocation(Location chestLocation) { SignManager.getInstance(plugin).setChestLocation(signLocation, chestLocation); }
/** Get the location of the chest for this sign. */ public Location getChestLocation() { return SignManager.getInstance(plugin).getChestLocation(signLocation); }