Changeset - r5445:1fea753fcd36
[Not reviewed]
master
0 1 0
rubidium - 18 years ago 2006-12-31 13:24:44
rubidium@openttd.org
(svn r7698) -Fix (r7573): towns did not grow beyond bridges.
1 file changed with 7 insertions and 6 deletions:
0 comments (0 inline, 0 general)
town_cmd.c
Show inline comments
 
@@ -612,15 +612,16 @@ static void GrowTownInTile(TileIndex* ti
 
	} else {
 
		int i;
 

	
 
		// Reached a tunnel? Then continue at the other side of it.
 
		if (IsTunnelTile(tile) && GetTunnelTransportType(tile) == TRANSPORT_ROAD) {
 
			*tile_ptr = GetOtherTunnelEnd(tile);
 
		// Reached a tunnel/bridge? Then continue at the other side of it.
 
		if (IsTileType(tile, MP_TUNNELBRIDGE)) {
 
			if (IsTunnel(tile) && GetTunnelTransportType(tile) == TRANSPORT_ROAD) {
 
				*tile_ptr = GetOtherTunnelEnd(tile);
 
			} else if (IsBridge(tile) && GetBridgeTransportType(tile) == TRANSPORT_ROAD) {
 
				*tile_ptr = GetOtherBridgeEnd(tile);
 
			}
 
			return;
 
		}
 

	
 
		// For any other kind of tunnel/bridge, bail out.
 
		if (IsTileType(tile, MP_TUNNELBRIDGE)) return;
 

	
 
		// Possibly extend the road in a direction.
 
		// Randomize a direction and if it has a road, bail out.
 
		i = GB(Random(), 0, 2);
0 comments (0 inline, 0 general)