mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-02-05 22:04:39 +00:00
(svn r14296) -Codechange: there is no case where an invalid waypoint index should be passed to be drawn as a string.
This commit is contained in:
parent
a2b00e24b6
commit
8f42c38039
@ -822,9 +822,9 @@ static char* FormatString(char* buff, const char* str, const int64* argv, uint c
|
|||||||
case SCC_WAYPOINT_NAME: { // {WAYPOINT}
|
case SCC_WAYPOINT_NAME: { // {WAYPOINT}
|
||||||
Waypoint *wp = GetWaypoint(GetInt32(&argv));
|
Waypoint *wp = GetWaypoint(GetInt32(&argv));
|
||||||
|
|
||||||
if (!wp->IsValid()) { // waypoint doesn't exist anymore
|
assert(wp->IsValid());
|
||||||
buff = GetStringWithArgs(buff, STR_UNKNOWN_DESTINATION, NULL, last);
|
|
||||||
} else if (wp->name != NULL) {
|
if (wp->name != NULL) {
|
||||||
buff = strecpy(buff, wp->name, last);
|
buff = strecpy(buff, wp->name, last);
|
||||||
} else {
|
} else {
|
||||||
int64 temp[2];
|
int64 temp[2];
|
||||||
|
Loading…
Reference in New Issue
Block a user