openttd updated to 1.5.0-beta2
--HG-- branch : openttd
This commit is contained in:
+14
-2
@@ -1,4 +1,4 @@
|
||||
/* $Id: newgrf_text.cpp 26244 2014-01-12 18:01:33Z frosch $ */
|
||||
/* $Id: newgrf_text.cpp 26713 2014-08-03 11:59:07Z frosch $ */
|
||||
|
||||
/*
|
||||
* This file is part of OpenTTD.
|
||||
@@ -33,6 +33,8 @@
|
||||
#include "table/strings.h"
|
||||
#include "table/control_codes.h"
|
||||
|
||||
#include "safeguards.h"
|
||||
|
||||
#define GRFTAB 28
|
||||
#define TABSIZE 11
|
||||
|
||||
@@ -229,7 +231,7 @@ struct UnmappedChoiceList : ZeroedMemoryAllocator {
|
||||
/* In case of a (broken) NewGRF without a default,
|
||||
* assume an empty string. */
|
||||
grfmsg(1, "choice list misses default value");
|
||||
this->strings[0] = strdup("");
|
||||
this->strings[0] = stredup("");
|
||||
}
|
||||
|
||||
char *d = old_d;
|
||||
@@ -1058,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) {
|
||||
|
||||
Reference in New Issue
Block a user