Java 类net.minecraft.block.state.BlockFaceShape 实例源码

项目:Soot    文件:UpgradeAlchemyGlobe.java   
@Nullable
public void ejectFailure(World world, BlockPos pos, ItemStack failure, EnumFacing[] directions)
{
    int ioff = 0;

    for(int i = 0; i < directions.length; i++)
    {
        EnumFacing direction = directions[(i + ioff) % directions.length];
        BlockPos ejectPos = pos.offset(direction);
        IBlockState state = world.getBlockState(ejectPos);
        if(state.getBlockFaceShape(world,ejectPos,direction.getOpposite()) == BlockFaceShape.UNDEFINED)
        {
            ejectFailure(world,pos,failure,direction);
            return;
        }
    }

    ejectFailure(world,pos,failure,EnumFacing.UP);
}
项目:Bewitchment    文件:BlockScornedBrickFence.java   
public boolean canConnectTo(IBlockAccess worldIn, BlockPos pos, EnumFacing p_176524_3_) {
    IBlockState iblockstate = worldIn.getBlockState(pos);
    BlockFaceShape blockfaceshape = iblockstate.getBlockFaceShape(worldIn, pos, p_176524_3_);
    Block block = iblockstate.getBlock();
    boolean flag = blockfaceshape == BlockFaceShape.MIDDLE_POLE && (iblockstate.getMaterial() == this.blockMaterial || block instanceof BlockFenceGate);
    return !isExcepBlockForAttachWithPiston(block) && blockfaceshape == BlockFaceShape.SOLID || flag;
}
项目:Bewitchment    文件:BlockFakeIceFence.java   
public boolean canConnectTo(IBlockAccess worldIn, BlockPos pos, EnumFacing p_176524_3_) {
    IBlockState iblockstate = worldIn.getBlockState(pos);
    BlockFaceShape blockfaceshape = iblockstate.getBlockFaceShape(worldIn, pos, p_176524_3_);
    Block block = iblockstate.getBlock();
    boolean flag = blockfaceshape == BlockFaceShape.MIDDLE_POLE && (iblockstate.getMaterial() == this.blockMaterial || block instanceof BlockFenceGate);
    return !isExcepBlockForAttachWithPiston(block) && blockfaceshape == BlockFaceShape.SOLID || flag;
}
项目:Ender-Rift    文件:BlockInterface.java   
@Deprecated
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    EnumFacing st = state.getValue(FACING);

    if (st == face)
        return BlockFaceShape.CENTER;

    EnumFacing op = face.getOpposite();
    if (st == op)
        return BlockFaceShape.SOLID;

    return BlockFaceShape.UNDEFINED;
}
项目:Ender-Rift    文件:BlockBrowser.java   
@Deprecated
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    EnumFacing st = state.getValue(FACING);

    if (st == face)
        return BlockFaceShape.CENTER;

    EnumFacing op = face.getOpposite();
    if (st == op)
        return BlockFaceShape.SOLID;

    return BlockFaceShape.UNDEFINED;
}
项目:Runes-of-Wizardry    文件:BlockDustPlaced.java   
@Override
public boolean canPlaceBlockAt(World world, BlockPos pos)
{
    //get the block 1 lower
    IBlockState state = world.getBlockState(pos.down());
    Block block = state.getBlock();
    if (block == null)
    {
        return false;
    } else{
        //FUTURE maybe tweak to use the oredict to allow other types of glass
        return state.getBlockFaceShape(world, pos, EnumFacing.UP)==BlockFaceShape.SOLID || block == Blocks.GLASS;
    }
}
项目:HardVox    文件:BlockStateDelegate.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, BlockPos pos, EnumFacing facing) {
    return delegate.getBlockFaceShape(worldIn, pos, facing);
}
项目:Bewitchment    文件:BlockScornedBrickFence.java   
@SuppressWarnings("deprecation")
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_) {
    return p_193383_4_ != EnumFacing.UP && p_193383_4_ != EnumFacing.DOWN ? BlockFaceShape.MIDDLE_POLE : BlockFaceShape.CENTER;
}
项目:Bewitchment    文件:BlockFakeIceFence.java   
@SuppressWarnings("deprecation")
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_) {
    return p_193383_4_ != EnumFacing.UP && p_193383_4_ != EnumFacing.DOWN ? BlockFaceShape.MIDDLE_POLE : BlockFaceShape.CENTER;
}
项目:Bewitchment    文件:BlockCircleGlyph.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState blockState, BlockPos pos, EnumFacing face) {
    return BlockFaceShape.UNDEFINED;
}
项目:harshencastle    文件:BaseFluidBlock.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing facing)
{
    return BlockFaceShape.UNDEFINED;
}
项目:Etheric    文件:BlockRift.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_,
        EnumFacing p_193383_4_) {
    return BlockFaceShape.UNDEFINED;
}
项目:Etheric    文件:BlockStabilityProjector.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_,
        EnumFacing p_193383_4_) {
    return BlockFaceShape.UNDEFINED;
}
项目:Geolosys    文件:BlockSample.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_)
{
    return BlockFaceShape.UNDEFINED;
}
项目:Geolosys    文件:BlockSampleVanilla.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockInfusionAltar.java   
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockAnimusMaterializer.java   
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return face == EnumFacing.DOWN ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockAnalyzer.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockArcaneTransfigurationTable.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockInfernalSmelter.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockAnimaConjurer.java   
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return face == EnumFacing.DOWN ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:ArcaneMagic    文件:BlockWritingDesk.java   
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:PurificatiMagicae    文件:BlockCrystal.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_)
{
    return BlockFaceShape.UNDEFINED;
}
项目:PurificatiMagicae    文件:BlockAbstractSingleItemHorizontal.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_)
{
    return BlockFaceShape.UNDEFINED;
}
项目:PurificatiMagicae    文件:BlockCrystalSmall.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_)
{
    return BlockFaceShape.UNDEFINED;
}
项目:PurificatiMagicae    文件:BlockAbstractWallIfTablet.java   
private static boolean canAttachToBlock(World world, BlockPos pos, EnumFacing facing)
{
    IBlockState state = world.getBlockState(pos);
    return facing.getHorizontalIndex() != -1 && !isExceptBlockForAttachWithPiston(state.getBlock()) && state.getBlockFaceShape(world, pos, facing) == BlockFaceShape.SOLID;
}
项目:PurificatiMagicae    文件:BlockAbstractWallIfTablet.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess p_193383_1_, IBlockState p_193383_2_, BlockPos p_193383_3_, EnumFacing p_193383_4_)
{
    return BlockFaceShape.UNDEFINED;
}
项目:PurificatiMagicae    文件:BlockMagibench.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:PurificatiMagicae    文件:BlockCodeStorage.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess worldIn, IBlockState state, BlockPos pos, EnumFacing face)
{
    return face == EnumFacing.DOWN ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:Solar    文件:BlockMechanicalTranslocator.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing facing) {
    return state.getValue(BlockDirectional.FACING) == facing ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:Solar    文件:BlockBlinker.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing facing) {
    return state.getValue(BlockDirectional.FACING) == facing ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:Solar    文件:BlockQimranut.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing facing) {
    return state.getValue(BlockDirectional.FACING) == facing ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:customstuff4    文件:BlockCarpet.java   
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess blockAccess, IBlockState state, BlockPos pos, EnumFacing side)
{
    return side == EnumFacing.DOWN ? BlockFaceShape.SOLID : BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockWorkedBoulder.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockLeaf.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockBoulderOre.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockShrub.java   
@SuppressWarnings("deprecation")
   @Override
   public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
   {
    return BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockFruit.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockPebble.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}
项目:ExPetrum    文件:BlockBoulder.java   
@SuppressWarnings("deprecation")
@Override
public BlockFaceShape getBlockFaceShape(IBlockAccess world, IBlockState state, BlockPos pos, EnumFacing face)
{
    return BlockFaceShape.UNDEFINED;
}