Changeset - r16115:04910cbe2b9c
[Not reviewed]
master
0 1 0
yexo - 14 years ago 2010-09-17 15:16:19
yexo@openttd.org
(svn r20821) -Fix [FS#4129]: terraforming the land under objects could leave sloped or elevated sea tiles
1 file changed with 1 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/landscape.cpp
Show inline comments
 
@@ -624,12 +624,13 @@ CommandCost CmdLandscapeClear(TileIndex 
 
		 * However, we need to check stuff, which is not the same for all object tiles. (e.g. being on water or not) */
 
		if (_cleared_object_areas[i].area.Intersects(TileArea(tile, 1, 1))) {
 
			/* If a object is removed, it leaves either bare land or water. */
 
			if ((flags & DC_NO_WATER) && HasTileWaterClass(tile) && IsTileOnWater(tile)) {
 
				return_cmd_error(STR_ERROR_CAN_T_BUILD_ON_WATER);
 
			}
 
			if (do_clear && (flags & DC_EXEC)) DoClearSquare(tile);
 
			return cost;
 
		}
 
	}
 
	cost.AddCost(_tile_type_procs[GetTileType(tile)]->clear_tile_proc(tile, flags));
 
	if (do_clear && (flags & DC_EXEC)) DoClearSquare(tile);
 
	return cost;
0 comments (0 inline, 0 general)