Search in sources :

Example 6 with SCManualPage

use of net.geforcemods.securitycraft.misc.SCManualPage in project SecurityCraft by Geforce132.

the class RegistrationHandler method registerItem.

/**
 * Registers the given item with GameRegistry.registerItem(), and adds the help info for the item to the SecurityCraft manual item.
 */
private static void registerItem(Item item, String customName) {
    GameRegistry.registerItem(item, customName);
    SecurityCraft.instance.manualPages.add(new SCManualPage(item, "help." + item.getUnlocalizedName().substring(5) + ".info"));
}
Also used : SCManualPage(net.geforcemods.securitycraft.misc.SCManualPage)

Example 7 with SCManualPage

use of net.geforcemods.securitycraft.misc.SCManualPage in project SecurityCraft by Geforce132.

the class ConfigurationHandler method registerItem.

/**
	 * Registers the given item with GameRegistry.registerItem(), and adds the help info for the item to the SecurityCraft manual item.
	 */
private void registerItem(Item item, String customName) {
    GameRegistry.registerItem(item, customName);
    mod_SecurityCraft.instance.manualPages.add(new SCManualPage(item, I18n.translateToLocal("help." + item.getUnlocalizedName().substring(5) + ".info")));
}
Also used : SCManualPage(net.geforcemods.securitycraft.misc.SCManualPage)

Example 8 with SCManualPage

use of net.geforcemods.securitycraft.misc.SCManualPage in project SecurityCraft by Geforce132.

the class ConfigurationHandler method registerBlock.

private void registerBlock(Block block, Class<? extends ItemBlock> itemClass, Object... constructorParams) {
    GameRegistry.registerBlock(block, itemClass, block.getUnlocalizedName().substring(5), constructorParams);
    mod_SecurityCraft.instance.manualPages.add(new SCManualPage(Item.getItemFromBlock(block), StatCollector.translateToLocal("help." + block.getUnlocalizedName().substring(5) + ".info")));
}
Also used : SCManualPage(net.geforcemods.securitycraft.misc.SCManualPage)

Example 9 with SCManualPage

use of net.geforcemods.securitycraft.misc.SCManualPage in project SecurityCraft by Geforce132.

the class ConfigurationHandler method registerBlockWithCustomRecipe.

/**
	 * Registers the given block with GameRegistry.registerBlock(), and adds the help info for the block to the SecurityCraft manual item.
	 * Also overrides the default recipe that would've been drawn in the manual with a new recipe.
	 * 
	 */
private void registerBlockWithCustomRecipe(Block block, ItemStack... customRecipe) {
    GameRegistry.registerBlock(block, block.getUnlocalizedName().substring(5));
    mod_SecurityCraft.instance.manualPages.add(new SCManualPage(Item.getItemFromBlock(block), I18n.translateToLocal("help." + block.getUnlocalizedName().substring(5) + ".info"), customRecipe));
}
Also used : SCManualPage(net.geforcemods.securitycraft.misc.SCManualPage)

Example 10 with SCManualPage

use of net.geforcemods.securitycraft.misc.SCManualPage in project SecurityCraft by Geforce132.

the class ConfigurationHandler method registerBlock.

private void registerBlock(Block block, Class<? extends ItemBlock> itemClass) {
    GameRegistry.registerBlock(block, itemClass, block.getUnlocalizedName().substring(5));
    mod_SecurityCraft.instance.manualPages.add(new SCManualPage(Item.getItemFromBlock(block), I18n.translateToLocal("help." + block.getUnlocalizedName().substring(5) + ".info")));
}
Also used : SCManualPage(net.geforcemods.securitycraft.misc.SCManualPage)

Aggregations

SCManualPage (net.geforcemods.securitycraft.misc.SCManualPage)15 Ingredient (net.minecraft.item.crafting.Ingredient)1