1
0
Fork 0

(svn r7698) -Fix (r7573): towns did not grow beyond bridges.

release/0.6
rubidium 2006-12-31 13:24:44 +00:00
parent d746829809
commit 6d5db058e1
1 changed files with 7 additions and 6 deletions

View File

@ -612,15 +612,16 @@ static void GrowTownInTile(TileIndex* tile_ptr, RoadBits mask, int block, Town*
} else { } else {
int i; int i;
// Reached a tunnel? Then continue at the other side of it. // Reached a tunnel/bridge? Then continue at the other side of it.
if (IsTunnelTile(tile) && GetTunnelTransportType(tile) == TRANSPORT_ROAD) { if (IsTileType(tile, MP_TUNNELBRIDGE)) {
*tile_ptr = GetOtherTunnelEnd(tile); if (IsTunnel(tile) && GetTunnelTransportType(tile) == TRANSPORT_ROAD) {
*tile_ptr = GetOtherTunnelEnd(tile);
} else if (IsBridge(tile) && GetBridgeTransportType(tile) == TRANSPORT_ROAD) {
*tile_ptr = GetOtherBridgeEnd(tile);
}
return; return;
} }
// For any other kind of tunnel/bridge, bail out.
if (IsTileType(tile, MP_TUNNELBRIDGE)) return;
// Possibly extend the road in a direction. // Possibly extend the road in a direction.
// Randomize a direction and if it has a road, bail out. // Randomize a direction and if it has a road, bail out.
i = GB(Random(), 0, 2); i = GB(Random(), 0, 2);