Network: Include town noise levels in network game saves
Don't recalculate on load for network clients
This commit is contained in:
@@ -70,6 +70,8 @@
|
||||
|
||||
#include "safeguards.h"
|
||||
|
||||
bool _town_noise_no_update = false;
|
||||
|
||||
/**
|
||||
* Check whether the given tile is a hangar.
|
||||
* @param t the tile to of whether it is a hangar.
|
||||
@@ -2639,6 +2641,8 @@ Town *AirportGetNearestTown(const AirportSpec *as, TileIndex tile, const TileIte
|
||||
/** Recalculate the noise generated by the airports of each town */
|
||||
void UpdateAirportsNoise()
|
||||
{
|
||||
if (_town_noise_no_update) return;
|
||||
|
||||
for (Town *t : Town::Iterate()) t->noise_reached = 0;
|
||||
|
||||
for (const Station *st : Station::Iterate()) {
|
||||
|
Reference in New Issue
Block a user