aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/xmod
diff options
context:
space:
mode:
authorDraknyte1 <Draknyte1@hotmail.com>2016-12-27 04:21:20 +1000
committerDraknyte1 <Draknyte1@hotmail.com>2016-12-27 04:21:20 +1000
commita47d4add073d3dafe6357b526ca5963466528feb (patch)
treed825b8af2177535be1bbd579b68597dcdd8edcbe /src/Java/gtPlusPlus/xmod
parentdea17b0667c442b6455b70c9b52eab29d0372b01 (diff)
downloadGT5-Unofficial-a47d4add073d3dafe6357b526ca5963466528feb.tar.gz
GT5-Unofficial-a47d4add073d3dafe6357b526ca5963466528feb.tar.bz2
GT5-Unofficial-a47d4add073d3dafe6357b526ca5963466528feb.zip
% Changed the Autogenerated Fluid textures again.
+ Created Thorium-232, a step towards ThF4. + Added centrifuge recipe for Th->Th232(Bonus U232 0.10%). + Added THORIUM_HEXAFLUORIDE & THORIUM_TETRAFLUORIDE into ALLOY.java % Fixed fluid extractor recipes not being added for every dust. + Added more fluid extractor and fluid solidifier recipes for each material. - Removed old "uraniumHexafluoride", "uraniumTetrafluoride", "thoriumTetrafluoride" fluids and IC2 cells. % Changed Multitank Controller Logic, maybe broke things. + Added getNugget and getCell to Material.java % Changed MaterialGenerator.java to use the materials radioactivity level, not the old method based on name. % Moved material blacklist for BlastSmelting Recipe generation out of material/MaterialGenerator.java.
Diffstat (limited to 'src/Java/gtPlusPlus/xmod')
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/blocks/fluid/GregtechFluidHandler.java12
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/GregtechMetaTileEntity_MultiTank.java69
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_BlastSmelter.java16
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_DustGeneration.java77
4 files changed, 160 insertions, 14 deletions
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/fluid/GregtechFluidHandler.java b/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/fluid/GregtechFluidHandler.java
index 6462b2f632..d50ce9a4c5 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/fluid/GregtechFluidHandler.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/fluid/GregtechFluidHandler.java
@@ -56,14 +56,14 @@ public class GregtechFluidHandler {
FluidUtils.addFluid("sulfuricApatite", "Sulfuric Apatite Mix", GT_Materials.SulfuricApatite, 4, 500, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.SulfuricApatite, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
generateIC2FluidCell("SulfuricApatite");
- FluidUtils.addFluid("uraniumHexafluoride", "Uranium Hexafluoride", GT_Materials.UraniumHexaFluoride, 4, 200, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.UraniumHexaFluoride, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
- generateIC2FluidCell("UraniumHexaFluoride");
+ //FluidUtils.addFluid("uraniumHexafluoride", "Uranium Hexafluoride", GT_Materials.UraniumHexaFluoride, 4, 200, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.UraniumHexaFluoride, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
+ //generateIC2FluidCell("Molten.UraniumHexaFluoride");
- FluidUtils.addFluid("uraniumTetrafluoride", "Uranium Tetrafluoride", GT_Materials.UraniumTetraFluoride, 4, 950, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.UraniumTetraFluoride, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
- generateIC2FluidCell("UraniumTetraFluoride");
+ //FluidUtils.addFluid("uraniumTetrafluoride", "Uranium Tetrafluoride", GT_Materials.UraniumTetraFluoride, 4, 950, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.UraniumTetraFluoride, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
+ //generateIC2FluidCell("UraniumTetraFluoride");
- FluidUtils.addFluid("thoriumTetrafluoride", "Thorium Tetrafluoride", GT_Materials.ThoriumTetraFluoride, 4, 1250, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.ThoriumTetraFluoride, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
- generateIC2FluidCell("ThoriumTetraFluoride");
+ //FluidUtils.addFluid("thoriumTetrafluoride", "Thorium Tetrafluoride", GT_Materials.ThoriumTetraFluoride, 4, 1250, GT_OreDictUnificator.get(OrePrefixes.cell, GT_Materials.ThoriumTetraFluoride, 1L), ItemList.Cell_Empty.get(1L, new Object[0]), 1000);
+ //generateIC2FluidCell("ThoriumTetraFluoride");
//Check for IHL Hydrogen Chloride
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/GregtechMetaTileEntity_MultiTank.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/GregtechMetaTileEntity_MultiTank.java
index dbf6569156..a1140f3777 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/GregtechMetaTileEntity_MultiTank.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/GregtechMetaTileEntity_MultiTank.java
@@ -75,10 +75,10 @@ extends GregtechMeta_MultiBlockBase {
aNBT.setInteger("mEfficiency", mEfficiency);
aNBT.setInteger("mPollution", mPollution);
aNBT.setInteger("mRuntime", mRuntime);
+ aNBT.setInteger("mCasingCount", countCasings());
aNBT.setLong("mFluidStored", fluidStored);
aNBT.setInteger("mStorageMultiplier", storageMultiplier);
aNBT.setLong("mMaxFluidStored", maximumFluidStorage);
- aNBT.setInteger("mCasingCount", multiblockCasingCount);
if (mOutputItems != null) for (int i = 0; i < mOutputItems.length; i++)
if (mOutputItems[i] != null) {
@@ -102,14 +102,13 @@ extends GregtechMeta_MultiBlockBase {
}
private short getStorageMultiplier(){
- int tempstorageMultiplier = (1*multiblockCasingCount);
+ int tempstorageMultiplier = (1*countCasings());
if (tempstorageMultiplier <= 0){
if (this != null){
if (this.getBaseMetaTileEntity() != null){
if (this.getBaseMetaTileEntity().getWorld() != null){
- Utils.LOG_INFO("Invalid Storage Multiplier. "+multiblockCasingCount);
- checkMachine(this.getBaseMetaTileEntity(), null);
- return 0;
+ Utils.LOG_INFO("Invalid Storage Multiplier. "+countCasings());
+ return (short) countCasings();
}
}
}
@@ -140,10 +139,10 @@ extends GregtechMeta_MultiBlockBase {
mEfficiency = aNBT.getInteger("mEfficiency");
mPollution = aNBT.getInteger("mPollution");
mRuntime = aNBT.getInteger("mRuntime");
+ multiblockCasingCount = aNBT.getInteger("mCasingCount");
fluidStored = aNBT.getLong("mFluidStored");
storageMultiplier = aNBT.getInteger("mStorageMultiplier");
maximumFluidStorage = aNBT.getLong("mMaxFluidStored");
- multiblockCasingCount = aNBT.getInteger("mCasingCount");
mOutputItems = new ItemStack[getAmountOfOutputs()];
for (int i = 0; i < mOutputItems.length; i++) mOutputItems[i] = GT_Utility.loadItem(aNBT, "mOutputItem" + i);
mOutputFluids = new FluidStack[getAmountOfOutputs()];
@@ -411,6 +410,64 @@ extends GregtechMeta_MultiBlockBase {
Utils.LOG_INFO("Casings Count: "+tAmount+" Valid Multiblock: "+(tAmount >= 16)+" Tank Storage Capacity:"+getMaximumTankStorage()+"L");
return tAmount >= 16;
}
+
+ public int countCasings() {
+ if (this.getBaseMetaTileEntity().getWorld() == null){
+ return 0;
+ }
+ int xDir = ForgeDirection.getOrientation(this.getBaseMetaTileEntity().getBackFacing()).offsetX;
+ int zDir = ForgeDirection.getOrientation(this.getBaseMetaTileEntity().getBackFacing()).offsetZ;
+ if (!this.getBaseMetaTileEntity().getAirOffset(xDir, 0, zDir)) {
+ Utils.LOG_WARNING("Must be hollow.");
+ return 0;
+ }
+ int tAmount = 0;
+ for (int i = -1; i < 2; i++) {
+ for (int j = -1; j < 2; j++) {
+ for (int h = -1; h < 19; h++) {
+ if ((h != 0) || (((xDir + i != 0) || (zDir + j != 0)) && ((i != 0) || (j != 0)))) {
+ IGregTechTileEntity tTileEntity = this.getBaseMetaTileEntity().getIGregTechTileEntityOffset(xDir + i, h, zDir + j);
+ if ((!addMaintenanceToMachineList(tTileEntity, 68)) && (!addInputToMachineList(tTileEntity, 68)) && (!addOutputToMachineList(tTileEntity, 68)) && (!addEnergyInputToMachineList(tTileEntity, 68))) {
+ if (this.getBaseMetaTileEntity().getBlockOffset(xDir + i, h, zDir + j) != ModBlocks.blockCasingsMisc) {
+ if (h < 3){
+ Utils.LOG_WARNING("Casing Expected.");
+ return 0;
+ }
+ else if (h >= 3){
+ //Utils.LOG_WARNING("Your Multitank can be 20 blocks tall.");
+ }
+ }
+ if (this.getBaseMetaTileEntity().getMetaIDOffset(xDir + i, h, zDir + j) != 11) {
+ if (h < 3){
+ Utils.LOG_WARNING("Wrong Meta.");
+ return 0;
+ }
+ else if (h >= 3){
+ //Utils.LOG_WARNING("Your Multitank can be 20 blocks tall.");
+ }
+ }
+ if (h < 3){
+ tAmount++;
+ }
+ else if (h >= 3){
+ if (this.getBaseMetaTileEntity().getBlockOffset(xDir + i, h, zDir + j) == Blocks.air || this.getBaseMetaTileEntity().getBlockOffset(xDir + i, h, zDir + j).getUnlocalizedName().contains("residual")){
+ Utils.LOG_WARNING("Found air");
+ }
+ else {
+ Utils.LOG_WARNING("Layer "+(h+2)+" is complete. Adding "+(64000*9)+"L storage to the tank.");
+ tAmount++;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ multiblockCasingCount = tAmount;
+ Utils.LOG_INFO("Your Multitank can be 20 blocks tall.");
+ Utils.LOG_INFO("Casings Count: "+tAmount+" Valid Multiblock: "+(tAmount >= 16)+" Tank Storage Capacity:"+getMaximumTankStorage()+"L");
+ return tAmount;
+ }
@Override
public int getMaxEfficiency(ItemStack aStack) {
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_BlastSmelter.java b/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_BlastSmelter.java
index 8da9699c8e..2e1e259b4e 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_BlastSmelter.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_BlastSmelter.java
@@ -3,8 +3,7 @@ package gtPlusPlus.xmod.gregtech.loaders;
import gregtech.api.enums.GT_Values;
import gregtech.api.enums.ItemList;
import gtPlusPlus.core.lib.CORE;
-import gtPlusPlus.core.material.Material;
-import gtPlusPlus.core.material.MaterialStack;
+import gtPlusPlus.core.material.*;
import gtPlusPlus.core.util.Utils;
import gtPlusPlus.core.util.item.ItemUtils;
@@ -30,6 +29,19 @@ public class RecipeGen_BlastSmelter implements Runnable{
//Add a Blast Smelting Recipe, Let's go!
ItemStack tStack;
if (null != (tStack = M.getDust(1))) {
+
+ Material[] badMaterials = {
+ ALLOY.THORIUM_HEXAFLUORIDE,
+ ALLOY.THORIUM_TETRAFLUORIDE,
+ ALLOY.BLOODSTEEL,
+ ALLOY.LiFBeF2ThF4UF4,
+ ALLOY.LiFBeF2ZrF4U235
+ };
+ for (Material R : badMaterials){
+ if (M == R){
+ return;
+ }
+ }
//Prepare some Variables
ItemStack[] components;
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_DustGeneration.java b/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_DustGeneration.java
index c0122cbcf5..6f0697365d 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_DustGeneration.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/loaders/RecipeGen_DustGeneration.java
@@ -1,6 +1,7 @@
package gtPlusPlus.xmod.gregtech.loaders;
import gregtech.api.enums.GT_Values;
+import gregtech.api.enums.ItemList;
import gtPlusPlus.core.material.Material;
import gtPlusPlus.core.util.Utils;
import gtPlusPlus.core.util.item.ItemUtils;
@@ -90,6 +91,82 @@ public class RecipeGen_DustGeneration implements Runnable{
else {
Utils.LOG_WARNING("4 Small dust from 1 Dust Recipe: "+material.getLocalizedName()+" - Failed");
}
+
+ //Melting Shapes to fluid
+ if (GT_Values.RA.addFluidExtractionRecipe(normalDust, //Input
+ null, //Input 2
+ material.getFluid(144), //Fluid Output
+ 0, //Chance
+ 1*20, //Duration
+ 16 //Eu Tick
+ )){
+ Utils.LOG_WARNING("144l fluid extractor from 1 Dust Recipe: "+material.getLocalizedName()+" - Success");
+ }
+ else {
+ Utils.LOG_WARNING("144l fluid extractor from 1 Dust Recipe: "+material.getLocalizedName()+" - Failed");
+ }
+ if (GT_Values.RA.addFluidExtractionRecipe(material.getPlate(1), //Input
+ null, //Input 2
+ material.getFluid(144), //Fluid Output
+ 0, //Chance
+ 1*20, //Duration
+ 16 //Eu Tick
+ )){
+ Utils.LOG_WARNING("144l fluid extractor from 1 plate Recipe: "+material.getLocalizedName()+" - Success");
+ }
+ else {
+ Utils.LOG_WARNING("144l fluid extractor from 1 plate Recipe: "+material.getLocalizedName()+" - Failed");
+ }
+ if (GT_Values.RA.addFluidExtractionRecipe(material.getNugget(1), //Input
+ null, //Input 2
+ material.getFluid(16), //Fluid Output
+ 0, //Chance
+ 1*20, //Duration
+ 16 //Eu Tick
+ )){
+ Utils.LOG_WARNING("16l fluid extractor from 1 nugget Recipe: "+material.getLocalizedName()+" - Success");
+ }
+ else {
+ Utils.LOG_WARNING("16l fluid extractor from 1 nugget Recipe: "+material.getLocalizedName()+" - Failed");
+ }
+
+ //Making Shapes from fluid
+ if (GT_Values.RA.addFluidSolidifierRecipe(
+ ItemList.Shape_Mold_Ingot.get(1), //Item Shape
+ material.getFluid(144), //Fluid Input
+ material.getIngot(1), //output
+ 1*20, //Duration
+ 16 //Eu Tick
+ )){
+ Utils.LOG_WARNING("144l fluid molder for 1 ingot Recipe: "+material.getLocalizedName()+" - Success");
+ }
+ else {
+ Utils.LOG_WARNING("144l fluid molder for 1 ingot Recipe: "+material.getLocalizedName()+" - Failed");
+ }
+ if (GT_Values.RA.addFluidSolidifierRecipe(
+ ItemList.Shape_Mold_Plate.get(1), //Item Shape
+ material.getFluid(144), //Fluid Input
+ material.getPlate(1), //output
+ 1*20, //Duration
+ 16 //Eu Tick
+ )){
+ Utils.LOG_WARNING("144l fluid molder for 1 plate Recipe: "+material.getLocalizedName()+" - Success");
+ }
+ else {
+ Utils.LOG_WARNING("144l fluid molder for 1 plate Recipe: "+material.getLocalizedName()+" - Failed");
+ }
+ if (GT_Values.RA.addFluidSolidifierRecipe(
+ ItemList.Shape_Mold_Nugget.get(1), //Item Shape
+ material.getFluid(16), //Fluid Input
+ material.getNugget(1), //output
+ 1*20, //Duration
+ 16 //Eu Tick
+ )){
+ Utils.LOG_WARNING("16l fluid molder for 1 nugget Recipe: "+material.getLocalizedName()+" - Success");
+ }
+ else {
+ Utils.LOG_WARNING("16l fluid molder for 1 nugget Recipe: "+material.getLocalizedName()+" - Failed");
+ }
//Is this a composite?
if (inputStacks != null){