Add null check to prevent
@@ -61,6 +61,7 @@ public class TileEntityTurbineCasing extends TileEntityMultiblock<SynchronizedTu
double rate = structure.lowerVolume * (structure.getDispersers() * MekanismGeneratorsConfig.generators.turbineDisperserGasFlow.get());
rate = Math.min(rate, structure.vents * MekanismGeneratorsConfig.generators.turbineVentGasFlow.get());
+ if (!energyMultiplier.isZero()) {
double proportion = stored / (double) structure.getSteamCapacity();
double origRate = rate;
rate = Math.min(Math.min(stored, rate), energyNeeded.divide(energyMultiplier).doubleValue()) * proportion;
@@ -73,6 +74,7 @@ public class TileEntityTurbineCasing extends TileEntityMultiblock<SynchronizedTu
}
structure.clientFlow = (long) rate;
structure.ventTank.setStack(new FluidStack(Fluids.WATER, Math.min(MathUtils.clampToInt(rate), structure.condensers * MekanismGeneratorsConfig.generators.condenserRate.get())));
+ }
} else {
structure.clientFlow = 0;
}
