1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-11-06 08:22:59 +00:00

Merge branch 'mc-1.13.x' into mc-1.14-fabric

This commit is contained in:
SquidDev
2019-05-06 21:53:59 +01:00
6 changed files with 392 additions and 2 deletions

View File

@@ -134,7 +134,7 @@ public final class MainThread
// Of course, we'll go over the MAX_TICK_TIME most of the time, but eventually that overrun will accumulate
// and we'll skip a whole tick - bringing the average back down again.
currentTick++;
budget += Math.min( budget + ComputerCraft.maxMainGlobalTime, ComputerCraft.maxMainGlobalTime );
budget = Math.min( budget + ComputerCraft.maxMainGlobalTime, ComputerCraft.maxMainGlobalTime );
canExecute = budget > 0;
// Cool down any warm computers.

View File

@@ -224,7 +224,7 @@ final class MainThreadExecutor implements IWorkMonitor
{
state = State.COOLING;
currentTick = MainThread.currentTick();
budget += Math.min( budget + ComputerCraft.maxMainComputerTime, ComputerCraft.maxMainComputerTime );
budget = Math.min( budget + ComputerCraft.maxMainComputerTime, ComputerCraft.maxMainComputerTime );
if( budget < ComputerCraft.maxMainComputerTime ) return false;
state = State.COOL;