How it works
- Based on the vanilla Decider Combinator
- Periodically scans connected chests to find item stacks and determine their actual spoilage time
- Uses a hidden timer combinator to calculate the remaining spoilage time every tick without additional Lua script overhead. If no items are added or removed between scans, the countdown remains accurate to a single tick
Known limitations
- UPS spikes: Scanning inventories can cause temporary UPS spikes and I haven't found a way to completely avoid these spikes. Unfortunately,
Spoilage Combinatorhas the same issue as Spoilage Scanner. This is a limitation of the Factorio API that mods cannot work around - Multiplayer GUI flicker: When opening the combinator in multiplayer, the vanilla Decider Combinator interface may briefly appear before being replaced by the Spoilage Combinator GUI a few milliseconds later
Differences from Spoilage Scanner
- Outputs remaining spoilage time in ticks instead of freshness %
- Reads chests and belts connected via circuit wires
- Does not calculate average freshness