Changeset - r4317:ba26f6003ffe
[Not reviewed]
master
0 1 0
truelight - 18 years ago 2006-08-20 11:41:34
truelight@openttd.org
(svn r5970) -Fix [FS#49]: town-growth removed houses under construction to make way for road. Not wanted behavoir (Rubidium)
1 file changed with 2 insertions and 3 deletions:
0 comments (0 inline, 0 general)
town_cmd.c
Show inline comments
 
@@ -770,9 +770,8 @@ static bool GrowTown(Town *t)
 
	// clearing some land and then building a road there.
 
	tile = t->xy;
 
	for (ptr = _town_coord_mod; ptr != endof(_town_coord_mod); ++ptr) {
 
		// Only work with plain land that not already has a house with GetHouseConstructionTick=0
 
		if ((!IsTileType(tile, MP_HOUSE) || GetHouseConstructionTick(tile) != 0) &&
 
				GetTileSlope(tile, NULL) == SLOPE_FLAT) {
 
		/* Only work with plain land that not already has a house */
 
		if (!IsTileType(tile, MP_HOUSE) && GetTileSlope(tile, NULL) == SLOPE_FLAT) {
 
			if (!CmdFailed(DoCommand(tile, 0, 0, DC_AUTO, CMD_LANDSCAPE_CLEAR))) {
 
				DoCommand(tile, GenRandomRoadBits(), t->index, DC_EXEC | DC_AUTO, CMD_BUILD_ROAD);
 
				_current_player = old_player;
0 comments (0 inline, 0 general)