summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeterN <peter@fuzzle.org>2019-04-20 02:21:25 +0100
committerGitHub <noreply@github.com>2019-04-20 02:21:25 +0100
commitd2b6176cdf9f37bea676972239471d950df4d531 (patch)
tree7b482665ed1f06ea270001e9110720f98e649f65
parent66a8db9dc5d2eaa586f19aef47b06d7bc08a732f (diff)
downloadopenttd-d2b6176cdf9f37bea676972239471d950df4d531.tar.xz
Add: NewGRF string codes to access PUSH/POP_COLOUR. (#7527)
-rw-r--r--src/newgrf_text.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/newgrf_text.cpp b/src/newgrf_text.cpp
index 4cba3c368..5387d6767 100644
--- a/src/newgrf_text.cpp
+++ b/src/newgrf_text.cpp
@@ -528,6 +528,9 @@ char *TranslateTTDPatchCodes(uint32 grfid, uint8 language_id, bool allow_newline
d += Utf8Encode(d, SCC_NEWGRF_PRINT_DWORD_DATE_LONG + code - 0x16);
break;
+ case 0x1F: d += Utf8Encode(d, SCC_PUSH_COLOUR); break;
+ case 0x20: d += Utf8Encode(d, SCC_POP_COLOUR); break;
+
default:
grfmsg(1, "missing handler for extended format code");
break;