From 31513d52d7a15a3f9018706a903c54662dd633f1 Mon Sep 17 00:00:00 2001 From: Glitchfinder Date: Wed, 17 Oct 2012 21:26:16 -0700 Subject: [PATCH] Fixing spacing issues and making herbalism drop cocoa beans instead of a cocoa block. --- .../com/gmail/nossr50/skills/gathering/Herbalism.java | 7 ++++++- src/main/java/com/gmail/nossr50/util/BlockChecks.java | 10 +++++----- 2 files changed, 11 insertions(+), 6 deletions(-) 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 5729b3bc2..beaaa762a 100644 --- a/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java +++ b/src/main/java/com/gmail/nossr50/skills/gathering/Herbalism.java @@ -218,7 +218,12 @@ public class Herbalism { is = new ItemStack(ModChecks.getCustomBlock(block).getItemDrop()); } else { - is = new ItemStack(mat); + if (mat == Material.COCOA) { + is = new ItemStack(Material.INK_SACK, 1, (short) 3); + } + else { + is = new ItemStack(mat); + } } if (herbLevel > MAX_BONUS_LEVEL || random.nextInt(randomChance) <= herbLevel) { diff --git a/src/main/java/com/gmail/nossr50/util/BlockChecks.java b/src/main/java/com/gmail/nossr50/util/BlockChecks.java index 7eda2333a..83dfc6817 100644 --- a/src/main/java/com/gmail/nossr50/util/BlockChecks.java +++ b/src/main/java/com/gmail/nossr50/util/BlockChecks.java @@ -52,8 +52,8 @@ public class BlockChecks { case VINE: case WATER_LILY: case YELLOW_FLOWER: - case COCOA: - case EMERALD_ORE: + case COCOA: + case EMERALD_ORE: return true; default: @@ -125,7 +125,7 @@ public class BlockChecks { case IRON_ORE: case LAPIS_ORE: case REDSTONE_ORE: - case EMERALD_ORE: + case EMERALD_ORE: return true; default: @@ -178,7 +178,7 @@ public class BlockChecks { case VINE: case WATER_LILY: case YELLOW_FLOWER: - case COCOA: + case COCOA: return true; case CROPS: @@ -221,7 +221,7 @@ public class BlockChecks { case REDSTONE_ORE: case SANDSTONE: case STONE: - case EMERALD_ORE: + case EMERALD_ORE: return true; default: