🌐Corrundum


This mod adds Corrundum, a planet centered around the chemistry of Sulfur.

Content
a month ago
2.0
29.9K
Factorio: Space Age Icon Space Age Mod
Planets Environment Mining Fluids Manufacturing Storage

b 440ms update time

8 months ago

Every few dozen of seconds this mod takes over 400ms to update, freezing game for a bit...

https://prnt.sc/5cMdoiHxneFg

8 months ago

The issue seems to be that every other tick the mod does a large batch of processing, instead of distributing that processing over several ticks.
it is for the labs and the ice box.

It literally scans every surface, that should be the cause.

8 months ago
(updated 8 months ago)

Yea Front rider is right. I did this because there was a bug where the cache isn't updated correctly, so I just updated it every 440ms. I'll implement a per surface batch.

EDIT: Per surface batching not necessary. Fixed the bug that caused me to re-validate the cache every couple of seconds.

8 months ago

Fixed. Reason I periodically updated was because of a bug. Turns out I you can't respond to the same event with different filters. You can only respond to a unique event once. If you bind the same event while already bound, you lose whatever functionality you had bound to it. I don't like responding to every built or destroy event, but it is necessary because you can't filter with multiple names. Either way, cache system works correctly now. And removing the pressure lab or ice box won't cause a crash.