diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java index 8fd31a9d..b42d14cd 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine.java @@ -163,7 +163,7 @@ public abstract class GT_MetaTileEntity_LargeTurbine extends GT_MetaTileEntity_M this.mMaxProgresstime = 1; this.mEfficiencyIncrease = (10); if(this.mDynamoHatches.size()>0){ - if(this.mDynamoHatches.get(0).getBaseMetaTileEntity().getOutputVoltage() < (mEUt * mEfficiency) / 10000){ + if(this.mDynamoHatches.get(0).getBaseMetaTileEntity().getOutputVoltage() < (int)((long)mEUt * (long)mEfficiency / 10000L)){ explodeMultiblock();} } return true; @@ -223,4 +223,4 @@ public abstract class GT_MetaTileEntity_LargeTurbine extends GT_MetaTileEntity_M return true; } -} \ No newline at end of file +} diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java index c5507e0b..963a4efc 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Gas.java @@ -114,9 +114,9 @@ public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeT if (efficiency < 0) efficiency = 0; // Can happen with really ludicrously poor inefficiency. tEU *= efficiency; - tEU = Math.max(1, tEU * aBaseEff / 10000); + tEU = Math.max(1, (int)((long)tEU * (long)aBaseEff / 10000L)); } else { - tEU = tEU * aBaseEff / 10000; + tEU = (int)((long)tEU * (long)aBaseEff / 10000L); } return tEU; @@ -126,4 +126,4 @@ public class GT_MetaTileEntity_LargeTurbine_Gas extends GT_MetaTileEntity_LargeT } -} \ No newline at end of file +} diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java index aa1f46af..8447b748 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_HPSteam.java @@ -103,13 +103,13 @@ public class GT_MetaTileEntity_LargeTurbine_HPSteam extends GT_MetaTileEntity_La float efficiency = 1.0f - Math.abs(((totalFlow - (float) aOptFlow) / aOptFlow)); if(totalFlow>aOptFlow){efficiency = 1.0f;} tEU *= efficiency; - tEU = Math.max(1, tEU * aBaseEff / 10000); + tEU = Math.max(1, (int)((long)tEU * (long)aBaseEff / 10000L)); } else { - tEU = tEU * aBaseEff / 10000; + tEU = (int)((long)tEU * (long)aBaseEff / 10000L); } return tEU; } -} \ No newline at end of file +} diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java index 923eaabc..6abe8105 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Plasma.java @@ -130,9 +130,9 @@ public class GT_MetaTileEntity_LargeTurbine_Plasma extends GT_MetaTileEntity_Lar if (efficiency < 0) efficiency = 0; // Can happen with really ludicrously poor inefficiency. tEU *= efficiency; - tEU = Math.max(1, tEU * aBaseEff / 10000); + tEU = Math.max(1, (int)((long)tEU * (long)aBaseEff / 10000L)); } else { - tEU = tEU * aBaseEff / 10000; + tEU = (int)((long)tEU * (long)aBaseEff / 10000L); } return tEU; diff --git a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java index 1023235c..262d7bb7 100644 --- a/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java +++ b/src/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_LargeTurbine_Steam.java @@ -111,11 +111,11 @@ public class GT_MetaTileEntity_LargeTurbine_Steam extends GT_MetaTileEntity_Larg float efficiency = 1.0f - Math.abs(((totalFlow - (float) aOptFlow) / aOptFlow)); if(totalFlow>aOptFlow){efficiency = 1.0f;} tEU *= efficiency; - tEU = Math.max(1, tEU * aBaseEff / 20000); + tEU = Math.max(1, (int)((long)tEU * (long)aBaseEff / 20000L)); } else { - tEU = tEU * aBaseEff / 20000; + tEU = (int)((long)tEU * (long)aBaseEff / 20000L); } return tEU; } -} \ No newline at end of file +}