mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
spoingus
This commit is contained in:
parent
1e3e5f38d4
commit
1f5fc1926c
@ -107,7 +107,7 @@ dependencies {
|
|||||||
|
|
||||||
implementation "li.cil.oc:OpenComputers:MC1.7.10-1.5.+:api"
|
implementation "li.cil.oc:OpenComputers:MC1.7.10-1.5.+:api"
|
||||||
|
|
||||||
implementation "com.github.GTNewHorizons:Applied-Energistics-2-Unofficial:rv3-beta.56-GTNH:dev"
|
compileOnly "com.github.GTNewHorizons:Applied-Energistics-2-Unofficial:rv3-beta.56-GTNH:dev"
|
||||||
}
|
}
|
||||||
|
|
||||||
processResources {
|
processResources {
|
||||||
|
|||||||
@ -1,7 +1,14 @@
|
|||||||
package com.hbm.handler.nei;
|
package com.hbm.handler.nei;
|
||||||
|
|
||||||
|
import java.util.Map.Entry;
|
||||||
|
|
||||||
import com.hbm.blocks.ModBlocks;
|
import com.hbm.blocks.ModBlocks;
|
||||||
import com.hbm.inventory.recipes.AnnihilatorRecipes;
|
import com.hbm.inventory.recipes.AnnihilatorRecipes;
|
||||||
|
import com.hbm.items.ModItems;
|
||||||
|
import com.hbm.util.InventoryUtil;
|
||||||
|
|
||||||
|
import codechicken.nei.NEIServerUtils;
|
||||||
|
import net.minecraft.item.ItemStack;
|
||||||
|
|
||||||
public class AnnihilatorHandler extends NEIUniversalHandler {
|
public class AnnihilatorHandler extends NEIUniversalHandler {
|
||||||
|
|
||||||
@ -13,4 +20,26 @@ public class AnnihilatorHandler extends NEIUniversalHandler {
|
|||||||
public String getKey() {
|
public String getKey() {
|
||||||
return "ntmAnnihilating";
|
return "ntmAnnihilating";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void loadCraftingRecipes(ItemStack result) {
|
||||||
|
|
||||||
|
outer: for(Entry<Object, Object> recipe : recipes.entrySet()) {
|
||||||
|
ItemStack[][] ins = InventoryUtil.extractObject(recipe.getKey());
|
||||||
|
ItemStack[][] outs = InventoryUtil.extractObject(recipe.getValue());
|
||||||
|
|
||||||
|
for(ItemStack[] array : ins) for(ItemStack stack : array) if(stack.getItem() == ModItems.item_secret) continue outer;
|
||||||
|
for(ItemStack[] array : outs) for(ItemStack stack : array) if(stack.getItem() == ModItems.item_secret) continue outer;
|
||||||
|
|
||||||
|
match:
|
||||||
|
for(ItemStack[] array : outs) {
|
||||||
|
for(ItemStack stack : array) {
|
||||||
|
if(NEIServerUtils.areStacksSameTypeCrafting(stack, result) && ItemStack.areItemStackTagsEqual(stack, result)) {
|
||||||
|
this.arecipes.add(new RecipeSet(ins, outs, recipe.getKey()));
|
||||||
|
break match;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -102,10 +102,10 @@ public class AnnihilatorRecipes extends SerializableRecipe {
|
|||||||
if(input instanceof List) {
|
if(input instanceof List) {
|
||||||
List<ItemStack> list = (List<ItemStack>) input;
|
List<ItemStack> list = (List<ItemStack>) input;
|
||||||
for(ItemStack stack : list) ItemStackUtil.addTooltipToStack(stack, EnumChatFormatting.RED + String.format(Locale.US, "%,d", milestone.getKey()));
|
for(ItemStack stack : list) ItemStackUtil.addTooltipToStack(stack, EnumChatFormatting.RED + String.format(Locale.US, "%,d", milestone.getKey()));
|
||||||
input = list.toArray(new ItemStack[0]);
|
input = new ItemStack[][] { list.toArray(new ItemStack[0]) };
|
||||||
}
|
}
|
||||||
|
|
||||||
recipes.put(input, milestone.getValue());
|
recipes.put(input, milestone.getValue().copy());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -265,10 +265,11 @@ public class AssemblyMachineRecipes extends GenericRecipes<GenericRecipe> {
|
|||||||
this.register(new GenericRecipe("ass.fracker").setup(600, 100).outputItems(new ItemStack(ModBlocks.machine_fracking_tower, 1))
|
this.register(new GenericRecipe("ass.fracker").setup(600, 100).outputItems(new ItemStack(ModBlocks.machine_fracking_tower, 1))
|
||||||
.inputItems(new OreDictStack(STEEL.shell(), 24), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModBlocks.concrete_smooth, 64), new ComparableStack(ModItems.drill_titanium), new ComparableStack(ModItems.motor_desh, 2), new ComparableStack(ModItems.plate_desh, 24), new ComparableStack(ModItems.circuit, 16, EnumCircuitType.CAPACITOR))
|
.inputItems(new OreDictStack(STEEL.shell(), 24), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModBlocks.concrete_smooth, 64), new ComparableStack(ModItems.drill_titanium), new ComparableStack(ModItems.motor_desh, 2), new ComparableStack(ModItems.plate_desh, 24), new ComparableStack(ModItems.circuit, 16, EnumCircuitType.CAPACITOR))
|
||||||
.inputItemsEx(new ComparableStack(ModItems.item_expensive, 4, EnumExpensiveType.HEAVY_FRAME), new ComparableStack(ModItems.item_expensive, 2, EnumExpensiveType.FERRO_PLATING), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModBlocks.concrete_smooth, 64), new ComparableStack(ModItems.drill_titanium), new ComparableStack(ModItems.motor_desh, 5), new ComparableStack(ModItems.item_expensive, 4, EnumExpensiveType.CIRCUIT))
|
.inputItemsEx(new ComparableStack(ModItems.item_expensive, 4, EnumExpensiveType.HEAVY_FRAME), new ComparableStack(ModItems.item_expensive, 2, EnumExpensiveType.FERRO_PLATING), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModBlocks.concrete_smooth, 64), new ComparableStack(ModItems.drill_titanium), new ComparableStack(ModItems.motor_desh, 5), new ComparableStack(ModItems.item_expensive, 4, EnumExpensiveType.CIRCUIT))
|
||||||
.setPools528(GenericRecipes.POOL_PREFIX_528 + "rubber"));
|
.setPools528(GenericRecipes.POOL_PREFIX_528 + "plastic"));
|
||||||
this.register(new GenericRecipe("ass.flarestack").setup(100, 100).outputItems(new ItemStack(ModBlocks.machine_flare, 1))
|
this.register(new GenericRecipe("ass.flarestack").setup(100, 100).outputItems(new ItemStack(ModBlocks.machine_flare, 1))
|
||||||
.inputItems(new OreDictStack(STEEL.plate(), 12), new OreDictStack(CU.plate(), 4), new OreDictStack(STEEL.shell(), 4), new ComparableStack(ModItems.thermo_element, 3))
|
.inputItems(new OreDictStack(STEEL.plate(), 12), new OreDictStack(CU.plate(), 4), new OreDictStack(STEEL.shell(), 4), new ComparableStack(ModItems.thermo_element, 3))
|
||||||
.inputItemsEx(new ComparableStack(ModItems.item_expensive, 8, EnumExpensiveType.STEEL_PLATING), new OreDictStack(CU.plate(), 4), new ComparableStack(ModItems.thermo_element, 3)));
|
.inputItemsEx(new ComparableStack(ModItems.item_expensive, 8, EnumExpensiveType.STEEL_PLATING), new OreDictStack(CU.plate(), 4), new ComparableStack(ModItems.thermo_element, 3))
|
||||||
|
.setPools528(GenericRecipes.POOL_PREFIX_528 + "plastic"));
|
||||||
this.register(new GenericRecipe("ass.refinery").setup(200, 100).outputItems(new ItemStack(ModBlocks.machine_refinery, 1))
|
this.register(new GenericRecipe("ass.refinery").setup(200, 100).outputItems(new ItemStack(ModBlocks.machine_refinery, 1))
|
||||||
.inputItems(new OreDictStack(STEEL.plateWelded(), 3), new OreDictStack(CU.plate(), 8), new OreDictStack(STEEL.shell(), 4), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModItems.plate_polymer, 8), new ComparableStack(ModItems.circuit, 3, EnumCircuitType.ANALOG))
|
.inputItems(new OreDictStack(STEEL.plateWelded(), 3), new OreDictStack(CU.plate(), 8), new OreDictStack(STEEL.shell(), 4), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModItems.plate_polymer, 8), new ComparableStack(ModItems.circuit, 3, EnumCircuitType.ANALOG))
|
||||||
.inputItemsEx(new ComparableStack(ModItems.item_expensive, 4, EnumExpensiveType.STEEL_PLATING), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModItems.plate_polymer, 8), new ComparableStack(ModItems.circuit, 5, EnumCircuitType.ANALOG)));
|
.inputItemsEx(new ComparableStack(ModItems.item_expensive, 4, EnumExpensiveType.STEEL_PLATING), new OreDictStack(STEEL.pipe(), 12), new ComparableStack(ModItems.plate_polymer, 8), new ComparableStack(ModItems.circuit, 5, EnumCircuitType.ANALOG)));
|
||||||
|
|||||||
@ -133,6 +133,8 @@ public class TileEntityMachineAnnihilator extends TileEntityMachineBase implemen
|
|||||||
if(pool != null) {
|
if(pool != null) {
|
||||||
this.monitorBigInt = pool.items.get(type);
|
this.monitorBigInt = pool.items.get(type);
|
||||||
if(this.monitorBigInt == null) this.monitorBigInt = BigInteger.ZERO;
|
if(this.monitorBigInt == null) this.monitorBigInt = BigInteger.ZERO;
|
||||||
|
} else {
|
||||||
|
this.monitorBigInt = BigInteger.ZERO;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user