diff --git a/src/main/java/com/gmail/nossr50/skills/gathering/Fishing.java b/src/main/java/com/gmail/nossr50/skills/gathering/Fishing.java index bca3c110a..17bdc6a3e 100755 --- a/src/main/java/com/gmail/nossr50/skills/gathering/Fishing.java +++ b/src/main/java/com/gmail/nossr50/skills/gathering/Fishing.java @@ -410,7 +410,7 @@ public class Fishing { try { item = (new MaterialData(Material.INK_SACK, DyeColor.BLACK.getDyeData())).toItemStack(1); } - catch(Exception e) { + catch(Exception e) { item = (new MaterialData(Material.INK_SACK, (byte) 0)).toItemStack(1); } diff --git a/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java b/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java index 5736a90f5..155db7d1a 100644 --- a/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java +++ b/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java @@ -277,10 +277,10 @@ public class Herbalism { } } else if (mat == Material.CARROT) { - is = new ItemStack(Material.CARROT_ITEM, 1, (short) 0); + is = new ItemStack(Material.CARROT_ITEM); } else if (mat == Material.POTATO) { - is = new ItemStack(Material.POTATO_ITEM, 1, (short) 0); + is = new ItemStack(Material.POTATO_ITEM); } else { is = new ItemStack(mat); @@ -467,11 +467,11 @@ public class Herbalism { break; case COCOA: try { - Misc.dropItem(location, new ItemStack(Material.INK_SACK, 3, DyeColor.BROWN.getDyeData())); + Misc.dropItems(location, new ItemStack(Material.INK_SACK, 1, DyeColor.BROWN.getDyeData()), 3); inventory.removeItem(new ItemStack(Material.INK_SACK, 1, DyeColor.BROWN.getDyeData())); } catch(Exception e) { - Misc.dropItem(location, new ItemStack(Material.INK_SACK, 3, (short) 3)); + Misc.dropItems(location, new ItemStack(Material.INK_SACK, 1, (short) 3), 3); inventory.removeItem(new ItemStack(Material.INK_SACK, 1, (short) 3)); } break; @@ -487,7 +487,7 @@ public class Herbalism { inventory.removeItem(new ItemStack(Material.POTATO_ITEM)); break; case NETHER_WARTS: - Misc.dropItem(location, new ItemStack(Material.NETHER_STALK, 2)); + Misc.dropItems(location, new ItemStack(Material.NETHER_STALK), 2); Misc.randomDropItems(location, new ItemStack(Material.NETHER_STALK), 50, 2); inventory.removeItem(new ItemStack(Material.NETHER_STALK)); break; @@ -508,8 +508,8 @@ public class Herbalism { * @param block The block being used in the ability */ public static void greenThumbBlocks(ItemStack is, Player player, Block block) { - final int MAX_CHANCE = advancedConfig.getGreenThumbChanceMax(); - final int MAX_BONUS_LEVEL = advancedConfig.getGreenThumbMaxLevel(); + final int MAX_CHANCE = advancedConfig.getGreenThumbChanceMax(); + final int MAX_BONUS_LEVEL = advancedConfig.getGreenThumbMaxLevel(); PlayerProfile profile = Users.getProfile(player); int skillLevel = profile.getSkillLevel(SkillType.HERBALISM); diff --git a/src/main/java/com/gmail/nossr50/skills/repair/SimpleRepairManager.java b/src/main/java/com/gmail/nossr50/skills/repair/SimpleRepairManager.java index b73ae5b43..f3a85ef9f 100644 --- a/src/main/java/com/gmail/nossr50/skills/repair/SimpleRepairManager.java +++ b/src/main/java/com/gmail/nossr50/skills/repair/SimpleRepairManager.java @@ -5,6 +5,7 @@ import java.util.List; import org.bukkit.Bukkit; import org.bukkit.ChatColor; +import org.bukkit.Material; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; import org.bukkit.inventory.PlayerInventory; @@ -165,7 +166,7 @@ public class SimpleRepairManager implements RepairManager { item.setAmount(item.getAmount() - 1); } else { - item = new ItemStack(0); + item = new ItemStack(Material.AIR); } // I suspect this may not be needed, but I don't think it hurts