(svn r11276) -Codechange: be more consistent with naming of some accessors.

-Fix: make sure canals are never owned by water. Based on a patch by boekabart.
This commit is contained in:
rubidium
2007-10-16 19:48:58 +00:00
parent 4f512a70c3
commit ba7c595d84
8 changed files with 52 additions and 17 deletions

View File

@@ -933,7 +933,7 @@ static bool GrowTownWithBridge(const Town *t, TileIndex tile, RoadBits rcmd)
return false;
}
bridge_tile = TILE_MASK(bridge_tile + TileOffsByDiagDir(bridge_dir));
} while (IsClearWaterTile(bridge_tile));
} while (IsWaterTile(bridge_tile));
/* no water tiles in between? */
if (bridge_length == 1) return false;
@@ -1072,7 +1072,7 @@ static void GrowTownInTile(TileIndex *tile_ptr, RoadBits cur_rb, DiagDirection t
TileIndex house_tile = TileAddByDiagDir(tile, target_dir); // position of a possible house
/* Don't walk into water. */
if (IsClearWaterTile(house_tile)) return;
if (IsWaterTile(house_tile)) return;
switch (_patches.town_layout) {
default: NOT_REACHED();
@@ -1121,7 +1121,7 @@ static void GrowTownInTile(TileIndex *tile_ptr, RoadBits cur_rb, DiagDirection t
}
/* Return if a water tile */
if (IsClearWaterTile(tile)) return;
if (IsWaterTile(tile)) return;
/* Make the roads look nicer */
rcmd = CleanUpRoadBits(tile, rcmd);