public override void SetBlockBoundsBasedOnState(net.minecraft.src.IBlockAccess iblockaccess , int i, int j, int k) { net.minecraft.src.TileEntityPiston tileentitypiston = GetTileEntityAtLocation(iblockaccess , i, j, k); if (tileentitypiston != null) { net.minecraft.src.Block block = net.minecraft.src.Block.blocksList[tileentitypiston .GetStoredBlockID()]; if (block == null || block == this) { return; } block.SetBlockBoundsBasedOnState(iblockaccess, i, j, k); float f = tileentitypiston.Func_31007_a(0.0F); if (tileentitypiston.Func_31010_c()) { f = 1.0F - f; } int l = tileentitypiston.Func_31008_d(); minX = block.minX - (double)((float)net.minecraft.src.PistonBlockTextures.field_31051_b [l] * f); minY = block.minY - (double)((float)net.minecraft.src.PistonBlockTextures.field_31054_c [l] * f); minZ = block.minZ - (double)((float)net.minecraft.src.PistonBlockTextures.field_31053_d [l] * f); maxX = block.maxX - (double)((float)net.minecraft.src.PistonBlockTextures.field_31051_b [l] * f); maxY = block.maxY - (double)((float)net.minecraft.src.PistonBlockTextures.field_31054_c [l] * f); maxZ = block.maxZ - (double)((float)net.minecraft.src.PistonBlockTextures.field_31053_d [l] * f); } }
public override net.minecraft.src.AxisAlignedBB GetCollisionBoundingBoxFromPool(net.minecraft.src.World world, int i, int j, int k) { net.minecraft.src.TileEntityPiston tileentitypiston = GetTileEntityAtLocation(world , i, j, k); if (tileentitypiston == null) { return(null); } float f = tileentitypiston.Func_31007_a(0.0F); if (tileentitypiston.Func_31010_c()) { f = 1.0F - f; } return(Func_31032_a(world, i, j, k, tileentitypiston.GetStoredBlockID(), f, tileentitypiston .Func_31008_d())); }