Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @Override
- public void setBlockBoundsBasedOnState(IBlockAccess worldIn, BlockPos pos)
- {
- if (worldIn.getBlockState(pos).getValue(DOUBLE))
- {
- EnumFacing facing = worldIn.getBlockState(pos).getValue(FACING);
- switch (facing)
- {
- case NORTH:
- this.setBlockBounds(0.05F, 0F, 0F, 0.95F, 0.95F, 0.95F);
- break;
- case EAST:
- this.setBlockBounds(0.05F, 0F, 0.05F, 1F, 0.95F, 0.95F);
- break;
- case SOUTH:
- this.setBlockBounds(0.05F, 0F, 0.05F, 0.95F, 0.95F, 1F);
- break;
- case WEST:
- this.setBlockBounds(0F, 0F, 0.05F, 0.95F, 0.95F, 0.95F);
- break;
- }
- }
- this.setBlockBounds(0.05F, 0F, 0.05F, 0.95F, 0.95F, 0.95F);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement