(svn r19560) -Fix: Bridge build error message should not show the same message twice.

This commit is contained in:
alberth 2010-04-04 14:19:17 +00:00
parent 7f5a0751e2
commit fb4ca3e569

View File

@ -248,9 +248,9 @@ CommandCost CmdBuildBridge(TileIndex end_tile, DoCommandFlag flags, uint32 p1, u
uint bridge_len = GetTunnelBridgeLength(tile_start, tile_end);
if (transport_type != TRANSPORT_WATER) {
/* set and test bridge length, availability */
if (!CheckBridgeAvailability(bridge_type, bridge_len, flags)) return_cmd_error(STR_ERROR_CAN_T_BUILD_BRIDGE_HERE);
if (!CheckBridgeAvailability(bridge_type, bridge_len, flags)) return CMD_ERROR;
} else {
if (bridge_len > (_settings_game.construction.longbridges ? 100U : 16U)) return_cmd_error(STR_ERROR_CAN_T_BUILD_BRIDGE_HERE);
if (bridge_len > (_settings_game.construction.longbridges ? 100U : 16U)) return CMD_ERROR;
}
/* retrieve landscape height and ensure it's on land */