@Nullable @Override public String getName(BlockType blockType) { return Block.REGISTRY.getObject(new ResourceLocation(blockType.getId())).getLocalizedName(); }
@Override public String getName() { return BetterQuesting.submitStation.getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return block_enchanter.getBlock().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return MachineObject.block_solar_panel.getBlock().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return MachineObject.block_stirling_generator.getBlock().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return MachineObject.block_combustion_generator.getBlock().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return MachineObject.block_zombie_generator.getBlock().getLocalizedName(); }
@Override public @Nonnull String getTitle() { return block_sag_mill.getBlockNN().getLocalizedName(); }
@Override public @Nonnull String getTitle() { return block_alloy_smelter.getBlockNN().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return MachineObject.block_ender_generator.getBlock().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return MachineObject.block_lava_generator.getBlock().getLocalizedName(); }
@SuppressWarnings("null") @Override public @Nonnull String getTitle() { return block_tank.getBlock().getLocalizedName(); }
@Override public @Nonnull String getTitle() { return block_painter.getBlockNN().getLocalizedName(); }
@Override public @Nonnull String getTitle() { return block_soul_binder.getBlockNN().getLocalizedName(); }
@Override public @Nonnull String getTitle() { return MachineObject.block_weather_obelisk.getBlockNN().getLocalizedName(); }
@Override public @Nonnull String getLocalizedName() { return getParent().getBlockNN().getLocalizedName(); }
@Nonnull @Override public ItemStack getWailaStack(IWailaDataAccessor accessor, IWailaConfigHandler config) { return new ItemStack(RegistrarBloodMagicItems.ARCANE_ASHES).setStackDisplayName(TextHelper.getFormattedText(RegistrarBloodMagicBlocks.ALCHEMY_ARRAY.getLocalizedName())); }
/** * The interior is any block that does not touch blocks outside the machine. * * @param world World object for the world in which this controller is located. * @param pos coordinate of the block being tested * @throws MultiblockValidationException if the tested block is not allowed in the machine's interior */ protected void isBlockGoodForInterior(World world, BlockPos pos) throws MultiblockValidationException { Block block = world.getBlockState(pos).getBlock(); throw new MultiblockValidationException(Translator.translateToLocalFormatted("for.multiblock.error.invalid.interior", block.getLocalizedName()), pos); }
/** * @param level the level of the block on the multiblock, starting at 0 for the bottom. * @param world World object for the world in which this controller is located. * @param pos coordinate of the block being tested * @throws MultiblockValidationException if the tested block is not allowed on the machine's side faces */ protected void isBlockGoodForExteriorLevel(int level, World world, BlockPos pos) throws MultiblockValidationException { Block block = world.getBlockState(pos).getBlock(); throw new MultiblockValidationException(Translator.translateToLocalFormatted("for.multiblock.error.invalid.interior", block.getLocalizedName()), pos); }
private void registerFarmable(Block plantBlock, Item plantItem, ItemStack product, String identifier) { IProperty<Integer> growthProperty = BlockUtil.getProperty(plantBlock, "growth", Integer.class); if (growthProperty == null) { Log.error("Could not find the growth property of {}.", plantBlock.getLocalizedName()); } else { IFarmRegistry registry = FarmRegistry.getInstance(); int harvestAge = Collections.max(growthProperty.getAllowedValues()); int replantAge = plantBlock.getDefaultState().getValue(growthProperty); registry.registerFarmables(identifier, new FarmableAgingCrop(new ItemStack(plantItem), plantBlock, product, growthProperty, harvestAge, replantAge)); } } }