mirror of https://github.com/OpenTTD/OpenTTD
Fix #9918: Reset industy last production year on scenario start
parent
2cdb0cb084
commit
470c902bdc
|
@ -844,6 +844,11 @@ static void OnStartScenario()
|
||||||
{
|
{
|
||||||
/* Reset engine pool to simplify changing engine NewGRFs in scenario editor. */
|
/* Reset engine pool to simplify changing engine NewGRFs in scenario editor. */
|
||||||
EngineOverrideManager::ResetToCurrentNewGRFConfig();
|
EngineOverrideManager::ResetToCurrentNewGRFConfig();
|
||||||
|
|
||||||
|
/* Make sure all industries were built "this year", to avoid too early closures. (#9918) */
|
||||||
|
for (Industry *i : Industry::Iterate()) {
|
||||||
|
i->last_prod_year = _cur_year;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue