use of net.minecraft.block.BlockOldLog in project SpongeCommon by SpongePowered.
the class MixinBlockLog method getTreeData.
protected ImmutableTreeData getTreeData(IBlockState blockState) {
BlockPlanks.EnumType type;
if (blockState.getBlock() instanceof BlockOldLog) {
type = blockState.getValue(BlockOldLog.VARIANT);
} else if (blockState.getBlock() instanceof BlockNewLog) {
type = blockState.getValue(BlockNewLog.VARIANT);
} else {
type = BlockPlanks.EnumType.OAK;
}
final TreeType treeType = TreeTypeResolver.getFor(type);
return ImmutableDataCachingUtil.getManipulator(ImmutableSpongeTreeData.class, treeType);
}
Aggregations