diff options
author | GDCloud <93287602+GDCloudstrike@users.noreply.github.com> | 2023-12-05 02:42:44 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-12-05 01:42:44 +0000 |
commit | 28f5b4aaa73675fe9e9c8e481f9bcebb6a9871cb (patch) | |
tree | a91db5d152defae3307eb66790b40dae28ae88c9 /src | |
parent | 455465c7ab5dd52b98b468d05d92f12f6a1a3fe4 (diff) | |
download | GT5-Unofficial-28f5b4aaa73675fe9e9c8e481f9bcebb6a9871cb.tar.gz GT5-Unofficial-28f5b4aaa73675fe9e9c8e481f9bcebb6a9871cb.tar.bz2 GT5-Unofficial-28f5b4aaa73675fe9e9c8e481f9bcebb6a9871cb.zip |
dont divide by 0 (#264)
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/com/github/technus/tectech/thing/metaTileEntity/multi/GT_MetaTileEntity_EM_EyeOfHarmony.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/multi/GT_MetaTileEntity_EM_EyeOfHarmony.java b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/multi/GT_MetaTileEntity_EM_EyeOfHarmony.java index 52edbc8a96..37592a3d9f 100644 --- a/src/main/java/com/github/technus/tectech/thing/metaTileEntity/multi/GT_MetaTileEntity_EM_EyeOfHarmony.java +++ b/src/main/java/com/github/technus/tectech/thing/metaTileEntity/multi/GT_MetaTileEntity_EM_EyeOfHarmony.java @@ -1496,7 +1496,7 @@ public class GT_MetaTileEntity_EM_EyeOfHarmony extends GT_MetaTileEntity_Multibl + " L"); } BigInteger euPerTick = (outputEU_BigInt.subtract(usedEU.abs())) - .divide(BigInteger.valueOf(maxProgresstime())); + .divide(BigInteger.valueOf(Math.max(maxProgresstime(), 1))); if (abs(euPerTick.longValue()) < LongMath.pow(10, 12)) { str.add("Estimated EU/t: " + RED + formatNumbers(euPerTick) + RESET + " EU/t"); } else { |