summaryrefslogtreecommitdiff
path: root/src/strings.cpp
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2011-02-05 20:37:00 +0000
committerfrosch <frosch@openttd.org>2011-02-05 20:37:00 +0000
commitfaa2a26ae15d6a8cf986059ed504b3371e6c3e37 (patch)
tree056b2420018a00942522602d10bab15660f9b86c /src/strings.cpp
parent2679051c68ea218ca00f4fe1bcadbbb86d4ecb22 (diff)
downloadopenttd-faa2a26ae15d6a8cf986059ed504b3371e6c3e37.tar.xz
(svn r21986) -Codechange: Add helper function to test whether an engine is still associated to a GRF.
Diffstat (limited to 'src/strings.cpp')
-rw-r--r--src/strings.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/strings.cpp b/src/strings.cpp
index 42e0a9450..1edea200b 100644
--- a/src/strings.cpp
+++ b/src/strings.cpp
@@ -1110,7 +1110,7 @@ static char *FormatString(char *buff, const char *str_arg, int64 *argv, const in
assert(e != NULL);
- if (e->name != NULL && e->info.string_id != STR_NEWGRF_INVALID_ENGINE) {
+ if (e->name != NULL && e->IsEnabled()) {
buff = strecpy(buff, e->name, last);
} else {
buff = GetStringWithArgs(buff, e->info.string_id, NULL, NULL, last);