mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-03-06 14:27:16 +00:00
(svn r15687) -Fix [FS#2723]: wrong/misleading error message when autorail builds nothing when trying to build over signals in the wrong way.
This commit is contained in:
parent
bd2e1ac903
commit
8ed58f2b94
@ -699,7 +699,7 @@ static CommandCost CmdRailTrackHelper(TileIndex tile, DoCommandFlag flags, uint3
|
|||||||
if (!IsDiagonalTrackdir(trackdir)) ToggleBit(trackdir, 0);
|
if (!IsDiagonalTrackdir(trackdir)) ToggleBit(trackdir, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (total_cost.GetCost() == 0) ? CommandCost(remove ? INVALID_STRING_ID : STR_1007_ALREADY_BUILT) : total_cost;
|
return (total_cost.GetCost() == 0) ? CommandCost(remove ? INVALID_STRING_ID : (_error_message == INVALID_STRING_ID ? STR_1007_ALREADY_BUILT : _error_message)) : total_cost;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Build rail on a stretch of track.
|
/** Build rail on a stretch of track.
|
||||||
|
Loading…
Reference in New Issue
Block a user