aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlkalus <3060479+draknyte1@users.noreply.github.com>2020-01-17 12:36:00 +0000
committerAlkalus <3060479+draknyte1@users.noreply.github.com>2020-01-17 12:36:00 +0000
commit3f35b4b0183ea16d623cdcf74447a11f4734ce45 (patch)
tree695afdc9abf2a481ae261e5bafea45e90482dcb3
parent72696a0dd5ca5c0cb2a1017cc1e0bb36669d0ce7 (diff)
downloadGT5-Unofficial-3f35b4b0183ea16d623cdcf74447a11f4734ce45.tar.gz
GT5-Unofficial-3f35b4b0183ea16d623cdcf74447a11f4734ce45.tar.bz2
GT5-Unofficial-3f35b4b0183ea16d623cdcf74447a11f4734ce45.zip
+ Added Zyngen.
% Adjusted Volcanus casing requirement from 10 to 9. % Adjusted logging in RF convertor. % Adjusted tooltip on Washplant to include information on water hatch. $ Fixed coil handling being offset by a tier. $ Fixed 9-1 breaking if an Input Bus didn't have a circuit.
-rw-r--r--src/Java/gtPlusPlus/core/block/ModBlocks.java4
-rw-r--r--src/Java/gtPlusPlus/core/handler/BookHandler.java2
-rw-r--r--src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java2
-rw-r--r--src/Java/gtPlusPlus/core/recipe/common/CI.java4
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java3
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/StaticFields59.java32
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/generators/GT_MetaTileEntity_RfConvertor.java22
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialAlloySmelter.java380
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialMultiMachine.java420
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialWashPlant.java3
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/advanced/GregtechMetaTileEntity_Adv_EBF.java4
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/loaders/Gregtech_Blocks.java2
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechIndustrialAlloySmelter.java22
13 files changed, 463 insertions, 437 deletions
diff --git a/src/Java/gtPlusPlus/core/block/ModBlocks.java b/src/Java/gtPlusPlus/core/block/ModBlocks.java
index 4bc5908f98..db9ad2264c 100644
--- a/src/Java/gtPlusPlus/core/block/ModBlocks.java
+++ b/src/Java/gtPlusPlus/core/block/ModBlocks.java
@@ -55,7 +55,8 @@ public final class ModBlocks {
public static Block blockCasingsMisc;
public static Block blockCasings2Misc;
public static Block blockCasings3Misc;
- public static Block blockCasings4Misc;
+ public static Block blockCasings4Misc;
+ public static Block blockCasingsTieredGTPP;
public static Block blockMetaTileEntity;
public static Block blockHeliumGenerator;
@@ -97,7 +98,6 @@ public final class ModBlocks {
public static Block blockPooCollector;
public static Block blockPestKiller;
- public static GregtechMetaTieredCasingBlocks1 BlockTieredCasings1;
public static void init() {
Logger.INFO("Initializing Blocks.");
diff --git a/src/Java/gtPlusPlus/core/handler/BookHandler.java b/src/Java/gtPlusPlus/core/handler/BookHandler.java
index 860946f513..d9d3efe680 100644
--- a/src/Java/gtPlusPlus/core/handler/BookHandler.java
+++ b/src/Java/gtPlusPlus/core/handler/BookHandler.java
@@ -125,7 +125,7 @@ public class BookHandler {
"The Mode can be set by using a Screwdriver on the controller block. Each mode allows the use of Numbered Circuits, to allow a different machine 'type' for each input bus.",
"[Metal Work] Mode A - Allows the multiblock to function as a Compressor, a Lathe or an Electro-Magnet. To allow a hatch to run in Compressor mode, insert a No. 20 circuit. For Lathe, use No. 21 and for Electro-Magnet use No. 22.",
"[Fluid Work] Mode B - Allows the multiblock to function as a Fermenter, a Fluid Extractor or an Extractor. To allow a hatch to run in Fermenter mode, insert a No. 20 circuit. For Fluid Extractor, use No. 21 and for Extractor use No. 22.",
- "[Misc. Work] Mode C - Allows the multiblock to function as a Laser Engraver, a Replicator or an Autoclave. To allow a hatch to run in Laser Engraver mode, insert a No. 20 circuit. For Autoclave, use No. 21 and for Replicator use No. 22. REPLICATOR DISABLED.",
+ "[Misc. Work] Mode C - Allows the multiblock to function as a Laser Engraver, an Autoclave or a Fluid Solidifier. To allow a hatch to run in Laser Engraver mode, insert a No. 20 circuit. For Autoclave, use No. 21 and for Solidifier use No. 22.",
});
book_NuclearManual = writeBookTemplate(
diff --git a/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java b/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java
index be02e352c7..d7c971e71f 100644
--- a/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java
+++ b/src/Java/gtPlusPlus/core/handler/COMPAT_HANDLER.java
@@ -68,6 +68,7 @@ import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialCuttingF
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialElectrolyzer;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialExtruder;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialFishPond;
+import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialAlloySmelter;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialFuelRefinery;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialGeneratorArray;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechIndustrialMacerator;
@@ -216,6 +217,7 @@ public class COMPAT_HANDLER {
GregtechPowerBreakers.run();
GregtechFluidReactor.run();
GregtechAlgaeContent.run();
+ GregtechIndustrialAlloySmelter.run();
//New Horizons Content
NewHorizonsAccelerator.run();
diff --git a/src/Java/gtPlusPlus/core/recipe/common/CI.java b/src/Java/gtPlusPlus/core/recipe/common/CI.java
index 6fae81e85f..f2b67bfe68 100644
--- a/src/Java/gtPlusPlus/core/recipe/common/CI.java
+++ b/src/Java/gtPlusPlus/core/recipe/common/CI.java
@@ -564,7 +564,7 @@ public class CI {
private static final Material[] aMaterial_Secondary = new Material[] {
ALLOY.STEEL,
ALLOY.SILICON_CARBIDE,
- ALLOY.TUNGSTEN_CARBIDE,
+ ALLOY.BABBIT_ALLOY,
ALLOY.INCONEL_690,
ALLOY.STELLITE,
ALLOY.ARCANITE,
@@ -579,7 +579,7 @@ public class CI {
private static final Material[] aMaterial_Tertiary = new Material[] {
ELEMENT.getInstance().LEAD,
ELEMENT.getInstance().ALUMINIUM,
- ALLOY.STAINLESS_STEEL,
+ ELEMENT.STANDALONE.BLACK_METAL,
ELEMENT.getInstance().TUNGSTEN,
ALLOY.HASTELLOY_N,
ALLOY.ENERGYCRYSTAL,
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java b/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java
index 2baf4157a6..cd4b0947e4 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/api/enums/GregtechItemList.java
@@ -155,6 +155,9 @@ public enum GregtechItemList implements GregtechItemContainer {
Industrial_Centrifuge,
Casing_Centrifuge1,
+ // Large Alloy Smelter
+ Industrial_AlloySmelter,
+
//Coke Oven
Industrial_CokeOven,
Casing_CokeOven,
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/StaticFields59.java b/src/Java/gtPlusPlus/xmod/gregtech/common/StaticFields59.java
index 814ed589f0..74e269e932 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/StaticFields59.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/StaticFields59.java
@@ -238,44 +238,51 @@ public class StaticFields59 {
return null;
}
- public static int getHeatingCapacityForCoil(Block aBlock, int aMeta) {
+
+
+ public static int getTierForCoil(Block aBlock, int aMeta) {
if (aBlock == GregTech_API.sBlockCasings1 && (aMeta >= 12 && aMeta <= 14)) {
- return getHeatingCapacityForCoilTier(aMeta == 12 ? 1 : aMeta == 13 ? 2 : 3);
+ return aMeta == 12 ? 1 : aMeta == 13 ? 2 : 3;
}
else if (aBlock == getBlockCasings5() && (aMeta >= 0 && aMeta <= 8)) {
- return getHeatingCapacityForCoilTier(aMeta);
+ return aMeta;
}
return 0;
}
+ public static int getHeatingCapacityForCoil(Block aBlock, int aMeta) {
+ int aTier = getTierForCoil(aBlock, aMeta);
+ return aTier > 0 ? getHeatingCapacityForCoilTier(aTier) : 0;
+ }
+
public static int getHeatingCapacityForCoilTier(int aCoilTier) {
int mHeatingCapacity = 0;
switch (aCoilTier) {
- case 0:
+ case 1:
mHeatingCapacity = 1800;
break;
- case 1:
+ case 2:
mHeatingCapacity = 2700;
break;
- case 2:
+ case 3:
mHeatingCapacity = 3600;
break;
- case 3:
+ case 4:
mHeatingCapacity = 4500;
break;
- case 4:
+ case 5:
mHeatingCapacity = 5400;
break;
- case 5:
+ case 6:
mHeatingCapacity = 7200;
break;
- case 6:
+ case 7:
mHeatingCapacity = 9000;
break;
- case 7:
+ case 8:
mHeatingCapacity = 9900;
break;
- case 8:
+ case 9:
mHeatingCapacity = 10800;
break;
default:
@@ -285,7 +292,6 @@ public class StaticFields59 {
if (CORE.GTNH && aCoilTier <= 6) {
mHeatingCapacity += 1;
}
-
return mHeatingCapacity;
}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/generators/GT_MetaTileEntity_RfConvertor.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/generators/GT_MetaTileEntity_RfConvertor.java
index ee37f50060..08356dd6ef 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/generators/GT_MetaTileEntity_RfConvertor.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/generators/GT_MetaTileEntity_RfConvertor.java
@@ -246,7 +246,7 @@ public class GT_MetaTileEntity_RfConvertor extends GregtechMetaEnergyBuffer impl
return 0;
}
- Logger.INFO("Someone is trying to inject RF from "+from+". Type:"+tTileEntity.getClass().getName());
+ Logger.WARNING("Someone is trying to inject RF from "+from+". Type:"+tTileEntity.getClass().getName());
// Calculate maximum RF we need to consume
int aInputRF = MathUtils.safeInt(this.maxEUOutput() * GregTech_API.mEUtoRF / 100);
@@ -261,22 +261,22 @@ public class GT_MetaTileEntity_RfConvertor extends GregtechMetaEnergyBuffer impl
long aStoredEU = this.getEUVar();
long aMaxEU = this.maxEUStore();
- Logger.INFO("Stored: "+aStoredEU+", Capacity: "+aMaxEU+"");
+ Logger.WARNING("Stored: "+aStoredEU+", Capacity: "+aMaxEU+"");
if (aStoredEU < aMaxEU) {
- Logger.INFO("StoredEU < MaxEU");
+ Logger.WARNING("StoredEU < MaxEU");
long aRemainingSpace = aMaxEU - aStoredEU;
if (aRemainingSpace > 0) {
long tEU = 0;
byte aSide = (byte) from.ordinal();
- Logger.INFO("Free: "+aRemainingSpace+"EU");
+ Logger.WARNING("Free: "+aRemainingSpace+"EU");
if (tTileEntity instanceof IEnergyProvider && ((IEnergyProvider) tTileEntity).extractEnergy(ForgeDirection.getOrientation(GT_Utility.getOppositeSide(aSide)), 1, true) == 1) {
tEU = (long) ((IEnergyProvider) tTileEntity).extractEnergy(ForgeDirection.getOrientation(GT_Utility.getOppositeSide(aSide)), (int) maxEUOutput() * 100 / GregTech_API.mRFtoEU, false);
- Logger.INFO("Drained from IEnergyProvider Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
+ Logger.WARNING("Drained from IEnergyProvider Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
tEU = tEU * GregTech_API.mRFtoEU / 100;
}
else if (tTileEntity instanceof IEnergyStorage && ((IEnergyStorage) tTileEntity).extractEnergy(1, true) == 1) {
tEU = (long) ((IEnergyStorage) tTileEntity).extractEnergy((int) maxEUOutput() * 100 / GregTech_API.mRFtoEU, false);
- Logger.INFO("Drained from IEnergyStorage Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
+ Logger.WARNING("Drained from IEnergyStorage Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
tEU = tEU * GregTech_API.mRFtoEU / 100;
}
else if (GregTech_API.meIOLoaded && tTileEntity instanceof IPowerContainer && ((IPowerContainer) tTileEntity).getEnergyStored() > 0) {
@@ -287,27 +287,27 @@ public class GT_MetaTileEntity_RfConvertor extends GregtechMetaEnergyBuffer impl
ICapBankNetwork network = ((TileCapBank) tTileEntity).getNetwork();
if (network != null && network.getEnergyStoredL() > 0) {
tEU = Math.min((Math.min(Math.min(network.getEnergyStoredL(), storedRF - extractRF), network.getMaxOutput())) * GregTech_API.mRFtoEU / 100, maxEUOutput());
- Logger.INFO("Drained from EIO CapBank Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
+ Logger.WARNING("Drained from EIO CapBank Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
network.addEnergy((int) -(tEU * 100 / GregTech_API.mRFtoEU));
}
} else {
if (storedRF > extractRF) {
((IPowerContainer) tTileEntity).setEnergyStored(storedRF - extractRF);
tEU = maxEUOutput();
- Logger.INFO("Drained from EIO Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
+ Logger.WARNING("Drained from EIO Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
} else {
((IPowerContainer) tTileEntity).setEnergyStored(0);
tEU = storedRF * GregTech_API.mRFtoEU / 100;
- Logger.INFO("Drained from EIO Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
+ Logger.WARNING("Drained from EIO Tile: "+(tEU * 100 / GregTech_API.mRFtoEU)+"");
}
}
}
- Logger.INFO("EU to inject: "+tEU+"EU");
+ Logger.WARNING("EU to inject: "+tEU+"EU");
if (!simulate) {
aVal = this.getBaseMetaTileEntity().increaseStoredEnergyUnits(tEU, true);
}
if (tEU > 0) {
- Logger.INFO("Tried injecting "+tEU+" eu into self. Success? "+aVal);
+ Logger.WARNING("Tried injecting "+tEU+" eu into self. Success? "+aVal);
}
}
}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialAlloySmelter.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialAlloySmelter.java
new file mode 100644
index 0000000000..ddbd87da64
--- /dev/null
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialAlloySmelter.java
@@ -0,0 +1,380 @@
+package gtPlusPlus.xmod.gregtech.common.tileentities.machines.multi.processing;
+
+import static gtPlusPlus.core.util.data.ArrayUtils.removeNulls;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.apache.commons.lang3.ArrayUtils;
+
+import gregtech.api.enums.TAE;
+import gregtech.api.enums.Textures;
+import gregtech.api.gui.GT_GUIContainer_MultiMachine;
+import gregtech.api.interfaces.ITexture;
+import gregtech.api.interfaces.metatileentity.IMetaTileEntity;
+import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
+import gregtech.api.objects.GT_RenderedTexture;
+import gregtech.api.util.GT_Recipe;
+import gregtech.api.util.GT_Utility;
+import gtPlusPlus.api.objects.Logger;
+import gtPlusPlus.core.block.ModBlocks;
+import gtPlusPlus.xmod.gregtech.api.metatileentity.implementations.base.GregtechMeta_MultiBlockBase;
+import gtPlusPlus.xmod.gregtech.common.StaticFields59;
+import net.minecraft.block.Block;
+import net.minecraft.entity.player.InventoryPlayer;
+import net.minecraft.item.ItemStack;
+import net.minecraftforge.common.util.ForgeDirection;
+import net.minecraftforge.fluids.FluidStack;
+
+public class GregtechMetaTileEntity_IndustrialAlloySmelter extends GregtechMeta_MultiBlockBase {
+
+ public static int CASING_TEXTURE_ID;
+ private int mHeatingCapacity = 0;
+ private int mLevel = 0;
+
+ public GregtechMetaTileEntity_IndustrialAlloySmelter(int aID, String aName, String aNameRegional) {
+ super(aID, aName, aNameRegional);
+ CASING_TEXTURE_ID = TAE.getIndexFromPage(2, 1);
+ }
+
+ public GregtechMetaTileEntity_IndustrialAlloySmelter(String aName) {
+ super(aName);
+ CASING_TEXTURE_ID = TAE.getIndexFromPage(2, 1);
+ }
+
+ public IMetaTileEntity newMetaEntity(IGregTechTileEntity aTileEntity) {
+ return new GregtechMetaTileEntity_IndustrialAlloySmelter(this.mName);
+ }
+
+ public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex, boolean aActive, boolean aRedstone) {
+ if (aSide == aFacing) {
+ return new ITexture[]{Textures.BlockIcons.CASING_BLOCKS[CASING_TEXTURE_ID], new GT_RenderedTexture(aActive ? Textures.BlockIcons.OVERLAY_FRONT_MULTI_SMELTER_ACTIVE : Textures.BlockIcons.OVERLAY_FRONT_MULTI_SMELTER)};
+ }
+ return new ITexture[]{Textures.BlockIcons.CASING_BLOCKS[CASING_TEXTURE_ID]};
+ }
+
+ public Object getClientGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) {
+ return new GT_GUIContainer_MultiMachine(aPlayerInventory, aBaseMetaTileEntity, getLocalName(), "MultiFurnace.png");
+ }
+
+ public GT_Recipe.GT_Recipe_Map getRecipeMap() {
+ return GT_Recipe.GT_Recipe_Map.sAlloySmelterRecipes;
+ }
+
+ public boolean isCorrectMachinePart(ItemStack aStack) {
+ return true;
+ }
+
+ public boolean isFacingValid(byte aFacing) {
+ return aFacing > 1;
+ }
+
+ public int getMaxEfficiency(ItemStack aStack) {
+ return 10000;
+ }
+
+ public int getPollutionPerTick(ItemStack aStack) {
+ return 15;
+ }
+
+ public int getDamageToComponent(ItemStack aStack) {
+ return 0;
+ }
+
+ public boolean explodesOnComponentBreak(ItemStack aStack) {
+ return false;
+ }
+
+ @Override
+ public boolean hasSlotInGUI() {
+ return false;
+ }
+
+ @Override
+ public String getCustomGUIResourceName() {
+ return null;
+ }
+
+ @Override
+ public String getMachineType() {
+ return "Alloy Smelter";
+ }
+
+ @Override
+ public String[] getTooltip() {
+ return new String[]{
+ "Controller Block for the Industrial Alloy Smelter",
+ "Gains one parallel per voltage tier",
+ "Gains one multiplier per coil tier",
+ "parallel = tier * coil tier",
+ "Gains 5% speed bonus per coil tier",
+ "Size(WxHxD): 3x5x3 (Hollow)",
+ "Controller (Front middle at bottom)",
+ "Inconel Reinforced Casings (layers 0/4, 10 at least!)",
+ "16x Heating Coils (layers 1/3, hollow)",
+ "8x Integral Encasement V (middle layer, hollow)",
+ "1x Input Bus",
+ "1x Output Bus",
+ "1x Output Hatch",
+ "1x Energy Hatch",
+ };
+ }
+
+ @Override
+ public int getMaxParallelRecipes() {
+ return (this.mLevel * GT_Utility.getTier(this.getMaxInputVoltage()));
+ }
+
+ @Override
+ public int getEuDiscountForParallelism() {
+ return 0;
+ }
+
+ @Override
+ public boolean checkMultiblock(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
+ int xDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetX;
+ int zDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetZ;
+
+ this.mLevel = 0;
+ this.mHeatingCapacity = 0;
+ for (int i=1;i<4;i++) {
+ if (!aBaseMetaTileEntity.getAirOffset(xDir, i, zDir)) {
+ Logger.INFO("Did not find air inside on layer "+i);
+ return false;
+ }
+ }
+ /*if (!addMufflerToMachineList(aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir, 3, zDir),
+ CASING_TEXTURE_ID)) {
+ return false;
+ }*/
+ Block tUsedBlock = aBaseMetaTileEntity.getBlockOffset(xDir + 1, 1, zDir);
+ byte tUsedMeta = aBaseMetaTileEntity.getMetaIDOffset(xDir + 1, 1, zDir);
+ this.mLevel = StaticFields59.getTierForCoil(tUsedBlock, tUsedMeta);
+ this.mHeatingCapacity = StaticFields59.getHeatingCapacityForCoil(tUsedBlock, tUsedMeta);
+
+ int aCasingCount = 0;
+
+ for (int i = -1; i < 2; i++) {
+ for (int j = -1; j < 2; j++) {
+
+ if ((i != 0) || (j != 0)) {
+ //Coils 1
+ if (!isValidBlockForStructure(null, CASING_TEXTURE_ID, false, aBaseMetaTileEntity.getBlockOffset(xDir + i, 1, zDir + j), (int) aBaseMetaTileEntity.getMetaIDOffset(xDir + i, 1, zDir + j), StaticFields59.getBlockCasings5(), tUsedMeta)) {
+ Logger.INFO("Heating Coils missing. First Layer");
+ return false;
+ }
+
+ //Integral Casings
+ if (!isValidBlockForStructure(null, CASING_TEXTURE_ID, false, aBaseMetaTileEntity.getBlockOffset(xDir + i, 2, zDir + j), (int) aBaseMetaTileEntity.getMetaIDOffset(xDir + i, 2, zDir + j), ModBlocks.blockCasingsTieredGTPP, 4)) {
+ Logger.INFO("Integral Framework missing. Second Layer");
+ return false;
+ }
+
+ //Coils 2
+ if (!isValidBlockForStructure(null, CASING_TEXTURE_ID, false, aBaseMetaTileEntity.getBlockOffset(xDir + i, 3, zDir + j), (int) aBaseMetaTileEntity.getMetaIDOffset(xDir + i, 3, zDir + j), StaticFields59.getBlockCasings5(), tUsedMeta)) {
+ Logger.INFO("Heating Coils missing. Third Layer");
+ return false;
+ }
+ }
+
+ //Top Layer
+
+ Block aCurrentBlock = aBaseMetaTileEntity.getBlockOffset(xDir + i, 4, zDir + j);
+ int aCurrentMeta = (int) aBaseMetaTileEntity.getMetaIDOffset(xDir + i, 4, zDir + j);
+ if (aCurrentBlock == ModBlocks.blockCasings3Misc && aCurrentMeta == 1) {
+ aCasingCount++;
+ }
+
+ final IGregTechTileEntity tTileEntity2 = aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir + i, 4, zDir + j);
+ if (!isValidBlockForStructure(tTileEntity2, CASING_TEXTURE_ID, true, aCurrentBlock, aCurrentMeta, ModBlocks.blockCasings3Misc, 1)) {
+ Logger.INFO("Top Layer missing.");
+ return false;
+ }
+ }
+ }
+ for (int i = -1; i < 2; i++) {
+ for (int j = -1; j < 2; j++) {
+
+
+ Block aCurrentBlock = aBaseMetaTileEntity.getBlockOffset(xDir + i, 0, zDir + j);
+ int aCurrentMeta = (int) aBaseMetaTileEntity.getMetaIDOffset(xDir + i, 0, zDir + j);
+ if (aCurrentBlock == ModBlocks.blockCasings3Misc && aCurrentMeta == 1) {
+ aCasingCount++;
+ }
+ if ((xDir + i != 0) || (zDir + j != 0)) {
+ IGregTechTileEntity tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir + i, 0, zDir + j);
+ if (!isValidBlockForStructure(tTileEntity, CASING_TEXTURE_ID, true, aCurrentBlock, aCurrentMeta, ModBlocks.blockCasings3Misc, 1)) {
+ Logger.INFO("Bottom Layer missing.");
+ return false;
+ }
+ }
+ }
+ }
+
+ return aCasingCount >= 10;
+ }
+
+ public boolean checkRecipe(ItemStack aStack) {
+ return checkRecipeGeneric(this.getMaxParallelRecipes(), 0, 5 * this.mLevel); // Will have to clone the logic from parent class to handle heating coil
+ // tiers.
+ }
+
+ @Override
+ public boolean checkRecipeGeneric(ItemStack[] aItemInputs, FluidStack[] aFluidInputs, int aMaxParallelRecipes,
+ int aEUPercent, int aSpeedBonusPercent, int aOutputChanceRoll) {
+ // Based on the Processing Array. A bit overkill, but very flexible.
+
+ // Reset outputs and progress stats
+ this.mEUt = 0;
+ this.mMaxProgresstime = 0;
+ this.mOutputItems = new ItemStack[] {};
+ this.mOutputFluids = new FluidStack[] {};
+
+ long tVoltage = getMaxInputVoltage();
+ byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
+ long tEnergy = getMaxInputEnergy();
+ Logger.WARNING("Running checkRecipeGeneric(0)");
+
+ GT_Recipe tRecipe = this.getRecipeMap().findRecipe(getBaseMetaTileEntity(), mLastRecipe, false,
+ gregtech.api.enums.GT_Values.V[tTier], aFluidInputs, aItemInputs);
+
+ Logger.WARNING("Running checkRecipeGeneric(1)");
+ // Remember last recipe - an optimization for findRecipe()
+ this.mLastRecipe = tRecipe;
+
+ if (tRecipe == null) {
+ Logger.WARNING("BAD RETURN - 1");
+ return false;
+ }
+
+ aMaxParallelRecipes = this.canBufferOutputs(tRecipe, aMaxParallelRecipes);
+ if (aMaxParallelRecipes == 0) {
+ Logger.WARNING("BAD RETURN - 2");
+ return false;
+ }
+
+ // EU discount
+ float tRecipeEUt = (tRecipe.mEUt * aEUPercent) / 100.0f;
+ int tHeatCapacityDivTiers = mHeatingCapacity / 900;
+ if (tHeatCapacityDivTiers > 0) {
+ tRecipeEUt = (int) (tRecipeEUt * (Math.pow(0.95, tHeatCapacityDivTiers)));
+ }
+ float tTotalEUt = 0.0f;
+
+ int parallelRecipes = 0;
+ // Count recipes to do in parallel, consuming input items and fluids and
+ // considering input voltage limits
+ for (; parallelRecipes < aMaxParallelRecipes && tTotalEUt < (tEnergy - tRecipeEUt); parallelRecipes++) {
+ if (!tRecipe.isRecipeInputEqual(true, aFluidInputs, aItemInputs)) {
+ Logger.WARNING("Broke at " + parallelRecipes + ".");
+ break;
+ }
+ Logger.WARNING("Bumped EU from " + tTotalEUt + " to " + (tTotalEUt + tRecipeEUt) + ".");
+ tTotalEUt += tRecipeEUt;
+ }
+
+ if (parallelRecipes == 0) {
+ Logger.WARNING("BAD RETURN - 3");
+ return false;
+ }
+
+ // -- Try not to fail after this point - inputs have already been consumed! --
+
+ // Convert speed bonus to duration multiplier
+ // e.g. 100% speed bonus = 200% speed = 100%/200% = 50% recipe duration.
+ aSpeedBonusPercent = Math.max(-99, aSpeedBonusPercent);
+ float tTimeFactor = 100.0f / (100.0f + aSpeedBonusPercent);
+ this.mMaxProgresstime = (int) (tRecipe.mDuration * tTimeFactor);
+ int rInt = 2;
+
+ this.mEUt = (int) Math.ceil(tTotalEUt);
+
+ this.mEfficiency = (10000 - (getIdealStatus() - getRepairStatus()) * 1000);
+ this.mEfficiencyIncrease = 10000;
+
+ // Overclock
+ if (this.mEUt <= 16) {
+ this.mEUt = (this.mEUt * (1 << tTier - 1) * (1 << tTier - 1));
+ this.mMaxProgresstime = (this.mMaxProgresstime / (1 << tTier - 1));
+ } else {
+ while (this.mEUt <= gregtech.api.enums.GT_Values.V[(tTier - 1)]) {
+ this.mEUt *= 4;
+ this.mMaxProgresstime /= (tHeatCapacityDivTiers >= rInt ? 4 : 2);
+ }
+ }
+ if (this.mEUt > 0) {
+ this.mEUt = (-this.mEUt);
+ }
+
+ this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
+
+ // Collect fluid outputs
+ FluidStack[] tOutputFluids = new FluidStack[tRecipe.mFluidOutputs.length];
+ for (int h = 0; h < tRecipe.mFluidOutputs.length; h++) {
+ if (tRecipe.getFluidOutput(h) != null) {
+ tOutputFluids[h] = tRecipe.getFluidOutput(h).copy();
+ tOutputFluids[h].amount *= parallelRecipes;
+ }
+ }
+
+ // Collect output item types
+ ItemStack[] tOutputItems = new ItemStack[tRecipe.mOutputs.length];
+ for (int h = 0; h < tRecipe.mOutputs.length; h++) {
+ if (tRecipe.getOutput(h) != null) {
+ tOutputItems[h] = tRecipe.getOutput(h).copy();
+ tOutputItems[h].stackSize = 0;
+ }
+ }
+
+ // Set output item stack sizes (taking output chance into account)
+ for (int f = 0; f < tOutputItems.length; f++) {
+ if (tRecipe.mOutputs[f] != null && tOutputItems[f] != null) {
+ for (int g = 0; g < parallelRecipes; g++) {
+ if (getBaseMetaTileEntity().getRandomNumber(aOutputChanceRoll) < tRecipe.getOutputChance(f))
+ tOutputItems[f].stackSize += tRecipe.mOutputs[f].stackSize;
+ }
+ }
+ }
+
+ tOutputItems = removeNulls(tOutputItems);
+
+ // Sanitize item stack size, splitting any stacks greater than max stack size
+ List<ItemStack> splitStacks = new ArrayList<ItemStack>();
+ for (ItemStack tItem : tOutputItems) {
+ while (tItem.getMaxStackSize() < tItem.stackSize) {
+ ItemStack tmp = tItem.copy();
+ tmp.stackSize = tmp.getMaxStackSize();
+ tItem.stackSize = tItem.stackSize - tItem.getMaxStackSize();
+ splitStacks.add(tmp);
+ }
+ }
+
+ if (splitStacks.size() > 0) {
+ ItemStack[] tmp = new ItemStack[splitStacks.size()];
+ tmp = splitStacks.toArray(tmp);
+ tOutputItems = ArrayUtils.addAll(tOutputItems, tmp);
+ }
+
+ // Strip empty stacks
+ List<ItemStack> tSList = new ArrayList<ItemStack>();
+ for (ItemStack tS : tOutputItems) {
+ if (tS.stackSize > 0)
+ tSList.add(tS);
+ }
+ tOutputItems = tSList.toArray(new ItemStack[tSList.size()]);
+
+ // Commit outputs
+ this.mOutputItems = tOutputItems;
+ this.mOutputFluids = tOutputFluids;
+ updateSlots();
+
+ // Play sounds (GT++ addition - GT multiblocks play no sounds)
+ startProcess();
+
+ Logger.WARNING("GOOD RETURN - 1");
+ return true;
+
+ }
+
+
+}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialMultiMachine.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialMultiMachine.java
index b071c77d15..05aec14500 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialMultiMachine.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialMultiMachine.java
@@ -55,12 +55,12 @@ extends GregtechMeta_MultiBlockBase {
private static final int MODE_EXTRACTOR = 5;
private static final int MODE_LASER = 6;
private static final int MODE_AUTOCLAVE = 7;
- private static final int MODE_REPLICATOR = 8;
+ private static final int MODE_FLUIDSOLIDIFY = 8;
private static final int[][] MODE_MAP = new int[][] {{0, 1, 2}, {3, 4, 5}, {6, 7, 8}};
public static final String[] aToolTipNames = new String[9];
static {
- for (int id = 0; id < 8; id++) {
+ for (int id = 0; id < 9; id++) {
String aNEI = GT_LanguageManager.getTranslation(getRecipeMap(id).mUnlocalizedName);
aToolTipNames[id] = aNEI != null ? aNEI : "BAD NEI NAME (Report to Github)";
}
@@ -143,7 +143,17 @@ extends GregtechMeta_MultiBlockBase {
tBusItems.add(tBus.getBaseMetaTileEntity().getStackInSlot(i));
}
}
-
+
+ boolean aFoundCircuitInBus = false;
+ for (ItemStack aBusItem : tBusItems) {
+ if (ItemUtils.isControlCircuit(aBusItem)) {
+ aFoundCircuitInBus = true;
+ }
+ }
+ if (!aFoundCircuitInBus) {
+ continue;
+ }
+
Object[] tempArray = tFluids.toArray(new FluidStack[] {});
FluidStack[] properArray;
properArray = ((tempArray != null && tempArray.length > 0) ? (FluidStack[]) tempArray : new FluidStack[] {});
@@ -188,7 +198,7 @@ extends GregtechMeta_MultiBlockBase {
if (!isValidBlockForStructure(tTileEntity, getTextureIndex(), true, aBlock, aMeta,
ModBlocks.blockCasings3Misc, 2)) {
- Logger.INFO("Bad centrifuge casing");
+ Logger.INFO("Bad casing");
return false;
}
++tAmount;
@@ -287,16 +297,14 @@ extends GregtechMeta_MultiBlockBase {
else if (aMode == MODE_AUTOCLAVE) {
return GT_Recipe.GT_Recipe_Map.sAutoclaveRecipes;
}
- else if (aMode == MODE_REPLICATOR) {
- return null;
+ else if (aMode == MODE_FLUIDSOLIDIFY) {
+ return GT_Recipe.GT_Recipe_Map.sFluidSolidficationRecipes;
}
else {
return null;
}
}
- private final AutoMap<ItemStack> mReplicatorOutputMap = new AutoMap<ItemStack>();
-
@Override
public boolean checkRecipeGeneric(
ItemStack[] aItemInputs, FluidStack[] aFluidInputs,
@@ -311,12 +319,6 @@ extends GregtechMeta_MultiBlockBase {
Logger.MACHINE_INFO("Mode: "+tCircuitID);
- // Time to Defer to Special Handling if it's in replicator mode.
- if (tCircuitID == MODE_REPLICATOR) {
- return false;
- // return checkReplicatorRecipe(aItemInputs, aFluidInputs, aMaxParallelRecipes, aEUPercent, aSpeedBonusPercent, aOutputChanceRoll);
- }
-
// Reset outputs and progress stats
this.mEUt = 0;
this.mMaxProgresstime = 0;
@@ -480,396 +482,6 @@ extends GregtechMeta_MultiBlockBase {
return true;
}
- private FluidStack mReplicatorFluidOutput;
- //Replicator handling
- public boolean checkReplicatorRecipe(
- ItemStack[] aItemInputs, FluidStack[] aFluidInputs,
- int aMaxParallelRecipes, int aEUPercent,
- int aSpeedBonusPercent, int aOutputChanceRoll) {
-
- // Based on the Processing Array. A bit overkill, but very flexible.
- // Reset outputs and progress stats
- this.mEUt = 0;
- this.mMaxProgresstime = 0;
- this.mOutputItems = new ItemStack[]{};
- this.mOutputFluids = new FluidStack[]{};
- this.mReplicatorOutputMap.clear();
-
- long tVoltage = getMaxInputVoltage();
- byte tTier = (byte) Math.max(1, GT_Utility.getTier(tVoltage));
-
- if (canBufferOutputs(aItemInputs, aMaxParallelRecipes)) {
- Logger.WARNING("BAD RETURN - 2.0");
- return false;
- }
-
- ItemStack tDataOrb = null;
- ItemStack tCellStack = null;
- ItemStack tReplicatedItem;
- FluidStack tOutputFluid = null;
- FluidStack tInputFluid = null;
- final Materials tMaterial = Element.get(Behaviour_DataOrb.getDataName(tDataOrb)).mLinkedMaterials.get(0);
- final long tMass = tMaterial.getMass();
-
- // Find First Data Orb with Scan Data
- for (ItemStack I : aItemInputs) {
- if (ItemList.Tool_DataOrb.isStackEqual((Object) I, false, true) && Behaviour_DataOrb.getDataTitle(I).equals("Elemental-Scan")) {
- tDataOrb = I.copy();
- break;
- }
- }
-
- // Find First empty cell stack
- for (ItemStack I : aItemInputs) {
- if (ItemList.Cell_Empty.isStackEqual((Object) I)) {
- tCellStack = I.copy();
- break;
- }
- }
-
- // Find UUM
- for (FluidStack F : aFluidInputs) {
- if (F != null && F.isFluidEqual(Materials.UUMatter.getFluid(1L))) {
- final FluidStack tFluid = F;
- if (tFluid.amount >= tMass && tMass > 0L) {
- tInputFluid = tFluid;
- }
- }
- }
-
- // No Data Orb or UUM found?
- if (tDataOrb == null || tInputFluid == null) {
- return false;
- }
- // Temp Values
- int tEUt = (int) GT_Values.V[(int) this.getInputTier()];
- int tMaxProgresstime = (int) (tMass * 512L / (1 << tTier - 1));
- float tRecipeEUt = (tEUt * aEUPercent) / 100.0f;
- float tTotalEUt = 0.0f;
- int parallelRecipes = 0;
- ItemStack[] expectedInputs = {tDataOrb};
- FluidStack[] expectedFluidInputs = {Materials.UUMatter.getFluid(tMass)};
-
- /**
- * Magic
- */
-
- int COST_UUM = 0;
- int COST_CELLS = 0;
-
- // Determine Output Item & Cost.
- if ((tReplicatedItem = GT_OreDictUnificator.get(OrePrefixes.dust, (Object) tMaterial, 1L)) == null) {
- if ((tReplicatedItem = GT_OreDictUnificator.get(OrePrefixes.cell, (Object) tMaterial, 1L)) != null) {
- if ((tOutputFluid = GT_Utility.getFluidForFilledItem(tReplicatedItem, true)) == null) {
- if (ItemList.Cell_Empty.isStackEqual((Object) tCellStack) && this.canBufferOutputs(new ItemStack[]{tReplicatedItem}, 1)) {
- COST_CELLS = 1;
- COST_UUM = (int) tMass;
- }
- } else {
- tReplicatedItem = null;
- if (this.getDrainableStack() == null || (this.getDrainableStack().isFluidEqual(tOutputFluid) && this.getDrainableStack().amount < 16000)) {
- COST_UUM = (int) tMass;
- }
- }
- }
- } else if (this.canBufferOutputs(new ItemStack[]{tReplicatedItem}, 1)) {
- COST_UUM = (int) tMass;
- }
-
- // Costs no UUM and no valid outputs? Let's bail gracefully before we consume inputs.
- if (COST_UUM <= 0 || (tReplicatedItem == null && tOutputFluid == null)) {
- return false;
- }
-
- // Count recipes to do in parallel, consuming input items and fluids and considering input voltage limits
- for (; parallelRecipes < aMaxParallelRecipes && tTotalEUt < (tVoltage - tRecipeEUt); parallelRecipes++) {
- if (!isRecipeInputEqual(true, aFluidInputs, aItemInputs, expectedFluidInputs, expectedInputs)) {
- Logger.WARNING("Broke at "+parallelRecipes+"..0");
- break;
- }
- Logger.WARNING("Bumped EU from "+tTotalEUt+" to "+(tTotalEUt+tRecipeEUt)+"..0");
- tTotalEUt += tRecipeEUt;
- }
-
- if (parallelRecipes == 0) {
- Logger.WARNING("BAD RETURN - 3.0");
- return false;
- }
-
- // Set Vars to Parralel amount
- COST_CELLS *= parallelRecipes;
-
- // Requires a cell? Ok, let's use some.
- if (COST_CELLS > 0) {
- this.depleteInput(ItemUtils.getEmptyCell(COST_CELLS));
- }
-
- // Build an output map, for simplicity.
- for (int r=0;r<parallelRecipes;r++) {
- this.mReplicatorOutputMap.put(ItemUtils.getSimpleStack(tReplicatedItem, 1));
- }
-
- // -- Try not to fail after this point - inputs have already been consumed! --
- ItemStack[] mBuiltOutput = new ItemStack[this.mReplicatorOutputMap.size()];
- int aIndex = 0;
- for (ItemStack i : this.mReplicatorOutputMap) {
- mBuiltOutput[aIndex++] = i;
- }
-
-
- // Convert speed bonus to duration multiplier
- // e.g. 100% speed bonus = 200% speed = 100%/200% = 50% recipe duration.
- aSpeedBonusPercent = Math.max(-99, aSpeedBonusPercent);
- float tTimeFactor = 100.0f / (100.0f + aSpeedBonusPercent);
- this.mMaxProgresstime = (int)(tMaxProgresstime * tTimeFactor);
-
- this.mEUt = (int)Math.ceil(tTotalEUt);
-
- this.mEfficiency = (10000 - (getIdealStatus() - getRepairStatus()) * 1000);
- this.mEfficiencyIncrease = 10000;
-
- // Overclock
- if (this.mEUt <= 16) {
- this.mEUt = (this.mEUt * (1 << tTier - 1) * (1 << tTier - 1));
- this.mMaxProgresstime = (this.mMaxProgresstime / (1 << tTier - 1));
- } else {
- while (this.mEUt <= gregtech.api.enums.GT_Values.V[(tTier - 1)]) {
- this.mEUt *= 4;
- this.mMaxProgresstime /= 2;
- }
- }
-
- if (this.mEUt > 0) {
- this.mEUt = (-this.mEUt);
- }
-
- this.mMaxProgresstime = Math.max(1, this.mMaxProgresstime);
-
- // Collect output item types
- ItemStack[] tOutputItems = new ItemStack[1];
- for (int h = 0; h < 1; h++) {
- if (mBuiltOutput[h] != null) {
- tOutputItems[h] = mBuiltOutput[h].copy();
- tOutputItems[h].stackSize = 0;
- }
- }
-
- // Set output item stack sizes (taking output chance into account)
- for (int f = 0; f < tOutputItems.length; f++) {
- if (mBuiltOutput[f] != null && tOutputItems[f] != null) {
- for (int g = 0; g < parallelRecipes; g++) {
- tOutputItems[f].stackSize += mBuiltOutput[f].stackSize;
- }
- }
- }
-
- tOutputItems = removeNulls(tOutputItems);
-
- // Sanitize item stack size, splitting any stacks greater than max stack size
- List<ItemStack> splitStacks = new ArrayList<ItemStack>();
- for (ItemStack tItem : tOutputItems) {
- while (tItem.getMaxStackSize() < tItem.stackSize) {
- ItemStack tmp = tItem.copy();
- tmp.stackSize = tmp.getMaxStackSize();
- tItem.stackSize = tItem.stackSize - tItem.getMaxStackSize();
- splitStacks.add(tmp);
- }
- }
-
- if (splitStacks.size() > 0) {
- ItemStack[] tmp = new ItemStack[splitStacks.size()];
- tmp = splitStacks.toArray(tmp);
- tOutputItems = ArrayUtils.addAll(tOutputItems, tmp);
- }
-
- // Strip empty stacks
- List<ItemStack> tSList = new ArrayList<ItemStack>();
- for (ItemStack tS : tOutputItems) {
- if (tS.stackSize > 0) tSList.add(tS);
- }
- tOutputItems = tSList.toArray(new ItemStack[tSList.size()]);
-
- // Commit outputs
- this.mOutputItems = tOutputItems;
- //this.mOutputFluids = tOutputFluids;
- updateSlots();
-
- // Play sounds (GT++ addition - GT multiblocks play no sounds)
- startProcess();
-
- Logger.WARNING("GOOD RETURN - 1.0");
- return true;
- }
-
-
- //Special Space Checking
- private boolean canBufferOutputs(ItemStack[] aInputs, int aParallelRecipes) {
- // Count slots available in output buses
- ArrayList<ItemStack> tBusStacks = new ArrayList<>();
-
- int tEmptySlots = 0;
- for (final GT_MetaTileEntity_Hatch_OutputBus tBus : this.mOutputBusses) {
- if (!isValidMetaTileEntity(tBus)) {
- continue;
- }
- final IInventory tBusInv = tBus.getBaseMetaTileEntity();
- for (int i = 0; i < tBusInv.getSizeInventory(); i++) {
- if (tBus.getStackInSlot(i) == null) {
- tEmptySlots++;
- }
- else {
- tBusStacks.add(tBus.getStackInSlot(i));
- }
- }
- }
-
- int slotsNeeded = aInputs.length;
- for (final ItemStack tRecipeOutput: aInputs) {
- if (tRecipeOutput == null) continue;
- int amount = tRecipeOutput.stackSize * aParallelRecipes;
- for (final ItemStack tBusStack : tBusStacks) {
- if (GT_Utility.areStacksEqual(tBusStack, tRecipeOutput)) {
- if (tBusStack.stackSize + amount <= tBusStack.getMaxStackSize()) {
- slotsNeeded--;
- break;
- }
- }
- }
- }
- // Enough open slots?
- if (tEmptySlots < slotsNeeded) return false;
- return true;
-
- }
-
- public FluidStack getDrainableStack() {
- return this.mReplicatorFluidOutput;
- }
-
- public FluidStack setDrainableStack(final FluidStack aFluid) {
- return this.mReplicatorFluidOutput = aFluid;
- }
-
- public boolean isRecipeInputEqual(final boolean aDecreaseStacksizeBySuccess,
- final FluidStack[] aFluidInputs,
- final ItemStack[] aInputs,
- final FluidStack[] mFluidInputs,
- final ItemStack[] mInputs) {
- return this.isRecipeInputEqual(aDecreaseStacksizeBySuccess, false, aFluidInputs, aInputs, mFluidInputs, mInputs);
- }
-
- public boolean isRecipeInputEqual(
- final boolean aDecreaseStacksizeBySuccess,
- final boolean aDontCheckStackSizes,
- final FluidStack[] aFluidInputs,
- final ItemStack[] aInputs,
- final FluidStack[] aExpectedFluidInputs,
- final ItemStack[] mExpectedInputs) {
- if (aExpectedFluidInputs.length > 0 && aFluidInputs == null) {
- return false;
- }
- for (final FluidStack tFluid : aExpectedFluidInputs) {
- if (tFluid != null) {
- boolean temp = true;
- int amt = tFluid.amount;
- for (final FluidStack aFluid : aFluidInputs) {
- if (aFluid != null && aFluid.isFluidEqual(tFluid)) {
- if (aDontCheckStackSizes) {
- temp = false;
- break;
- }
- amt -= aFluid.amount;
- if (amt < 1) {
- temp = false;
- break;
- }
- }
- }
- if (temp) {
- return false;
- }
- }
- }
- if (mExpectedInputs.length > 0 && aInputs == null) {
- return false;
- }
- for (final ItemStack tStack : mExpectedInputs) {
- if (tStack != null) {
- int amt = tStack.stackSize;
- boolean temp = true;
- for (final ItemStack aStack : aInputs) {
- if (GT_Utility.areUnificationsEqual(aStack, tStack, true)
- || GT_Utility.areUnificationsEqual(GT_OreDictUnificator.get(false, aStack), tStack, true)) {
- if (aDontCheckStackSizes) {
- temp = false;
- break;
- }
- amt -= aStack.stackSize;
- if (amt < 1) {
- temp = false;
- break;
- }
- }
- }
- if (temp) {
- return false;
- }
- }
- }
- if (aDecreaseStacksizeBySuccess) {
- if (aFluidInputs != null) {
- for (final FluidStack tFluid : aExpectedFluidInputs) {
- if (tFluid != null) {
- int amt = tFluid.amount;
- for (final FluidStack aFluid2 : aFluidInputs) {
- if (aFluid2 != null && aFluid2.isFluidEqual(tFluid)) {
- if (aDontCheckStackSizes) {
- final FluidStack fluidStack = aFluid2;
- fluidStack.amount -= amt;
- break;
- }
- if (aFluid2.amount >= amt) {
- final FluidStack fluidStack2 = aFluid2;
- fluidStack2.amount -= amt;
- amt = 0;
- break;
- }
- amt -= aFluid2.amount;
- aFluid2.amount = 0;
- }
- }
- }
- }
- }
- if (aInputs != null) {
- for (final ItemStack tStack : mExpectedInputs) {
- if (tStack != null) {
- int amt = tStack.stackSize;
- for (final ItemStack aStack2 : aInputs) {
- if (GT_Utility.areUnificationsEqual(aStack2, tStack, true) || GT_Utility
- .areUnificationsEqual(GT_OreDictUnificator.get(false, aStack2), tStack, true)) {
- if (aDontCheckStackSizes) {
- final ItemStack itemStack = aStack2;
- itemStack.stackSize -= amt;
- break;
- }
- if (aStack2.stackSize >= amt) {
- final ItemStack itemStack2 = aStack2;
- itemStack2.stackSize -= amt;
- amt = 0;
- break;
- }
- amt -= aStack2.stackSize;
- aStack2.stackSize = 0;
- }
- }
- }
- }
- }
- }
- return true;
- }
-
@Override
public void onModeChangeByScrewdriver(byte aSide, EntityPlayer aPlayer, float aX, float aY, float aZ) {
if (mInternalMode < 2) {
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialWashPlant.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialWashPlant.java
index ce1fe57e63..ca6eeda207 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialWashPlant.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/GregtechMetaTileEntity_IndustrialWashPlant.java
@@ -56,13 +56,14 @@ extends GregtechMeta_MultiBlockBase {
"Can be configured with a screwdriver to also process Chemical Bathing",
"400% faster than using single block machines of the same voltage",
"Processes four item per voltage tier",
+ "Always requires an Input Hatch full of water to refill structure",
"Size: 5x3x7 [WxHxL] (open)",
"X X",
"X X",
"XXXXX",
"Controller (front centered)",
"1x Input Bus (Any casing)",
- "1x Input Hatch (Any casing)",
+ "2x Input Hatch (Any casing)",
"1x Output Bus (Any casing)",
"1x Energy Hatch (Any casing)",
"Wash Plant Casings for the rest"
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/advanced/GregtechMetaTileEntity_Adv_EBF.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/advanced/GregtechMetaTileEntity_Adv_EBF.java
index 133e10d6f6..96a85a3d1c 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/advanced/GregtechMetaTileEntity_Adv_EBF.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/processing/advanced/GregtechMetaTileEntity_Adv_EBF.java
@@ -86,7 +86,7 @@ public class GregtechMetaTileEntity_Adv_EBF extends GregtechMeta_MultiBlockBase
"Speed: 120% | Eu Usage: 90% | Parallel: 8",
"Consumes 10L of " + mHotFuelName + " per second during operation",
"Constructed exactly the same as a normal EBF",
- "Use "+mCasingName+"s (10 at least!)",
+ "Use "+mCasingName+"s (9 at least!)",
"1x " + mHatchName + " (Required)",
"TAG_HIDE_HATCHES"
};
@@ -208,7 +208,7 @@ public class GregtechMetaTileEntity_Adv_EBF extends GregtechMeta_MultiBlockBase
}
}
- return aCasingCount >= 10;
+ return aCasingCount >= 9;
}
public int getMaxEfficiency(ItemStack aStack) {
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/loaders/Gregtech_Blocks.java b/src/Java/gtPlusPlus/xmod/gregtech/loaders/Gregtech_Blocks.java
index 361fadcb5a..535dfb3faa 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/loaders/Gregtech_Blocks.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/loaders/Gregtech_Blocks.java
@@ -26,7 +26,7 @@ public class Gregtech_Blocks {
ModBlocks.blockCasings3Misc = new GregtechMetaCasingBlocks3();
ModBlocks.blockCasings4Misc = new GregtechMetaCasingBlocks4();
- ModBlocks.BlockTieredCasings1 = new GregtechMetaTieredCasingBlocks1();
+ ModBlocks.blockCasingsTieredGTPP = new GregtechMetaTieredCasingBlocks1();
}
}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechIndustrialAlloySmelter.java b/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechIndustrialAlloySmelter.java
new file mode 100644
index 0000000000..6587e3a253
--- /dev/null
+++ b/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechIndustrialAlloySmelter.java
@@ -0,0 +1,22 @@
+package gtPlusPlus.xmod.gregtech.registration.gregtech;
+
+import gtPlusPlus.api.objects.Logger;
+import gtPlusPlus.xmod.gregtech.api.enums.GregtechItemList;
+import gtPlusPlus.xmod.gregtech.common.tileentities.machines.multi.processing.GregtechMetaTileEntity_IndustrialAlloySmelter;
+
+public class GregtechIndustrialAlloySmelter {
+
+ public static void run() {
+ if (gtPlusPlus.core.lib.LoadedMods.Gregtech) {
+ Logger.INFO("Gregtech5u Content | Registering Industrial Alloy Smelter Multiblock.");
+ run1();
+ }
+
+ }
+
+ private static void run1() {
+ GregtechItemList.Industrial_AlloySmelter.set(new GregtechMetaTileEntity_IndustrialAlloySmelter(31023,
+ "industrialalloysmelter.controller.tier.single", "Zyngen").getStackForm(1L));
+
+ }
+} \ No newline at end of file