src/main/java/arcaratus/bloodarsenal/common/util/Utils.java
public static boolean canPush(BlockState blockStateIn, World worldIn, BlockPos pos, Direction facing, boolean destroyBlocks, Direction direction)
    {
        if (pos.getY() >= 0 && pos.getY() <= worldIn.getHeight() - 1 && worldIn.getWorldBorder().contains(pos))
        {
            if (blockStateIn.isAir())
            {
                return true;
            }
            else if (!blockStateIn.isIn(Blocks.OBSIDIAN) && !blockStateIn.isIn(Blocks.CRYING_OBSIDIAN) && !blockStateIn.isIn(Blocks.RESPAWN_ANCHOR))
            {
                if (facing == Direction.DOWN && pos.getY() == 0)
                {
                    return false;
                }
                else if (facing == Direction.UP && pos.getY() == worldIn.getHeight() - 1)
                {
                    return false;
                }
                else
                {
                    if (!blockStateIn.isIn(Blocks.PISTON) && !blockStateIn.isIn(Blocks.STICKY_PISTON))
                    {
                        if (blockStateIn.getBlockHardness(worldIn, pos) == -1.0F)
                        {
                            return false;
                        }

                        switch (blockStateIn.getPushReaction())
                        {
                            case BLOCK:
                                return false;
                            case DESTROY:
                                return destroyBlocks;
                            case PUSH_ONLY:
                                return facing == direction;
                        }
                    }

                    return true;
                }
            }
            else
            {
                return false;
            }
        }
        else
        {
            return false;
        }
    }
// Modified version of the PistonBlock#canPush to allow tiles
Modified version of the PistonBlock#canPush to allow tiles
Modified version of the PistonBlock#canPush to allow tiles
public static boolean canPush(BlockState blockStateIn, World worldIn, BlockPos pos, Direction facing, boolean destroyBlocks, Direction direction)
    {
        if (pos.getY() >= 0 && pos.getY() <= worldIn.getHeight() - 1 && worldIn.getWorldBorder().contains(pos))
        {
            if (blockStateIn.isAir())
            {
                return true;
            }
            else if (!blockStateIn.isIn(Blocks.OBSIDIAN) && !blockStateIn.isIn(Blocks.CRYING_OBSIDIAN) && !blockStateIn.isIn(Blocks.RESPAWN_ANCHOR))
            {
                if (facing == Direction.DOWN && pos.getY() == 0)
                {
                    return false;
                }
                else if (facing == Direction.UP && pos.getY() == worldIn.getHeight() - 1)
                {
                    return false;
                }
                else
                {
                    if (!blockStateIn.isIn(Blocks.PISTON) && !blockStateIn.isIn(Blocks.STICKY_PISTON))
                    {
                        if (blockStateIn.getBlockHardness(worldIn, pos) == -1.0F)
                        {
                            return false;
                        }
                        switch (blockStateIn.getPushReaction())
                        {
                            case BLOCK:
                                return false;
                            case DESTROY:
                                return destroyBlocks;
                            case PUSH_ONLY:
                                return facing == direction;
                        }
                    }
                    return true;
                }
            }
            else
            {
                return false;
            }
        }
        else
        {
            return false;
        }
    }
public static boolean canPush ( BlockState blockStateIn , World worldIn , BlockPos pos , Direction facing , boolean destroyBlocks , Direction direction ) { if ( pos . getY ( ) >= 0 && pos . getY ( ) <= worldIn . getHeight ( ) - 1 && worldIn . getWorldBorder ( ) . contains ( pos ) ) { if ( blockStateIn . isAir ( ) ) { return true ; } else if ( ! blockStateIn . isIn ( Blocks . OBSIDIAN ) && ! blockStateIn . isIn ( Blocks . CRYING_OBSIDIAN ) && ! blockStateIn . isIn ( Blocks . RESPAWN_ANCHOR ) ) { if ( facing == Direction . DOWN && pos . getY ( ) == 0 ) { return false ; } else if ( facing == Direction . UP && pos . getY ( ) == worldIn . getHeight ( ) - 1 ) { return false ; } else { if ( ! blockStateIn . isIn ( Blocks . PISTON ) && ! blockStateIn . isIn ( Blocks . STICKY_PISTON ) ) { if ( blockStateIn . getBlockHardness ( worldIn , pos ) == - 1.0F ) { return false ; } switch ( blockStateIn . getPushReaction ( ) ) { case BLOCK : return false ; case DESTROY : return destroyBlocks ; case PUSH_ONLY : return facing == direction ; } } return true ; } } else { return false ; } } else { return false ; } }
Modified version of the PistonBlock#canPush to allow tiles
Modified version of the PistonBlock#canPush to allow tiles