diff options
author | Connor-Colenso <52056774+Connor-Colenso@users.noreply.github.com> | 2022-12-18 17:38:54 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-18 18:38:54 +0100 |
commit | 3c852a0143cbfa864da59bdd0b2edab1fa4bf146 (patch) | |
tree | bbdb97091199dccad76f03182a1270969e36f113 /src/main/java/gregtech/api/util | |
parent | e3e077b34f825d9f09da8fe7191251c1dcd9bbd5 (diff) | |
download | GT5-Unofficial-3c852a0143cbfa864da59bdd0b2edab1fa4bf146.tar.gz GT5-Unofficial-3c852a0143cbfa864da59bdd0b2edab1fa4bf146.tar.bz2 GT5-Unofficial-3c852a0143cbfa864da59bdd0b2edab1fa4bf146.zip |
Turbine efficiency helper (#1562)
* Add value to automatically determine highest possible turbine efficiency.
* spotlessApply (#1563)
Co-authored-by: Connor-Colenso <52056774+Connor-Colenso@users.noreply.github.com>
Co-authored-by: GitHub GTNH Actions <>
Co-authored-by: GTNH-Colen <54497873+GTNH-Colen@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Diffstat (limited to 'src/main/java/gregtech/api/util')
-rw-r--r-- | src/main/java/gregtech/api/util/GT_Utility.java | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/main/java/gregtech/api/util/GT_Utility.java b/src/main/java/gregtech/api/util/GT_Utility.java index da98e97f8e..e24c893063 100644 --- a/src/main/java/gregtech/api/util/GT_Utility.java +++ b/src/main/java/gregtech/api/util/GT_Utility.java @@ -4331,4 +4331,15 @@ public class GT_Utility { @Nullable protected abstract NBTTagCompound nbt(); } + + public static int getPlasmaFuelValueInEUPerLiterFromMaterial(Materials material) { + return getPlasmaFuelValueInEUPerLiterFromFluid(material.getPlasma(1)); + } + + public static int getPlasmaFuelValueInEUPerLiterFromFluid(FluidStack aLiquid) { + if (aLiquid == null) return 0; + GT_Recipe tFuel = GT_Recipe.GT_Recipe_Map.sPlasmaFuels.findFuel(aLiquid); + if (tFuel != null) return tFuel.mSpecialValue; + return 0; + } } |