lower potential operations if the cabinet is full

This commit is contained in:
Quantumlyy committed 2023-12-09 23:04:10 +01:00
1 parent b19979e88b
commit e88eb1756c
1 file changed
+3 -2
@@ -35,7 +35,8 @@ public class TileEntityPhialingCabinet extends TileEntity implements IAspectCont
@Override
public void updateEntity() {
// If there's no stored aspect we shouldn't even check for the above block.
if (aspect == null) return;
// We also don't need to run all the logic if the cabinet is full.
if (aspect == null || essentia.visSize() == maxAmount) return;
if (increment % Config.thaumcraftEssentiaBeePhialingCabinetTimeBetween == 0) {
try {
@@ -53,10 +54,10 @@ public class TileEntityPhialingCabinet extends TileEntity implements IAspectCont
if (Objects.equals(queenSpecies.getUID(), BeeSpecies.TC_ESSENTIA.getSpecies().getUID())) {
addToContainer(aspect, Config.thaumcraftEssentiaBeePhialingCabinetAmount);
increment = 0;
}
}
} catch (Exception ignored) {}
increment = 0;
}
increment++;