Fix crash caused by reference to sapling which does not exist

This commit is contained in:
Cheeserolls 2015-05-22 13:25:18 +01:00
parent 7019c0a68c
commit e6b8d04fb0
1 changed files with 4 additions and 1 deletions

View File

@ -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));