Mercurial > hg > openttd
changeset 15461:3f7f8e8a342e draft
(svn r20110) -Fix [FS#3695]: Do not allow building a rail track to the water using a tree-tile.
author | alberth <alberth@openttd.org> |
---|---|
date | Sat, 10 Jul 2010 13:04:31 +0000 |
parents | e4312d30348a |
children | fd70c2a4db8a |
files | src/rail_cmd.cpp |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/src/rail_cmd.cpp +++ b/src/rail_cmd.cpp @@ -329,7 +329,7 @@ static CommandCost CheckRailSlope(Slope tileh, TrackBits rail_bits, TrackBits existing, TileIndex tile) { /* don't allow building on the lower side of a coast */ - if (IsTileType(tile, MP_WATER) || (IsTileType(tile, MP_RAILWAY) && (GetRailGroundType(tile) == RAIL_GROUND_WATER))) { + if (GetFloodingBehaviour(tile) != FLOOD_NONE) { if (!IsSteepSlope(tileh) && ((~_valid_tracks_on_leveled_foundation[tileh] & (rail_bits | existing)) != 0)) return_cmd_error(STR_ERROR_CAN_T_BUILD_ON_WATER); }