Restored original behavior of Salvage.isSalvageable

It doesn't check for custom armors, I don't know if it's a bug or not
Added isMinecraftTool and isMinecraftArmor for clarity
This commit is contained in:
bm01
2013-02-12 19:15:17 +01:00
parent f486492c37
commit 9f22382506
2 changed files with 13 additions and 3 deletions

View File

@ -141,10 +141,10 @@ public class Salvage {
* @return true if the item is salvageable, false otherwise
*/
public static boolean isSalvageable(final ItemStack is) {
if (configInstance.getSalvageTools() && (ItemChecks.isTool(is) || ItemChecks.isStringTool(is) || is.getType() == Material.BUCKET)) {
if (configInstance.getSalvageTools() && (ItemChecks.isMinecraftArmor(is) || ItemChecks.isStringTool(is) || is.getType() == Material.BUCKET)) {
return true;
}
if (configInstance.getSalvageArmor() && ItemChecks.isArmor(is)) {
if (configInstance.getSalvageArmor() && ItemChecks.isMinecraftArmor(is)) {
return true;
}
return false;