Fix fruit pods

This commit is contained in:
mezz committed 2016-03-11 20:21:52 -08:00
1 parent d5a45a39eb
commit a192c1ce49
40 files changed
+408 -406

No files matched your search

@@ -11,6 +11,7 @@
package forestry.farming.logic;
import net.minecraft.block.Block;
import net.minecraft.block.BlockCocoa;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.init.Blocks;
import net.minecraft.init.Items;
@@ -42,7 +43,7 @@ public class FarmableCocoa implements IFarmable {
return null;
}
int meta = BlockUtil.getBlockMetadata(world, pos);
if (BlockUtil.getMaturityPod(BlockUtil.getBlockState(world, pos)) < 2) {
if (BlockUtil.getBlockState(world, pos).getValue(BlockCocoa.AGE) < 2) {
return null;
}
@@ -61,7 +62,7 @@ public class FarmableCocoa implements IFarmable {
@Override
public boolean plantSaplingAt(EntityPlayer player, ItemStack germling, World world, BlockPos pos) {
return BlockUtil.tryPlantPot(world, pos, COCOA_PLANT);
return BlockUtil.tryPlantCocoaPod(world, pos);
}
}