Search in sources :

Example 1 with IArcaneRecipe

use of thaumcraft.api.crafting.IArcaneRecipe in project Railcraft by Railcraft.

the class ThaumcraftPlugin method setupResearch.

public static void setupResearch() {
    ResearchCategories.registerCategory(RESEARCH_CATEGORY, null, new ResourceLocation("railcraft", "textures/items/tool.crowbar.magic.png"), new ResourceLocation("thaumcraft", "textures/gui/gui_researchback.png"));
    // Apothecaries Backpack
    Item item = RailcraftItems.BACKPACK_APOTHECARY_T1.item();
    if (item != null) {
        IArcaneRecipe recipe = ThaumcraftApi.addArcaneCraftingRecipe("RC_ApothecariesBackpack", RailcraftItems.BACKPACK_APOTHECARY_T1.getStack(), new AspectList().add(Aspect.AIR, 16).add(Aspect.ORDER, 16), "X#X", "VYV", "X#X", '#', Blocks.WOOL, 'V', Items.GLASS_BOTTLE, 'X', Items.STRING, 'Y', "chestWood");
        AspectList aspects = new AspectList();
        aspects.add(Aspect.VOID, 3).add(Aspect.CRAFT, 3).add(Aspect.MOTION, 2);
        ResearchItem backpack = new ResearchItemRC("RC_ApothecariesBackpack", ThaumcraftPlugin.RESEARCH_CATEGORY, aspects, 2, 0, 6, RailcraftItems.BACKPACK_APOTHECARY_T1.getStack());
        backpack.setPages(ThaumcraftPlugin.getResearchPage("RC_ApothecariesBackpack"), new ResearchPage(recipe)).setParentsHidden("ENCHFABRIC").registerResearchItem();
    }
    // Thaumium Crowbar
    item = RailcraftItems.CROWBAR_THAUMIUM.item();
    if (item != null) {
        String researchTag = "RC_Crowbar_Thaumium";
        IArcaneRecipe recipe = ThaumcraftApi.addArcaneCraftingRecipe(researchTag, new ItemStack(item), new AspectList().add(Aspect.ORDER, 8), " RI", "RIR", "IR ", 'I', ThaumcraftPlugin.ITEMS.get("ingots", 0), 'R', "dyeRed");
        AspectList aspects = new AspectList();
        aspects.add(Aspect.TOOL, 1).add(Aspect.MECHANISM, 2).add(Aspect.METAL, 1);
        ResearchItem thaumiumCrowbar = new ResearchItemRC(researchTag, ThaumcraftPlugin.RESEARCH_CATEGORY, aspects, 0, 0, 3, new ItemStack(item));
        thaumiumCrowbar.setPages(ThaumcraftPlugin.getResearchPage(researchTag), new ResearchPage(recipe)).setParentsHidden("THAUMIUM").registerResearchItem();
    }
    // Void Crowbar
    item = RailcraftItems.CROWBAR_VOID.item();
    if (item != null) {
        String researchTag = "RC_Crowbar_Void";
        IArcaneRecipe recipe = ThaumcraftApi.addArcaneCraftingRecipe(researchTag, new ItemStack(item), new AspectList().add(Aspect.ENTROPY, 50), " RI", "RIR", "IR ", 'I', ThaumcraftPlugin.ITEMS.get("ingots", 1), 'R', "dyeRed");
        AspectList aspects = new AspectList();
        aspects.add(Aspect.TOOL, 2).add(Aspect.MECHANISM, 4).add(Aspect.METAL, 2);
        ResearchItemRC voidCrowbar = new ResearchItemRC(researchTag, ThaumcraftPlugin.RESEARCH_CATEGORY, aspects, 0, 1, 3, new ItemStack(item));
        voidCrowbar.setPages(ThaumcraftPlugin.getResearchPage(researchTag), new ResearchPage(recipe)).setParents(researchTag).setParentsHidden("VOIDMETAL").registerResearchItem();
    }
}
Also used : Item(net.minecraft.item.Item) ResearchItem(thaumcraft.api.research.ResearchItem) AspectList(thaumcraft.api.aspects.AspectList) ResourceLocation(net.minecraft.util.ResourceLocation) IArcaneRecipe(thaumcraft.api.crafting.IArcaneRecipe) ResearchPage(thaumcraft.api.research.ResearchPage) ItemStack(net.minecraft.item.ItemStack) ResearchItem(thaumcraft.api.research.ResearchItem)

Aggregations

Item (net.minecraft.item.Item)1 ItemStack (net.minecraft.item.ItemStack)1 ResourceLocation (net.minecraft.util.ResourceLocation)1 AspectList (thaumcraft.api.aspects.AspectList)1 IArcaneRecipe (thaumcraft.api.crafting.IArcaneRecipe)1 ResearchItem (thaumcraft.api.research.ResearchItem)1 ResearchPage (thaumcraft.api.research.ResearchPage)1