(svn r19273) -Codechange: Return station joining error message when error is detected.

This commit is contained in:
alberth
2010-02-27 13:51:11 +00:00
parent 01562e2dfc
commit 9f437abd40
2 changed files with 11 additions and 6 deletions

View File

@@ -253,6 +253,7 @@ CommandCost CmdBuildRailWaypoint(TileIndex start_tile, DoCommandFlag flags, uint
Waypoint *wp = NULL;
TileArea new_location(TileArea(start_tile, width, height));
CommandCost ret = FindJoiningWaypoint(est, station_to_join, adjacent, new_location, &wp);
ret.SetGlobalErrorMessage();
if (ret.Failed()) return ret;
/* Check if there is an already existing, deleted, waypoint close to us that we can reuse. */