@Override public @Nonnull IBlockState withRotation(@Nonnull Rotation rot) { return state.withRotation(rot); }
/** * @deprecated (Remove this as soon as minecraft offers anything better). */ @SuppressWarnings(DEPRECATION) @NotNull @Override @Deprecated public IBlockState withMirror(@NotNull final IBlockState state, final Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
@Override public @Nonnull IBlockState withMirror(@Nonnull IBlockState state, @Nonnull Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
/** * @deprecated (Remove this as soon as minecraft offers anything better). */ @NotNull @Override @Deprecated public IBlockState withMirror(@NotNull final IBlockState state, final Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
@Nonnull @Override public IBlockState withMirror(@Nonnull IBlockState state, Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
@Nonnull @Override public IBlockState withMirror(@Nonnull IBlockState state, Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
/** * @deprecated (Remove this as soon as minecraft offers anything better). */ @SuppressWarnings(DEPRECATION) @NotNull @Override @Deprecated public IBlockState withMirror(@NotNull final IBlockState state, final Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
/** * @deprecated (Remove this as soon as minecraft offers anything better). */ @NotNull @Override @Deprecated public IBlockState withMirror(@NotNull final IBlockState state, final Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
@Nonnull @Override public IBlockState withMirror(@Nonnull IBlockState state, Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
@Override public IBlockState withMirror(final IBlockState state, final Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation((EnumFacing) state.getValue(FACING))); }
@SuppressWarnings("deprecation") @Override public IBlockState withMirror(IBlockState state, Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
@Override public IBlockState getState(int turns) { return super.getState(turns).withRotation(Rotation.values()[turns % 4]); } }
@Override public IBlockState withMirror(IBlockState state, Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation((EnumFacing) state.getValue(FACING))); }
@Override public IBlockState withMirror(IBlockState state, Mirror mirrorIn) { if (hasFacing) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); } return state; }
@Override public IBlockState withMirror(IBlockState state, Mirror mirrorIn) { return state.withRotation(mirrorIn.toRotation(state.getValue(FACING))); }
private void generateFurniture(World world, Random rand, StructureBoundingBox sbb) { setBlockState(world, CRUCIBLE_STATE.withRotation(Rotation.COUNTERCLOCKWISE_90), 5, 0, 5, sbb); setBlockState(world, MOLD_STATE.withRotation(Rotation.CLOCKWISE_90), 4, 0, 5, sbb); setBlockState(world, CARVING_TABLE_STATE, 1, 0, 5, sbb); generateChest(world, sbb, rand, 5, 0, 2, LootTableList.CHESTS_VILLAGE_BLACKSMITH); generateChest(world, sbb, rand, 1, 0, 3, MetalcastingModule.CARVING_TABLE_LOOT); } }
private void generateFrontWall(World world, Random rand, StructureBoundingBox sbb, EnumFacing dir) { fillWithBlocks(world, sbb, 1, 0, 0, 5, 3, 0, CLAY_STATE, CLAY_STATE, false); setBlockState(world, AIR_STATE, 4, 0, 1, sbb); setBlockState(world, AIR_STATE, 4, 1, 1, sbb); createVillageDoor(world, sbb, rand, 3, 0, 0, dir); setBlockState(world, BUTTON_STATE.withRotation(Rotation.CLOCKWISE_180), 1, 2, -1, sbb); setBlockState(world, BUTTON_STATE.withRotation(Rotation.CLOCKWISE_180), 3, 2, -1, sbb); setBlockState(world, BUTTON_STATE.withRotation(Rotation.CLOCKWISE_180), 5, 2, -1, sbb); fillWithBlocks(world, sbb, 1, 4, 0, 5, 4, 0, FENCE_STATE, FENCE_STATE, false); }
private void generateLogicalLeftWall(World world, StructureBoundingBox sbb) { fillWithBlocks(world, sbb, 0, 0, 1, 0, 3, 5, CLAY_STATE, CLAY_STATE, false); setBlockState(world, BUTTON_STATE.withRotation(Rotation.COUNTERCLOCKWISE_90), -1, 2, 1, sbb); setBlockState(world, BUTTON_STATE.withRotation(Rotation.COUNTERCLOCKWISE_90), -1, 2, 5, sbb); setBlockState(world, FENCE_STATE, 0, 1, 3, sbb); setBlockState(world, FENCE_STATE, 0, 2, 3, sbb); fillWithBlocks(world, sbb, 0, 4, 1, 0, 4, 5, FENCE_STATE, FENCE_STATE, false); }
@Override public boolean test(World world, BlockPos start, int x, int y, int z, Rotation rotation) { setWorld(world); BlockPos checkPos = start.add(RotationUtil.x(rotation, x, z), y, RotationUtil.z(rotation, x, z)); Predicate<IBlockState> pred = stateTargets[x][y][z].getStatePredicate(); IBlockState state = world.getBlockState(checkPos).withRotation(RotationUtil.fixHorizontal(rotation)); return pred.test(state); }
private void generateLogicalRightWall(World world, StructureBoundingBox sbb) { fillWithBlocks(world, sbb, 6, 0, 1, 6, 3, 5, CLAY_STATE, CLAY_STATE, false); setBlockState(world, BUTTON_STATE.withRotation(Rotation.CLOCKWISE_90), 7, 2, 2, sbb); setBlockState(world, FENCE_STATE, 6, 1, 3, sbb); setBlockState(world, FENCE_STATE, 6, 2, 3, sbb); fillWithBlocks(world, sbb, 6, 4, 1, 6, 4, 5, FENCE_STATE, FENCE_STATE, false); }