本文整理汇总了Java中ic2.api.recipe.Recipes类的典型用法代码示例。如果您正苦于以下问题:Java Recipes类的具体用法?Java Recipes怎么用?Java Recipes使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Recipes类属于ic2.api.recipe包,在下文中一共展示了Recipes类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: addRecipesToRegistry
import ic2.api.recipe.Recipes; //导入依赖的package包/类
public static void addRecipesToRegistry(){
//AE Kit
Recipes.advRecipes.addRecipe(new ItemStack(CrossAppeng.kitAppeng), new Object[]{
"IT", "PD",
'I', AEApi.instance().definitions().materials().fluixCrystal().maybeStack(1).get(),
'T', IC2Items.getItem("frequencyTransmitter"),
'P', Items.paper,
'D', "dyePurple"});
//AE Monitor
Recipes.advRecipes.addRecipe(new ItemStack(CrossAppeng.networklink), new Object[]{
"BRB", "YCY", "BRB",
'B', "ingotIron",
'R', AEApi.instance().definitions().materials().calcProcessor().maybeStack(1).get(),
'Y', AEApi.instance().definitions().parts().cableGlass().item(AEColor.Purple),
'C', Items.comparator});
}
示例2: addGregtechRecipes
import ic2.api.recipe.Recipes; //导入依赖的package包/类
public static void addGregtechRecipes(){
//AE Kit
Recipes.advRecipes.addRecipe(new ItemStack(CrossAppeng.kitAppeng), new Object[]{
"IT", "PD",
'I', AEApi.instance().definitions().materials().fluixCrystal().maybeStack(1).get(),
'T', IC2Items.getItem("frequencyTransmitter"),
'P', Items.paper,
'D', "dyePurple"});
//AE Monitor
Recipes.advRecipes.addRecipe(new ItemStack(CrossAppeng.networklink), new Object[]{
"BRB", "YCY", "BRB",
'B', "plateIron",
'R', AEApi.instance().definitions().materials().calcProcessor().maybeStack(1).get(),
'Y', AEApi.instance().definitions().parts().cableGlass().item(AEColor.Transparent),
'C', Items.comparator});
}
示例3: initVanilla
import ic2.api.recipe.Recipes; //导入依赖的package包/类
public static void initVanilla(){
inventoryCard = new ItemCardInventoryScanner().setUnlocalizedName("ItemInventoryScannerCard");
vanillaKit = new ItemVanillaKit().setUnlocalizedName("ItemVanilliaKit");
machineCard = new ItemVanillaMachineCard().setUnlocalizedName("ItemVanillaMachineCard");
GameRegistry.registerItem(inventoryCard, "ItemInventoryScannerCard");
GameRegistry.registerItem(vanillaKit, "ItemVanilliaKit");
GameRegistry.registerItem(machineCard, "ItemVanillaMachineCard");
Recipes.advRecipes.addRecipe(new ItemStack(vanillaKit), new Object[] {
"PL ",
"FC ",
'P', Items.paper,
'C', "circuitBasic",
'F', IC2Items.getItem("frequencyTransmitter"),
'L', Blocks.lever
});
}
示例4: scan
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@Override
public void scan() {
Map<IRecipeInput, RecipeOutput> recipeMap = Maps.newHashMap();
recipeMap.putAll(Recipes.metalformerCutting.getRecipes());
recipeMap.putAll(Recipes.metalformerExtruding.getRecipes());
recipeMap.putAll(Recipes.metalformerRolling.getRecipes());
for (Map.Entry<IRecipeInput, RecipeOutput> entry : recipeMap.entrySet()) {
IStackWrapper input = IC2ClassHelper.convert(entry.getKey());
for (ItemStack itemStack : entry.getValue().items) {
if (input instanceof VanillaStackWrapper) {
addRecipe(new VanillaStackWrapper(itemStack), (VanillaStackWrapper) input);
} else if (input instanceof OreStackWrapper) {
for (ItemStack oreStack : OreDictionary.getOres(((OreStackWrapper) input).getOreTag())) {
addRecipe(new VanillaStackWrapper(itemStack), new VanillaStackWrapper(oreStack));
}
}
}
}
}
示例5: getOutputFor
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@Override
public RecipeOutput getOutputFor(ItemStack input, boolean consume) {
if(ImmibisCore.areItemsEqual(input, Ic2Items.scrap)) {
if(input.stackSize < 9)
return null;
if(consume)
input.stackSize -= 9;
return scrapbox_out;
}
if(!consume)
return scrap_out;
input.stackSize--;
if(Recipes.recyclerBlacklist.contains(input))
return null_out;
return worldObj.rand.nextInt(8) == 0 ? scrap_out : null_out;
}
示例6: addRecipes
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@RecipeAddition(requiredModids = "IC2", time = EventTime.INIT)
public static void addRecipes() {
if (ConfigurationHandler.doCharcoalBlockCompression) {
if (!OreDictionary.getOres("blockCharcoal").isEmpty()) {
Recipes.compressor.addRecipe(new RecipeInputOreDict("blockCharcoal"), null, new ItemStack(Items.coal, 1, 0));
}
}
if (ConfigurationHandler.addIridiumPanelRecipe) {
GameRegistry.addRecipe(new ShapedOreRecipe(Ic2Items.iridiumPlate,
"IPI",
"PDP",
"IPI",
'I', "ingotIridium",
'P', Ic2Items.advancedAlloy,
'D', "gemDiamond"
));
}
}
示例7: initialize
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@Override
public boolean initialize() {
processRecipes(Recipes.metalformerRolling);
processRecipes(Recipes.metalformerExtruding);
processRecipes(Recipes.metalformerCutting);
processRecipes(Recipes.compressor);
return true;
}
示例8: init
import ic2.api.recipe.Recipes; //导入依赖的package包/类
public static void init(){
IC2RecipeInput input1 = new IC2RecipeInput(new ItemStack(ShinyStonesBlocks.shinyAirStone));
Recipes.macerator.addRecipe(input1, null, new ItemStack(ShinyStonesItems.shinyAirDust, 8));
IC2RecipeInput input2 = new IC2RecipeInput(new ItemStack(ShinyStonesBlocks.shinyEarthStone));
Recipes.macerator.addRecipe(input2, null, new ItemStack(ShinyStonesItems.shinyEarthDust, 8));
IC2RecipeInput input3 = new IC2RecipeInput(new ItemStack(ShinyStonesBlocks.shinyFireStone));
Recipes.macerator.addRecipe(input3, null, new ItemStack(ShinyStonesItems.shinyFireDust, 8));
IC2RecipeInput input4 = new IC2RecipeInput(new ItemStack(ShinyStonesBlocks.shinyWaterStone));
Recipes.macerator.addRecipe(input4, null, new ItemStack(ShinyStonesItems.shinyWaterDust, 8));
}
示例9: addIC2BronzeRecipe
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@Method(modid = "IC2")
public static void addIC2BronzeRecipe()
{
try {
Recipes.macerator.addRecipe(new RecipeInputOreDict("ingotBronze"), null, StackUtils.size(OreDictionary.getOres("dustBronze").get(0), 1));
} catch(Exception e) {}
}
示例10: addRecipes
import ic2.api.recipe.Recipes; //导入依赖的package包/类
public static void addRecipes(){
//TODO BR doesn't have any GT recipes
Recipes.advRecipes.addRecipe(new ItemStack(CrossBigReactors.kitRFsensor), new Object[]{
"IT", "PD",
'I', "ingotYellorium",
'T', IC2Items.getItem("frequencyTransmitter"),
'P', Items.paper,
'D', "dyeRed"});
Recipes.advRecipes.addRecipe(new ItemStack(CrossBigReactors.ReactorInfoFetch), new Object[]{
"BRB", "YCY", "BRB",
'B', "reactorCasing",
'R', "dustRedstone",
'Y', "ingotYellorium",
'C', Items.comparator});
}
示例11: addRecipes
import ic2.api.recipe.Recipes; //导入依赖的package包/类
public static void addRecipes(){
Recipes.advRecipes.addRecipe(new ItemStack(CrossBigReactors.kitRFsensor), new Object[]{
"IT", "PD",
'I', "ingotYellorium",
'T', IC2Items.getItem("frequencyTransmitter"),
'P', Items.paper,
'D', "dyeRed"});
Recipes.advRecipes.addRecipe(new ItemStack(CrossBigReactors.ReactorInfoFetch), new Object[]{
"BRB", "YCY", "BRB",
'B', "reactorCasing",
'R', "dustRedstone",
'Y', "ingotYellorium",
'C', Items.comparator});
}
示例12: onPostInit
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@Override
public void onPostInit() {
if (MiscPeripherals.instance.enableChargeStationT4) {
Recipes.advRecipes.addRecipe(new ItemStack(MiscPeripherals.instance.blockBeta, 1, 3), " # ", "[email protected]", " $ ", 'C', Items.getItem("trippleInsulatedIronCableItem"), '#', "circuitTier07", '$', "10kkEUStore", '@', MiscPeripherals.instance.enableChargeStationT3 ? new ItemStack(MiscPeripherals.instance.blockBeta, 1, 2) : (MiscPeripherals.instance.enableChargeStationT2 ? new ItemStack(MiscPeripherals.instance.blockBeta, 1, 1) : (MiscPeripherals.instance.enableChargeStation ? new ItemStack(MiscPeripherals.instance.blockAlpha, 1, 0) : "rawMachineTier04")));
}
thorium = GregTech_API.getGregTechItem(48, 1, 0);
dualThorium = GregTech_API.getGregTechItem(49, 1, 0);
quadThorium = GregTech_API.getGregTechItem(50, 1, 0);
plutonium = GregTech_API.getGregTechItem(51, 1, 0);
dualPlutonium = GregTech_API.getGregTechItem(52, 1, 0);
quadPlutonium = GregTech_API.getGregTechItem(53, 1, 0);
IRTGFuel.handlers.add(new IRTGFuel() {
@Override
public int get(ItemStack stack) {
if (stack.itemID == thorium.itemID) {
return (int)(PeripheralRTG.URANIUM_TOTAL * PeripheralRTG.THORIUM_MOD * (1.0F - ((float)stack.getItemDamage() / (float)stack.getMaxDamage())));
} else if (stack.itemID == dualThorium.itemID) {
return (int)(PeripheralRTG.URANIUM_TOTAL * PeripheralRTG.THORIUM_MOD * 2.0F * (1.0F - ((float)stack.getItemDamage() / (float)stack.getMaxDamage())));
} else if (stack.itemID == quadThorium.itemID) {
return (int)(PeripheralRTG.URANIUM_TOTAL * PeripheralRTG.THORIUM_MOD * 4.0F * (1.0F - ((float)stack.getItemDamage() / (float)stack.getMaxDamage())));
} else if (stack.itemID == plutonium.itemID) {
return (int)(PeripheralRTG.URANIUM_TOTAL * PeripheralRTG.PLUTONIUM_MOD * (1.0F - ((float)stack.getItemDamage() / (float)stack.getMaxDamage())));
} else if (stack.itemID == dualPlutonium.itemID) {
return (int)(PeripheralRTG.URANIUM_TOTAL * PeripheralRTG.PLUTONIUM_MOD * 2.0F * (1.0F - ((float)stack.getItemDamage() / (float)stack.getMaxDamage())));
} else if (stack.itemID == quadPlutonium.itemID) {
return (int)(PeripheralRTG.URANIUM_TOTAL * PeripheralRTG.PLUTONIUM_MOD * 4.0F * (1.0F - ((float)stack.getItemDamage() / (float)stack.getMaxDamage())));
}
return 0;
}
});
}
示例13: init
import ic2.api.recipe.Recipes; //导入依赖的package包/类
@EventHandler
public void init(FMLInitializationEvent event){
NetworkRegistry.INSTANCE.registerGuiHandler(AFSUMod.instance, new GuiHandler());
Recipes.advRecipes.addRecipe(new ItemStack(ALC), "GIG", "IUI", "GIG", 'G', IC2Items.getItem("cable", "glass"), 'I', IC2Items.getItem("crafting", "iridium"), 'U',
IC2Items.getItem("fluid_cell", "ic2uu_matter"));
Recipes.advRecipes.addRecipe(new ItemStack(AFSU), "MGM", "IAI", "MGM", 'I', IC2Items.getItem("crafting", "iridium"), 'G', IC2Items.getItem("cable", "glass"), 'M',
IC2Items.getItem("te", "mfsu"), 'A', AFSUMod.ALC);
}
示例14: registerWash
import ic2.api.recipe.Recipes; //导入依赖的package包/类
private void registerWash(ItemStack input, NBTTagCompound metadata, ItemStack... outputs) {
if (!this.isLoaded())
return;
if (Recipes.oreWashing.getOutputFor(input, true) == null) {
Recipes.oreWashing.addRecipe(new RecipeInputItemStack(input), metadata, outputs);
}
}
示例15: registerCentrifuge
import ic2.api.recipe.Recipes; //导入依赖的package包/类
private void registerCentrifuge(ItemStack input, NBTTagCompound metadata,
ItemStack... outputs) {
if (!this.isLoaded())
return;
if (Recipes.centrifuge.getOutputFor(input, true) == null) {
Recipes.centrifuge.addRecipe(new RecipeInputItemStack(input), metadata, outputs);
}
}