summaryrefslogtreecommitdiff
path: root/src/water_cmd.cpp
diff options
context:
space:
mode:
authoryexo <yexo@openttd.org>2010-08-19 13:44:41 +0000
committeryexo <yexo@openttd.org>2010-08-19 13:44:41 +0000
commit85740a02832c9c474833f929b4464eba06be66d3 (patch)
tree9e10d3039ec55bce24ceebffd0c4c949be1f45ee /src/water_cmd.cpp
parent16be24e13acf17a3292b490196d301b5b1aa1056 (diff)
downloadopenttd-85740a02832c9c474833f929b4464eba06be66d3.tar.xz
(svn r20559) -Fix [FS#4045]: make sure that all vehicles are build in the most northern depot/hangar tile
Diffstat (limited to 'src/water_cmd.cpp')
-rw-r--r--src/water_cmd.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/water_cmd.cpp b/src/water_cmd.cpp
index 3c0e6ee2f..78d190d69 100644
--- a/src/water_cmd.cpp
+++ b/src/water_cmd.cpp
@@ -172,7 +172,6 @@ static CommandCost RemoveShipDepot(TileIndex tile, DoCommandFlag flags)
}
if (flags & DC_EXEC) {
- /* Kill the depot, which is registered at the northernmost tile. Use that one */
delete Depot::GetByTile(tile);
MakeWaterKeepingClass(tile, GetTileOwner(tile));
@@ -1180,9 +1179,7 @@ static TrackStatus GetTileTrackStatus_Water(TileIndex tile, TransportType mode,
static bool ClickTile_Water(TileIndex tile)
{
if (GetWaterTileType(tile) == WATER_TILE_DEPOT) {
- TileIndex tile2 = GetOtherShipDepotTile(tile);
-
- ShowDepotWindow(tile < tile2 ? tile : tile2, VEH_SHIP);
+ ShowDepotWindow(GetShipDepotNorthTile(tile), VEH_SHIP);
return true;
}
return false;