diff options
author | Alkalus <3060479+draknyte1@users.noreply.github.com> | 2022-01-15 13:29:00 +0000 |
---|---|---|
committer | Alkalus <3060479+draknyte1@users.noreply.github.com> | 2022-01-15 13:29:00 +0000 |
commit | 860bded5892357e4575595c71ccce5a0351abe12 (patch) | |
tree | a05a86e185c6ef2a0401344329eb671f43ff8281 /src/main/java/gtPlusPlus/xmod/gregtech/loaders | |
parent | d3c655a124b349fa7f78b52ca9651c2c4140198a (diff) | |
download | GT5-Unofficial-860bded5892357e4575595c71ccce5a0351abe12.tar.gz GT5-Unofficial-860bded5892357e4575595c71ccce5a0351abe12.tar.bz2 GT5-Unofficial-860bded5892357e4575595c71ccce5a0351abe12.zip |
Added ability for GT++ Plates and Foils to be used as covers.
Added missing foil recipes.
Diffstat (limited to 'src/main/java/gtPlusPlus/xmod/gregtech/loaders')
-rw-r--r-- | src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_Plates.java | 18 | ||||
-rw-r--r-- | src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_ShapedCrafting.java | 14 |
2 files changed, 31 insertions, 1 deletions
diff --git a/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_Plates.java b/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_Plates.java index 56d11520d0..6b512f4b3a 100644 --- a/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_Plates.java +++ b/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_Plates.java @@ -6,6 +6,8 @@ import java.util.Set; import gregtech.api.GregTech_API; import gregtech.api.enums.GT_Values; import gregtech.api.enums.ItemList; +import gregtech.api.objects.GT_RenderedTexture; +import gregtech.api.render.TextureFactory; import gregtech.api.util.GT_Recipe; import gtPlusPlus.api.interfaces.RunnableWithInfo; import gtPlusPlus.api.objects.Logger; @@ -93,7 +95,7 @@ public class RecipeGen_Plates extends RecipeGen_Base { Logger.WARNING("Cutting Machine Recipe: "+material.getLocalizedName()+" - Success"); } else { - Logger.WARNING("ACutting Machine Recipe: "+material.getLocalizedName()+" - Failed"); + Logger.WARNING("Cutting Machine Recipe: "+material.getLocalizedName()+" - Failed"); } @@ -121,6 +123,20 @@ public class RecipeGen_Plates extends RecipeGen_Base { else { Logger.WARNING("Bender Recipe: "+material.getLocalizedName()+" - Failed"); } + + //Bender + if (ItemUtils.checkForInvalidItems(material.getPlate(1)) && ItemUtils.checkForInvalidItems(material.getFoil(1))) + if (addBenderRecipe( + material.getPlate(1), + material.getFoil(4), + (int) Math.max(material.getMass(), 1L), + material.vVoltageMultiplier)){ + GregTech_API.registerCover(material.getFoil(1), new GT_RenderedTexture(material.getTextureSet().mTextures[70], material.getRGBA(), false), null); + Logger.WARNING("Bender Foil Recipe: "+material.getLocalizedName()+" - Success"); + } + else { + Logger.WARNING("Bender Foil Recipe: "+material.getLocalizedName()+" - Failed"); + } } public static boolean addBenderRecipe(final ItemStack aInput1, final ItemStack aOutput1, int aDuration, final int aEUt) { diff --git a/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_ShapedCrafting.java b/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_ShapedCrafting.java index 7a596c3c42..1a6221b09e 100644 --- a/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_ShapedCrafting.java +++ b/src/main/java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_ShapedCrafting.java @@ -192,6 +192,20 @@ public class RecipeGen_ShapedCrafting extends RecipeGen_Base { Logger.WARNING("Fine Wire Recipe: "+material.getLocalizedName()+" - Failed"); } } + + //Shaped Recipe - Foil + if (ItemUtils.checkForInvalidItems(material.getFoil(1)) && ItemUtils.checkForInvalidItems(material.getPlate(1))) { + if (RecipeUtils.addShapedRecipe( + CI.craftingToolHammer_Hard, material.getPlate(1), null, + null, null, null, + null, null, null, + material.getFoil(2))){ + Logger.WARNING("Foil Recipe: "+material.getLocalizedName()+" - Success"); + } + else { + Logger.WARNING("Foil Recipe: "+material.getLocalizedName()+" - Failed"); + } + } //Shaped Recipe - Ingot to Rod |