aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gregtech/api/recipe
diff options
context:
space:
mode:
authorNotAPenguin <michiel.vandeginste@gmail.com>2024-08-08 21:08:24 +0200
committerGitHub <noreply@github.com>2024-08-08 21:08:24 +0200
commitce7826d878b0a4924f96cadf7b66287bd0c1d034 (patch)
tree6e48dcd133d82697854e2d99eb1af4567b59218d /src/main/java/gregtech/api/recipe
parent89156d0d8485753e0cea91637fced1b66897a6df (diff)
downloadGT5-Unofficial-ce7826d878b0a4924f96cadf7b66287bd0c1d034.tar.gz
GT5-Unofficial-ce7826d878b0a4924f96cadf7b66287bd0c1d034.tar.bz2
GT5-Unofficial-ce7826d878b0a4924f96cadf7b66287bd0c1d034.zip
Finalize textures for items related to grade 8 purified water (#2848)
* swap circuits in engraving for distilled water * change quark goop textures and water colors * add structure tooltip to grade 8 multi * display quark catalysts in t8 frontend * add simple uv treatment frontend to show lenses * add final quark catalyst textures and recipes * remove electromagnet from recipe * fix baryonic perfection recipemap and quark colors in scanner output
Diffstat (limited to 'src/main/java/gregtech/api/recipe')
-rw-r--r--src/main/java/gregtech/api/recipe/RecipeMaps.java6
-rw-r--r--src/main/java/gregtech/api/recipe/maps/PurificationUnitLaserFrontend.java36
-rw-r--r--src/main/java/gregtech/api/recipe/maps/PurificationUnitParticleExtractorFrontend.java36
3 files changed, 77 insertions, 1 deletions
diff --git a/src/main/java/gregtech/api/recipe/RecipeMaps.java b/src/main/java/gregtech/api/recipe/RecipeMaps.java
index 6d614d27d0..a2f053922c 100644
--- a/src/main/java/gregtech/api/recipe/RecipeMaps.java
+++ b/src/main/java/gregtech/api/recipe/RecipeMaps.java
@@ -61,7 +61,9 @@ import gregtech.api.recipe.maps.OilCrackerBackend;
import gregtech.api.recipe.maps.PrinterBackend;
import gregtech.api.recipe.maps.PurificationUnitClarifierFrontend;
import gregtech.api.recipe.maps.PurificationUnitFlocculatorFrontend;
+import gregtech.api.recipe.maps.PurificationUnitLaserFrontend;
import gregtech.api.recipe.maps.PurificationUnitOzonationFrontend;
+import gregtech.api.recipe.maps.PurificationUnitParticleExtractorFrontend;
import gregtech.api.recipe.maps.PurificationUnitPhAdjustmentFrontend;
import gregtech.api.recipe.maps.PurificationUnitPlasmaHeaterFrontend;
import gregtech.api.recipe.maps.RecyclerBackend;
@@ -1225,9 +1227,10 @@ public final class RecipeMaps {
.build();
public static final RecipeMap<RecipeMapBackend> purificationUVTreatmentRecipes = RecipeMapBuilder
.of("gt.recipe.purificationplantuvtreatment")
- .maxIO(0, 0, 1, 1)
+ .maxIO(9, 0, 1, 1)
.minInputs(0, 1)
.progressBar(GT_UITextures.PROGRESSBAR_ARROW)
+ .frontend(PurificationUnitLaserFrontend::new)
.disableOptimize()
.build();
public static final RecipeMap<RecipeMapBackend> purificationDegasifierRecipes = RecipeMapBuilder
@@ -1242,6 +1245,7 @@ public final class RecipeMaps {
.maxIO(2, 1, 1, 2)
.minInputs(0, 1)
.progressBar(GT_UITextures.PROGRESSBAR_ARROW)
+ .frontend(PurificationUnitParticleExtractorFrontend::new)
.disableOptimize()
.build();
public static final RecipeMap<RecipeMapBackend> ic2NuclearFakeRecipes = RecipeMapBuilder.of("gt.recipe.ic2nuke")
diff --git a/src/main/java/gregtech/api/recipe/maps/PurificationUnitLaserFrontend.java b/src/main/java/gregtech/api/recipe/maps/PurificationUnitLaserFrontend.java
new file mode 100644
index 0000000000..df42259864
--- /dev/null
+++ b/src/main/java/gregtech/api/recipe/maps/PurificationUnitLaserFrontend.java
@@ -0,0 +1,36 @@
+package gregtech.api.recipe.maps;
+
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+
+import com.gtnewhorizons.modularui.api.math.Pos2d;
+
+import codechicken.nei.PositionedStack;
+import gregtech.api.recipe.BasicUIPropertiesBuilder;
+import gregtech.api.recipe.NEIRecipePropertiesBuilder;
+import gregtech.api.recipe.RecipeMapFrontend;
+import gregtech.common.gui.modularui.UIHelper;
+import gregtech.common.tileentities.machines.multi.purification.GT_MetaTileEntity_PurificationUnitUVTreatment;
+import gregtech.nei.GT_NEI_DefaultHandler;
+
+public class PurificationUnitLaserFrontend extends RecipeMapFrontend {
+
+ public PurificationUnitLaserFrontend(BasicUIPropertiesBuilder uiPropertiesBuilder,
+ NEIRecipePropertiesBuilder neiPropertiesBuilder) {
+ super(uiPropertiesBuilder, neiPropertiesBuilder);
+ }
+
+ @Override
+ public void drawNEIOverlays(GT_NEI_DefaultHandler.CachedDefaultRecipe neiCachedRecipe) {
+ final int numLenses = GT_MetaTileEntity_PurificationUnitUVTreatment.LENS_ITEMS.size();
+ List<Pos2d> positions = UIHelper.getGridPositions(numLenses, 12, -4, 3, 3);
+ // Put in lens items
+ for (int i = 0; i < numLenses; ++i) {
+ Pos2d position = positions.get(i);
+ ItemStack lens = GT_MetaTileEntity_PurificationUnitUVTreatment.LENS_ITEMS.get(i);
+ neiCachedRecipe.mInputs.add(new PositionedStack(lens, position.x, position.y, false));
+ }
+ super.drawNEIOverlays(neiCachedRecipe);
+ }
+}
diff --git a/src/main/java/gregtech/api/recipe/maps/PurificationUnitParticleExtractorFrontend.java b/src/main/java/gregtech/api/recipe/maps/PurificationUnitParticleExtractorFrontend.java
new file mode 100644
index 0000000000..bbbd88fd5f
--- /dev/null
+++ b/src/main/java/gregtech/api/recipe/maps/PurificationUnitParticleExtractorFrontend.java
@@ -0,0 +1,36 @@
+package gregtech.api.recipe.maps;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import net.minecraft.item.ItemStack;
+
+import com.gtnewhorizons.modularui.api.math.Pos2d;
+
+import codechicken.nei.PositionedStack;
+import gregtech.api.recipe.BasicUIPropertiesBuilder;
+import gregtech.api.recipe.NEIRecipePropertiesBuilder;
+import gregtech.api.recipe.RecipeMapFrontend;
+import gregtech.common.gui.modularui.UIHelper;
+import gregtech.nei.GT_NEI_DefaultHandler;
+
+public class PurificationUnitParticleExtractorFrontend extends RecipeMapFrontend {
+
+ public static final ArrayList<ItemStack> inputItems = new ArrayList<>();
+ public static final ArrayList<ItemStack> inputItemsShuffled = new ArrayList<>();
+
+ public PurificationUnitParticleExtractorFrontend(BasicUIPropertiesBuilder uiPropertiesBuilder,
+ NEIRecipePropertiesBuilder neiPropertiesBuilder) {
+ super(uiPropertiesBuilder, neiPropertiesBuilder);
+ }
+
+ @Override
+ public void drawNEIOverlays(GT_NEI_DefaultHandler.CachedDefaultRecipe neiCachedRecipe) {
+ List<Pos2d> positions = UIHelper.getGridPositions(2, 30, 14, 2, 1);
+ Pos2d pos1 = positions.get(0);
+ Pos2d pos2 = positions.get(1);
+ neiCachedRecipe.mInputs.set(0, new PositionedStack(inputItems, pos1.x, pos1.y, true));
+ neiCachedRecipe.mInputs.set(1, new PositionedStack(inputItemsShuffled, pos2.x, pos2.y, true));
+ super.drawNEIOverlays(neiCachedRecipe);
+ }
+}