Mini bug: habitats may report loss of power with different speeds

In Building.UpdateFrameThread() you are checking whether a building needs to report a problem. Power and missing resources are using a 10s timer, integrating the time in the private field missingResourceDuration. This works perfectly fine for FactoryProductionLogic ConsumerProducers, but not for habitats. They use the timer only for missing power. But if that happens, then there is no way (except upgrade or downgrade, which replaces the building) to reset the missingResourceDuration.

You need to add an else to the check if (habitat.ShouldMoveOut()) and reset the timer there. But to be honest I find the timer kind of useless for both FactoryProductionLogic and habitats. If they have a power or input resource problem, why not report so immediately? If habitats are lacking resources you are already doing that, I suggest simply doing it for all of the above.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.