Improve performance by reducing unnecessary lighting updates (#32)

Introduce 5 second delay on changing ambient lighting when a machine shuts off. IActiveState now has a concept of wasActiveRecently to enable rendering/block updates to have some wiggle room.
This commit is contained in:
Dave Smith authored and GitHub committed 2019-03-14 12:38:16 -06:00
1 parent 8c79baccf6
commit 2c6d666b89
7 files changed
+47 -49

No files matched your search

@@ -196,9 +196,7 @@ public class TileEntityFactory extends TileEntityMachine implements IComputerInt
System.arraycopy(progress, 0, factory.progress, 0, tier.processes);
factory.recipeTicks = recipeTicks;
factory.clientActive = clientActive;
factory.isActive = isActive;
factory.updateDelay = updateDelay;
factory.prevEnergy = prevEnergy;
factory.gasTank.setGas(gasTank.getGas());
factory.sorting = sorting;