net.minecraft.block.properties.PropertyBool Java Examples

The following examples show how to use net.minecraft.block.properties.PropertyBool. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: WorldGenCustomSwampTree.java    From CommunityMod with GNU Lesser General Public License v2.1 5 votes vote down vote up
private void addVine(World worldIn, BlockPos pos, PropertyBool prop) {
    IBlockState iblockstate = Blocks.VINE.getDefaultState().withProperty(prop, Boolean.valueOf(true));
    this.setBlockAndNotifyAdequately(worldIn, pos, iblockstate);
    int i = 4;

    for (pos = pos.down(); isAir(worldIn, pos) && i > 0; --i) {
        this.setBlockAndNotifyAdequately(worldIn, pos, iblockstate);
        pos = pos.down();
    }
}
 
Example #2
Source File: WorldGenCustomSwampTree.java    From Traverse-Legacy-1-12-2 with MIT License 5 votes vote down vote up
private void addVine(World worldIn, BlockPos pos, PropertyBool prop) {
    IBlockState iblockstate = Blocks.VINE.getDefaultState().withProperty(prop, Boolean.valueOf(true));
    this.setBlockAndNotifyAdequately(worldIn, pos, iblockstate);
    int i = 4;

    for (pos = pos.down(); isAir(worldIn, pos) && i > 0; --i) {
        this.setBlockAndNotifyAdequately(worldIn, pos, iblockstate);
        pos = pos.down();
    }
}