aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlkalus <3060479+draknyte1@users.noreply.github.com>2021-12-11 19:01:54 +0000
committerAlkalus <3060479+draknyte1@users.noreply.github.com>2021-12-11 19:01:54 +0000
commitf8a024abbe83d475b48282d235970b000ee5b37e (patch)
tree926ba6457dd5002122d59c2c2c7f16cb43f718fe
parenta88fed98878a081350cde7a0ee6d3fdd1a3de420 (diff)
downloadGT5-Unofficial-f8a024abbe83d475b48282d235970b000ee5b37e.tar.gz
GT5-Unofficial-f8a024abbe83d475b48282d235970b000ee5b37e.tar.bz2
GT5-Unofficial-f8a024abbe83d475b48282d235970b000ee5b37e.zip
Removed an unused import from HANDLER_GT.
Balanced FFPP fuel production recipes.
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/HANDLER_GT.java1
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_ElementalDuplicator.java197
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/loaders/recipe/RecipeLoader_NuclearFuelProcessing.java8
3 files changed, 5 insertions, 201 deletions
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/HANDLER_GT.java b/src/Java/gtPlusPlus/xmod/gregtech/HANDLER_GT.java
index 6b7ca6c9b3..f623fe7405 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/HANDLER_GT.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/HANDLER_GT.java
@@ -55,7 +55,6 @@ import gtPlusPlus.xmod.gregtech.loaders.ProcessingElectricSnips;
import gtPlusPlus.xmod.gregtech.loaders.ProcessingToolHeadChoocher;
import gtPlusPlus.xmod.gregtech.loaders.misc.AddCustomMachineToPA;
import gtPlusPlus.xmod.gregtech.loaders.recipe.RecipeLoader_AlgaeFarm;
-import gtPlusPlus.xmod.gregtech.loaders.recipe.RecipeLoader_Nuclear;
import gtPlusPlus.xmod.gregtech.recipes.RecipesToRemove;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechConduits;
import gtPlusPlus.xmod.gregtech.registration.gregtech.GregtechNitroDieselFix;
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_ElementalDuplicator.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_ElementalDuplicator.java
index e4d8d2778e..326cc01de7 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_ElementalDuplicator.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_ElementalDuplicator.java
@@ -569,202 +569,7 @@ public class GregtechMTE_ElementalDuplicator extends GregtechMeta_MultiBlockBase
ItemStack[] aItemInputs, FluidStack[] aFluidInputs,
int aMaxParallelRecipes, int aEUPercent,
int aSpeedBonusPercent, int aOutputChanceRoll, GT_Recipe aRecipe, boolean isOC) {
-
- // 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();
- log("Running checkRecipeGeneric(0)");
-
- //GT_Recipe tRecipe = findRecipe(getBaseMetaTileEntity(), mLastRecipe, false, gregtech.api.enums.GT_Values.V[tTier], aFluidInputs, aItemInputs);
- GT_Recipe tRecipe = findRecipe(mLastRecipe, gregtech.api.enums.GT_Values.V[tTier], getSolidCasingTier(), aItemInputs, aFluidInputs);
-
-
-
-
- if (tRecipe == null) {
- log("BAD RETURN - 1");
- return false;
- }
-
- // checks if it has a catalyst with enough durability
- ItemStack tCatalystRecipe = findCatalyst(aItemInputs);
- boolean aDoesRecipeNeedCatalyst = false;
- for (ItemStack aInputItem : tRecipe.mInputs) {
- if (ItemUtils.isCatalyst(aInputItem)) {
- aDoesRecipeNeedCatalyst = true;
- break;
- }
- }
- if (aDoesRecipeNeedCatalyst) {
- if (tCatalystRecipe == null) {
- log("does not have catalyst");
- return false;
- }
- }
-
-
- log("Running checkRecipeGeneric(1)");
- // Remember last recipe - an optimization for findRecipe()
- this.mLastRecipe = tRecipe;
-
- if (tRecipe.mSpecialValue > this.mSolidCasingTier) {
- log("solid tier is too low");
- return false;
- }
-
- aMaxParallelRecipes = this.canBufferOutputs(tRecipe, aMaxParallelRecipes);
- if (aMaxParallelRecipes == 0) {
- log("BAD RETURN - 2");
- return false;
- }
-
- // checks if it has enough catalyst durabilety
- ArrayList<ItemStack>tCatalysts = null;
- int tMaxParrallelCatalyst = aMaxParallelRecipes;
- if (tCatalystRecipe != null) {
- tCatalysts = new ArrayList<ItemStack>();
- tMaxParrallelCatalyst = getCatalysts(aItemInputs, tCatalystRecipe, aMaxParallelRecipes, tCatalysts);
- log("Can process "+tMaxParrallelCatalyst+" recipes. If less than "+aMaxParallelRecipes+", catalyst does not have enough durability.");
- }
-
- if (tMaxParrallelCatalyst == 0) {
- log("found not enough catalysts");
- return false;
- }
-
- // EU discount
- float tRecipeEUt = (tRecipe.mEUt * aEUPercent) / 100.0f;
- float tTotalEUt = 0.0f;
- log("aEUPercent "+aEUPercent);
- log("mEUt "+tRecipe.mEUt);
-
- int parallelRecipes = 0;
-
- log("parallelRecipes: "+parallelRecipes);
- log("aMaxParallelRecipes: "+tMaxParrallelCatalyst);
- log("tTotalEUt: "+tTotalEUt);
- log("tVoltage: "+tVoltage);
- log("tEnergy: "+tEnergy);
- log("tRecipeEUt: "+tRecipeEUt);
- // Count recipes to do in parallel, consuming input items and fluids and considering input voltage limits
- for (; parallelRecipes < tMaxParrallelCatalyst && tTotalEUt < (tEnergy - tRecipeEUt); parallelRecipes++) {
- if (!tRecipe.isRecipeInputEqual(true, aFluidInputs, aItemInputs)) {
- log("Broke at "+parallelRecipes+".");
- break;
- }
- log("Bumped EU from "+tTotalEUt+" to "+(tTotalEUt+tRecipeEUt)+".");
- tTotalEUt += tRecipeEUt;
- }
-
- if (parallelRecipes == 0) {
- log("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);
-
- 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 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();
-
- log("GOOD RETURN - 1");
- return true;
+ return false;
}
private static final HashMap<Long, AutoMap<GT_Recipe>> mTieredRecipeMap = new HashMap<Long, AutoMap<GT_Recipe>>();
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/loaders/recipe/RecipeLoader_NuclearFuelProcessing.java b/src/Java/gtPlusPlus/xmod/gregtech/loaders/recipe/RecipeLoader_NuclearFuelProcessing.java
index 94a5627882..646b99d924 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/loaders/recipe/RecipeLoader_NuclearFuelProcessing.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/loaders/recipe/RecipeLoader_NuclearFuelProcessing.java
@@ -45,7 +45,7 @@ public class RecipeLoader_NuclearFuelProcessing {
// 7LiF - BeF2 - ZrF4 - UF4 - 650C
CORE.RA.addFissionFuel(
- FluidUtils.getFluidStack(aLithiumFluoride, 650),
+ FluidUtils.getFluidStack(aLithiumFluoride, 600),
FluidUtils.getFluidStack(aBerylliumFluoride, 250),
FluidUtils.getFluidStack(aZirconiumFluoride, 80),
FluidUtils.getFluidStack(aUraniumTetraFluoride, 70),
@@ -58,9 +58,9 @@ public class RecipeLoader_NuclearFuelProcessing {
// 7liF - BeF2 - ThF4 - UF4 - 566C
CORE.RA.addFissionFuel(
- FluidUtils.getFluidStack(aLithiumFluoride, 620),
- FluidUtils.getFluidStack(aBerylliumFluoride, 280),
- FluidUtils.getFluidStack(aThoriumFluoride, 70),
+ FluidUtils.getFluidStack(aLithiumFluoride, 580),
+ FluidUtils.getFluidStack(aBerylliumFluoride, 270),
+ FluidUtils.getFluidStack(aThoriumFluoride, 80),
FluidUtils.getFluidStack(aUraniumTetraFluoride, 70),
null, null, null, null, null, // Extra 5 inputs
FluidUtils.getFluidStack(aLiFBeF2ThF4UF4, 1000),