diff options
Diffstat (limited to 'road_map.c')
-rw-r--r-- | road_map.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/road_map.c b/road_map.c index 8702f7692..3573902bf 100644 --- a/road_map.c +++ b/road_map.c @@ -52,9 +52,13 @@ RoadBits GetAnyRoadBits(TileIndex tile) TrackBits GetAnyRoadTrackBits(TileIndex tile) { - if (IsTileType(tile, MP_STREET) && !IsTileDepotType(tile, TRANSPORT_ROAD)) { - uint32 r = GetTileTrackStatus(tile, TRANSPORT_ROAD); - return (byte)(r | (r >> 8)); + uint32 r; + + // Don't allow building through road depot tiles. + if (IsTileType(tile, MP_STREET) && IsTileDepotType(tile, TRANSPORT_ROAD)) { + return 0; } - return 0; + + r = GetTileTrackStatus(tile, TRANSPORT_ROAD); + return (byte)(r | (r >> 8)); } |