summaryrefslogtreecommitdiff
path: root/src/station_cmd.cpp
diff options
context:
space:
mode:
authorsmatz <smatz@openttd.org>2007-12-17 22:29:27 +0000
committersmatz <smatz@openttd.org>2007-12-17 22:29:27 +0000
commit0b08f7370ddd778da13ed5426c8c4d24fe0d5432 (patch)
tree4b515d99becc25cc7fb8461375ce7ffa41682f47 /src/station_cmd.cpp
parentbda9d4a23633c4ebb6ad18c29218deaf1a92d55d (diff)
downloadopenttd-0b08f7370ddd778da13ed5426c8c4d24fe0d5432.tar.xz
(svn r11657) -Fix: show better error message when trying to convert rail
-Codechange: merge DoConvert functions into one, make test and exec runs the same for tunnels/bridges
Diffstat (limited to 'src/station_cmd.cpp')
-rw-r--r--src/station_cmd.cpp23
1 files changed, 0 insertions, 23 deletions
diff --git a/src/station_cmd.cpp b/src/station_cmd.cpp
index 0e189bd05..dc077e27f 100644
--- a/src/station_cmd.cpp
+++ b/src/station_cmd.cpp
@@ -1290,29 +1290,6 @@ static CommandCost RemoveRailroadStation(Station *st, TileIndex tile, uint32 fla
}
/**
- * Switches the rail type at a railway station tile.
- * @param tile The tile on which the railtype is to be convert.
- * @param totype The railtype we want to convert to
- * @param exec Switches between test and execute mode
- * @return The cost and state of the operation
- * @retval CMD_ERROR An error occured during the operation.
- */
-CommandCost DoConvertStationRail(TileIndex tile, RailType totype, bool exec)
-{
- /* Tile is not a railroad station? */
- if (!IsRailwayStation(tile)) return CMD_ERROR;
-
- if (exec) {
- SetRailType(tile, totype);
- MarkTileDirtyByTile(tile);
- YapfNotifyTrackLayoutChange(tile, GetRailStationTrack(tile));
- VehicleFromPos(tile, NULL, &UpdateTrainPowerProc);
- }
-
- return CommandCost(RailConvertCost(GetRailType(tile), totype));
-}
-
-/**
* @param truck_station Determines whether a stop is RoadStop::BUS or RoadStop::TRUCK
* @param st The Station to do the whole procedure for
* @return a pointer to where to link a new RoadStop*