mirror of
https://github.com/tobspr/shapez.io.git
synced 2025-06-13 13:04:03 +00:00
Carry forward only when processing is continuous
This commit is contained in:
parent
21a9027add
commit
9d4f5c50fe
@ -20,10 +20,8 @@ export class ItemProcessorSystem extends GameSystemWithFilter {
|
||||
const ejectorComp = entity.components.ItemEjector;
|
||||
|
||||
// First of all, process the current recipe
|
||||
if (processorComp.secondsUntilEject > 0) {
|
||||
processorComp.secondsUntilEject =
|
||||
processorComp.secondsUntilEject - this.root.dynamicTickrate.deltaSeconds;
|
||||
}
|
||||
|
||||
if (G_IS_DEV && globalConfig.debug.instantProcessors) {
|
||||
processorComp.secondsUntilEject = 0;
|
||||
@ -82,6 +80,11 @@ export class ItemProcessorSystem extends GameSystemWithFilter {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Remove time carryover if processing is not continuous
|
||||
if (processorComp.secondsUntilEject < 0) {
|
||||
processorComp.secondsUntilEject = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user