summaryrefslogtreecommitdiff
path: root/src/waypoint.cpp
diff options
context:
space:
mode:
authorrubidium <rubidium@openttd.org>2007-10-19 22:46:55 +0000
committerrubidium <rubidium@openttd.org>2007-10-19 22:46:55 +0000
commit8342c18fb5f96465c917f9f89ec31765b0c21c6c (patch)
tree94325422edf35b6645a697ffa3bfd15ed090bf01 /src/waypoint.cpp
parent3b08339a10df6c5aa761930565cd928c95aa0773 (diff)
downloadopenttd-8342c18fb5f96465c917f9f89ec31765b0c21c6c.tar.xz
(svn r11303) -Fix: EnsureNoVehicle and EnsureNoVehicleOnGround were both used to check whether there was no vehicle on the ground, except that the former didn't take care of aircraft shadows. So now we only use EnsureNoVehicleOnGround.
Diffstat (limited to 'src/waypoint.cpp')
-rw-r--r--src/waypoint.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/waypoint.cpp b/src/waypoint.cpp
index 34e6a7d8b..c4422f8d4 100644
--- a/src/waypoint.cpp
+++ b/src/waypoint.cpp
@@ -175,7 +175,7 @@ CommandCost CmdBuildTrainWaypoint(TileIndex tile, uint32 flags, uint32 p1, uint3
}
if (!CheckTileOwnership(tile)) return CMD_ERROR;
- if (!EnsureNoVehicle(tile)) return CMD_ERROR;
+ if (!EnsureNoVehicleOnGround(tile)) return CMD_ERROR;
tileh = GetTileSlope(tile, NULL);
if (tileh != SLOPE_FLAT &&
@@ -276,7 +276,7 @@ CommandCost RemoveTrainWaypoint(TileIndex tile, uint32 flags, bool justremove)
if (!IsTileType(tile, MP_RAILWAY) ||
!IsRailWaypoint(tile) ||
(!CheckTileOwnership(tile) && _current_player != OWNER_WATER) ||
- !EnsureNoVehicle(tile)) {
+ !EnsureNoVehicleOnGround(tile)) {
return CMD_ERROR;
}