Minor fixes in CmdRemoveSingleSignal
Whitespace fixes
This commit is contained in:
@@ -1482,7 +1482,7 @@ CommandCost CmdRemoveSingleSignal(TileIndex tile, DoCommandFlag flags, uint32 p1
|
|||||||
cost *= ((GetTunnelBridgeLength(tile, end) + 4) >> 2);
|
cost *= ((GetTunnelBridgeLength(tile, end) + 4) >> 2);
|
||||||
|
|
||||||
CommandCost ret = EnsureNoTrainOnTrack(GetOtherTunnelBridgeEnd(tile), track);
|
CommandCost ret = EnsureNoTrainOnTrack(GetOtherTunnelBridgeEnd(tile), track);
|
||||||
//if (ret.Failed()) return ret;
|
if (ret.Failed()) return ret;
|
||||||
} else {
|
} else {
|
||||||
if (!ValParamTrackOrientation(track) || !IsPlainRailTile(tile) || !HasTrack(tile, track)) {
|
if (!ValParamTrackOrientation(track) || !IsPlainRailTile(tile) || !HasTrack(tile, track)) {
|
||||||
return_cmd_error(STR_ERROR_THERE_IS_NO_RAILROAD_TRACK);
|
return_cmd_error(STR_ERROR_THERE_IS_NO_RAILROAD_TRACK);
|
||||||
@@ -1491,11 +1491,13 @@ CommandCost CmdRemoveSingleSignal(TileIndex tile, DoCommandFlag flags, uint32 p1
|
|||||||
return_cmd_error(STR_ERROR_THERE_ARE_NO_SIGNALS);
|
return_cmd_error(STR_ERROR_THERE_ARE_NO_SIGNALS);
|
||||||
}
|
}
|
||||||
CommandCost ret = EnsureNoTrainOnTrack(tile, track);
|
CommandCost ret = EnsureNoTrainOnTrack(tile, track);
|
||||||
//if (ret.Failed()) return ret;
|
if (ret.Failed()) return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Only water can remove signals from anyone */
|
/* Only water can remove signals from anyone */
|
||||||
if (_current_company != OWNER_WATER) {
|
if (_current_company != OWNER_WATER) {
|
||||||
|
CommandCost ret = CheckTileOwnership(tile);
|
||||||
|
if (ret.Failed()) return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Do it? */
|
/* Do it? */
|
||||||
|
Reference in New Issue
Block a user