From 860a538adc56a678f640f606692ea7ca00c8d424 Mon Sep 17 00:00:00 2001 From: rubidium Date: Thu, 10 Sep 2009 14:37:55 +0000 Subject: (svn r17495) -Codechange: replace 'Depot::Get(GetDepotIndex(tile))->index' with GetDepotIndex(tile) --- src/road_cmd.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/road_cmd.cpp') 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); -- cgit v1.2.3-54-g00ecf