diff --git a/src/lang/english.txt b/src/lang/english.txt index 31a87d6262..1e781370e0 100644 --- a/src/lang/english.txt +++ b/src/lang/english.txt @@ -5012,6 +5012,7 @@ STR_ERROR_TUNNEL_RAMP_TOO_SHORT :{WHITE}... ramp STR_ERROR_TUNNEL_TOO_MANY :{WHITE}... too many tunnels STR_ERROR_NO_DRILLING_ABOVE_CHUNNEL :{WHITE}No oil rigs allowed above underwater tunnels. STR_ERROR_ANOTHER_TUNNEL_IN_THE_WAY_FOR_CHUNNEL :{WHITE}Three tiles are needed to pass under the other tunnel. +STR_ERROR_CHUNNEL_ONLY_OVER_SEA :{WHITE}Underwater tunnels are only allowed to cross sea... # Object related errors STR_ERROR_TOO_MANY_OBJECTS :{WHITE}... too many objects diff --git a/src/tunnelbridge_cmd.cpp b/src/tunnelbridge_cmd.cpp index f86a3e84a3..0ed3a53db0 100644 --- a/src/tunnelbridge_cmd.cpp +++ b/src/tunnelbridge_cmd.cpp @@ -734,9 +734,10 @@ CommandCost CmdBuildTunnel(TileIndex start_tile, DoCommandFlag flags, uint32 p1, end_tile += delta; tiles++; + if (IsTileType(end_tile, MP_WATER) && IsSea(end_tile)) is_chunnel = true; } /* The water was passed */ - is_chunnel = true; + if (!is_chunnel) return_cmd_error(STR_ERROR_CHUNNEL_ONLY_OVER_SEA); head_tiles = 0; found_tunnel_tile = INVALID_TILE; }