mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-08-21 13:39:09 +00:00
(svn r19415) -Codechange: Forward CommandCost with an error back to the caller.
This commit is contained in:
@@ -904,7 +904,7 @@ CommandCost CmdBuildRoadDepot(TileIndex tile, DoCommandFlag flags, uint32 p1, ui
|
||||
}
|
||||
|
||||
CommandCost cost = DoCommand(tile, 0, 0, flags, CMD_LANDSCAPE_CLEAR);
|
||||
if (cost.Failed()) return CMD_ERROR;
|
||||
if (cost.Failed()) return cost;
|
||||
|
||||
if (MayHaveBridgeAbove(tile) && IsBridgeAbove(tile)) return_cmd_error(STR_ERROR_MUST_DEMOLISH_BRIDGE_FIRST);
|
||||
|
||||
|
Reference in New Issue
Block a user