summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2014-08-03 11:59:07 +0000
committerfrosch <frosch@openttd.org>2014-08-03 11:59:07 +0000
commit9119ebe2cefdd58ca4a13774ddf685e1af7ba21a (patch)
tree70356bdb80252870f30a7d025ffa99d54f87ce1e
parent9490aab2d7e9437c5c3ce358482f933e55a0450f (diff)
downloadopenttd-9119ebe2cefdd58ca4a13774ddf685e1af7ba21a.tar.xz
(svn r26713) -Fix (r23027): [NewGRF] Parameters to SCC_NEWGRF_PUSH_WORD and SCC_NEWGRF_UNPRINT were not skipped during drawing.
-rw-r--r--src/newgrf_text.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/newgrf_text.cpp b/src/newgrf_text.cpp
index 549353122..daf9db443 100644
--- a/src/newgrf_text.cpp
+++ b/src/newgrf_text.cpp
@@ -1060,6 +1060,16 @@ uint RemapNewGRFStringControlCode(uint scc, char *buf_start, char **buff, const
*argv = MapGRFStringID(_newgrf_textrefstack.grffile->grfid, _newgrf_textrefstack.PopUnsignedWord());
break;
}
+ } else {
+ /* Consume additional parameter characters */
+ switch (scc) {
+ default: break;
+
+ case SCC_NEWGRF_PUSH_WORD:
+ case SCC_NEWGRF_UNPRINT:
+ Utf8Consume(str);
+ break;
+ }
}
switch (scc) {