MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / RecomputeCatchmentForAll

Method RecomputeCatchmentForAll

src/station.cpp:534–539  ·  view source on GitHub ↗

* Recomputes catchment of all stations. * This will additionally recompute nearby stations for all towns and industries. */ static */

Source from the content-addressed store, hash-verified

532 * This will additionally recompute nearby stations for all towns and industries.
533 */
534/* static */ void Station::RecomputeCatchmentForAll()
535{
536 for (Town *t : Town::Iterate()) { t->stations_near.clear(); }
537 for (Industry *i : Industry::Iterate()) { i->stations_near.clear(); }
538 for (Station *st : Station::Iterate()) { st->RecomputeCatchment(true); }
539}
540
541/************************************************************************/
542/* StationRect implementation */

Callers

nothing calls this directly

Calls 2

RecomputeCatchmentMethod · 0.80
clearMethod · 0.45

Tested by

no test coverage detected