Skip to content

Commit

Permalink
made steam cutter not auto inherit recipes from cutter, fixed duratio…
Browse files Browse the repository at this point in the history
…n on cutter recipes being absurdly long
  • Loading branch information
Trinsdar committed Apr 22, 2024
1 parent 489dc17 commit bf79519
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 5 deletions.
2 changes: 1 addition & 1 deletion common/src/main/java/trinsdar/gt4r/data/RecipeMaps.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public class RecipeMaps {
public static RecipeMap<?> CANNING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "canner", new RecipeBuilder()));
public static RecipeMap<?> CENTRIFUGING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "centrifuge", new RecipeBuilder()));
public static RecipeMap<?> COMPRESSING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "compressor", new SteamBuilder(STEAM_COMPRESSOR)));
public static RecipeMap<?> CUTTING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "plate_cutter", new SteamBuilder(STEAM_CUTTER)));
public static RecipeMap<?> CUTTING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "plate_cutter", new RecipeBuilder()));
public static RecipeMap<?> SMELTING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "furnace", new RecipeBuilder()).setProxy(RecipeProxies.FURNACE_PROXY.apply(4, 60)));
public static RecipeMap<?> EXTRACTING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "extractor", new SteamBuilder(STEAM_EXTRACTOR)));
public static RecipeMap<?> EXTRUDING = AntimatterAPI.register(RecipeMap.class, new RecipeMap<>(GT4RRef.ID, "extruder", new RecipeBuilder()));
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
package trinsdar.gt4r.loader.machines;

import muramasa.antimatter.data.AntimatterMaterials;
import muramasa.antimatter.material.MaterialTags;
import muramasa.antimatter.recipe.ingredient.RecipeIngredient;
import net.minecraft.world.item.ItemStack;
import net.minecraft.world.item.Items;
Expand All @@ -8,21 +10,28 @@
import static muramasa.antimatter.data.AntimatterMaterialTypes.BOLT;
import static muramasa.antimatter.data.AntimatterMaterialTypes.PLATE;
import static muramasa.antimatter.data.AntimatterMaterialTypes.ROD;
import static trinsdar.gt4r.data.Materials.Steam;
import static trinsdar.gt4r.data.RecipeMaps.CUTTING;
import static trinsdar.gt4r.data.RecipeMaps.STEAM_CUTTER;

public class CutterLoader {
public static void init(){
PLATE.all().forEach(t -> {
if (!t.has(BLOCK)) return;
long duration = Math.max(t.getMass(), 1) * 300;
CUTTING.RB().ii(RecipeIngredient.of(BLOCK.getMaterialTag(t), 1)).io(PLATE.get(t,9)).add(t.getId() + "_plate",duration, 30);
long duration = Math.max(t.getMass(), 1);
int multiplier = 1;//mat.has(AntimatterMaterialTypes.GEM) ? 8 : 3;
if (t == AntimatterMaterials.Diamond || t == AntimatterMaterials.NetherizedDiamond)
multiplier = 5;
int count = t.has(MaterialTags.QUARTZ_LIKE_BLOCKS) ? 4 : 9;
CUTTING.RB().ii(RecipeIngredient.of(BLOCK.getMaterialTag(t), 1)).fi(AntimatterMaterials.Water.getLiquid(3)).io(PLATE.get(t,count)).add(t.getId() + "_plate",duration * multiplier, 30);
STEAM_CUTTER.RB().ii(BLOCK.getMaterialIngredient(t, 1)).fi(AntimatterMaterials.Water.getLiquid(3)).io(PLATE.get(t, count)).add(t.getId() + "_plate", duration * multiplier * 4, 30);
});
BOLT.all().forEach(t -> {
if (!t.has(ROD)) return;
long duration = Math.max(t.getMass(), 1) * 4;
CUTTING.RB().ii(RecipeIngredient.of(ROD.getMaterialTag(t), 1)).io(BOLT.get(t,4)).add(t.getId() + "_bolt",duration, 30);
CUTTING.RB().ii(RecipeIngredient.of(ROD.getMaterialTag(t), 1)).fi(AntimatterMaterials.Water.getLiquid(3)).io(BOLT.get(t,4)).add(t.getId() + "_bolt",duration, 30);
});
CUTTING.RB().ii(RecipeIngredient.of(Items.GLASS, 3)).io(new ItemStack(Items.GLASS_PANE)).add("glass_pane",50, 8);
CUTTING.RB().ii(RecipeIngredient.of(Items.GLASS, 3)).fi(AntimatterMaterials.Water.getLiquid(3)).io(new ItemStack(Items.GLASS_PANE)).add("glass_pane",50, 8);

}
}

0 comments on commit bf79519

Please sign in to comment.