fixed radiolysis machine crashing when running too fast

This commit is contained in:
Boblet 2022-04-15 08:02:36 +02:00
parent 218b43933e
commit 646d22b4e4

View File

@ -127,7 +127,7 @@ public class TileEntityMachineRadiolysis extends TileEntityMachineBase implement
setupTanks(); setupTanks();
if(heat > 100) { if(heat > 100) {
int crackTime = (int) Math.min(-0.1 * (heat - 100) + 30, 5); int crackTime = (int) Math.max(-0.1 * (heat - 100) + 30, 5);
if(worldObj.getTotalWorldTime() % crackTime == 0) if(worldObj.getTotalWorldTime() % crackTime == 0)
crack(); crack();