From e6b8d04fb0b20bd88a3050eb405c55711be811eb Mon Sep 17 00:00:00 2001 From: Cheeserolls Date: Fri, 22 May 2015 13:25:18 +0100 Subject: [PATCH] Fix crash caused by reference to sapling which does not exist --- src/main/java/biomesoplenty/common/init/ModCrafting.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/main/java/biomesoplenty/common/init/ModCrafting.java b/src/main/java/biomesoplenty/common/init/ModCrafting.java index acc961770..ff044de40 100644 --- a/src/main/java/biomesoplenty/common/init/ModCrafting.java +++ b/src/main/java/biomesoplenty/common/init/ModCrafting.java @@ -311,8 +311,11 @@ public class ModCrafting for (BOPTrees tree : BOPTrees.values()) { - OreDictionary.registerOre("treeSapling", BlockBOPSapling.paging.getVariantItem(tree)); OreDictionary.registerOre("treeLeaves", BlockBOPLeaves.paging.getVariantItem(tree)); + if (tree.hasSapling()) + { + OreDictionary.registerOre("treeSapling", BlockBOPSapling.paging.getVariantItem(tree)); + } } // TODO ? // OreDictionary.registerOre("treeLeaves", new ItemStack(BOPCBlocks.appleLeaves, 1, OreDictionary.WILDCARD_VALUE));