aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/xmod/gregtech/api
diff options
context:
space:
mode:
authorAlkalus <Draknyte1@hotmail.com>2020-03-30 15:56:40 +0100
committerAlkalus <Draknyte1@hotmail.com>2020-03-30 15:56:40 +0100
commitb5cbe510e959ae0fe8803b5df1031f2752c50e30 (patch)
treeff2ead43d39d4721c3b7f3c10fbf396cb4e7a19c /src/Java/gtPlusPlus/xmod/gregtech/api
parent7bf528ec566132d6a4ae2726791feedbd5380823 (diff)
downloadGT5-Unofficial-b5cbe510e959ae0fe8803b5df1031f2752c50e30.tar.gz
GT5-Unofficial-b5cbe510e959ae0fe8803b5df1031f2752c50e30.tar.bz2
GT5-Unofficial-b5cbe510e959ae0fe8803b5df1031f2752c50e30.zip
+ Added IsaMill.
+ Added repackaged Sun classes. + Added Milled ores. + Added Milling Balls. $ Disabled Hand-pump pumping from non-GT tile entities. > Maybe did other things, but in a hurry to commit.
Diffstat (limited to 'src/Java/gtPlusPlus/xmod/gregtech/api')
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/api/enums/CustomOrePrefix.java89
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java15
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/api/interfaces/internal/IGregtech_RecipeAdder.java5
3 files changed, 108 insertions, 1 deletions
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/enums/CustomOrePrefix.java b/src/Java/gtPlusPlus/xmod/gregtech/api/enums/CustomOrePrefix.java
new file mode 100644
index 0000000000..050081fc82
--- /dev/null
+++ b/src/Java/gtPlusPlus/xmod/gregtech/api/enums/CustomOrePrefix.java
@@ -0,0 +1,89 @@
+package gtPlusPlus.xmod.gregtech.api.enums;
+
+import static gregtech.api.enums.GT_Values.B;
+
+import gregtech.api.enums.OrePrefixes;
+import gtPlusPlus.api.objects.Logger;
+import gtPlusPlus.core.lib.CORE;
+import net.minecraftforge.common.util.EnumHelper;
+
+public class CustomOrePrefix {
+
+ public static CustomOrePrefix Milled;
+
+ static {
+ Milled = new CustomOrePrefix("Milled Ores", "Milled ", " Ore", true, true, false, false, false, false, false, false, false, true, B[3], -1, 64, -1);
+ }
+
+ public static void init() {
+ // Does nothing except run the static{} block
+ }
+
+ private final String mLocalizedMaterialPre;
+
+ private CustomOrePrefix(
+ String aRegularLocalName,
+ String aLocalizedMaterialPre,
+ String aLocalizedMaterialPost,
+ boolean aIsUnificatable,
+ boolean aIsMaterialBased,
+ boolean aIsSelfReferencing,
+ boolean aIsContainer,
+ boolean aDontUnificateActively,
+ boolean aIsUsedForBlocks,
+ boolean aAllowNormalRecycling,
+ boolean aGenerateDefaultItem,
+ boolean aIsEnchantable,
+ boolean aIsUsedForOreProcessing,
+ int aMaterialGenerationBits,
+ long aMaterialAmount,
+ int aDefaultStackSize,
+ int aTextureindex) {
+
+ mLocalizedMaterialPre = aLocalizedMaterialPre;
+
+ // Add this to the GT Enum
+ EnumHelper.addEnum(OrePrefixes.class, aLocalizedMaterialPre, new Object[] {
+ aRegularLocalName,
+ aLocalizedMaterialPre,
+ aLocalizedMaterialPost,
+ aIsUnificatable,
+ aIsMaterialBased,
+ aIsSelfReferencing,
+ aIsContainer,
+ aDontUnificateActively,
+ aIsUsedForBlocks,
+ aAllowNormalRecycling,
+ aGenerateDefaultItem,
+ aIsEnchantable,
+ aIsUsedForOreProcessing,
+ aMaterialGenerationBits,
+ aMaterialAmount,
+ aDefaultStackSize,
+ aTextureindex}
+ );
+
+ Logger.INFO("Registered custom OrePrefixes '"+aLocalizedMaterialPre+"'. Success? "+checkEntryWasAdded(this));
+
+ }
+
+ private static final boolean checkEntryWasAdded(CustomOrePrefix aCustomPrefixObject) {
+ for (OrePrefixes o :OrePrefixes.values()) {
+ if (o.mLocalizedMaterialPre.equals(aCustomPrefixObject.mLocalizedMaterialPre)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ public static OrePrefixes get(CustomOrePrefix aCustomPrefixObject) {
+ for (OrePrefixes o :OrePrefixes.values()) {
+ if (o.mLocalizedMaterialPre.equals(aCustomPrefixObject.mLocalizedMaterialPre)) {
+ return o;
+ }
+ }
+ CORE.crash("Tried to obtain an invalid custom OrePrefixes object");
+ return null;
+ }
+
+}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java b/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java
index 9e084d5069..504533c406 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java
@@ -139,6 +139,11 @@ public enum GregtechItemList implements GregtechItemContainer {
Chip_MultiNerf_NoOutputBonus,
Chip_MultiNerf_NoSpeedBonus,
Chip_MultiNerf_NoEuBonus,
+
+ // Milling Balls
+ Milling_Ball_Alumina,
+ Milling_Ball_Soapstone,
+
//----------------------------------------------------------------------------
@@ -365,6 +370,15 @@ public enum GregtechItemList implements GregtechItemContainer {
// Large Rocket Engine
Casing_RocketEngine,
Controller_RocketEngine,
+
+ // Large Semi-Fluid
+ Controller_LargeSemifluidGenerator,
+
+ // IsaMill
+ Controller_IsaMill_Controller,
+ Casing_IsaMill_Casing,
+ Casing_IsaMill_Gearbox,
+ Casing_IsaMill_Pipe,
//----------------------------------------------------------------------------
@@ -592,7 +606,6 @@ public enum GregtechItemList implements GregtechItemContainer {
Generator_SemiFluid_LV,
Generator_SemiFluid_MV,
Generator_SemiFluid_HV,
- Controller_LargeSemifluidGenerator,
//Advanced Mixer 4x4
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/interfaces/internal/IGregtech_RecipeAdder.java b/src/Java/gtPlusPlus/xmod/gregtech/api/interfaces/internal/IGregtech_RecipeAdder.java
index 2db81d693e..688433b3ac 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/api/interfaces/internal/IGregtech_RecipeAdder.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/api/interfaces/internal/IGregtech_RecipeAdder.java
@@ -1,5 +1,7 @@
package gtPlusPlus.xmod.gregtech.api.interfaces.internal;
+import gregtech.api.enums.Materials;
+import gtPlusPlus.core.material.Material;
import net.minecraft.item.ItemStack;
import net.minecraftforge.fluids.FluidStack;
@@ -283,6 +285,9 @@ public interface IGregtech_RecipeAdder {
public boolean addDistilleryRecipe(ItemStack aCircuit, FluidStack aInput, FluidStack aOutput, ItemStack aSolidOutput, int aDuration, int aEUt, boolean aHidden);
public boolean addPulverisationRecipe(final ItemStack aInput, ItemStack aOutput1, ItemStack aOutput2, final ItemStack aOutput3);
+
+ public boolean addMillingRecipe(Materials aMat, int aEU);
+ public boolean addMillingRecipe(Material aMat, int aEU);
}