summaryrefslogtreecommitdiff
path: root/src/road_cmd.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/road_cmd.cpp')
-rw-r--r--src/road_cmd.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/road_cmd.cpp b/src/road_cmd.cpp
index 9f5787044..e94d9bb0e 100644
--- a/src/road_cmd.cpp
+++ b/src/road_cmd.cpp
@@ -1266,7 +1266,7 @@ void UpdateNearestTownForRoadTiles(bool invalidate)
assert(!invalidate || _generating_world);
for (TileIndex t = 0; t < MapSize(); t++) {
- if (IsTileType(t, MP_ROAD) && !HasTownOwnedRoad(t)) {
+ if (IsTileType(t, MP_ROAD) && !IsRoadDepot(t) && !HasTownOwnedRoad(t)) {
TownID tid = (TownID)INVALID_TOWN;
if (!invalidate) {
const Town *town = CalcClosestTownFromTile(t);