|
@@ -227,13 +227,14 @@ static GRFLineToSpriteOverride _grf_line
|
|
|
* Function is essentially the same as DEBUG(grf, severity, ...) with the
|
|
|
* addition of file:line information when parsing grf files.
|
|
|
* NOTE: for the above reason(s) grfmsg() should ONLY be used for
|
|
|
* loading/parsing grf files, not for runtime debug messages as there
|
|
|
* is no file information available during that time.
|
|
|
* @param severity debugging severity level, see debug.h
|
|
|
* @param str message in printf() format */
|
|
|
* @param str message in printf() format
|
|
|
*/
|
|
|
void CDECL grfmsg(int severity, const char *str, ...)
|
|
|
{
|
|
|
char buf[1024];
|
|
|
va_list va;
|
|
|
|
|
|
va_start(va, str);
|
|
@@ -6794,13 +6795,14 @@ static void InitNewGRFFile(const GRFConf
|
|
|
*_grf_files.Append() = _cur_grffile = newfile;
|
|
|
}
|
|
|
|
|
|
|
|
|
/**
|
|
|
* List of what cargo labels are refittable for the given the vehicle-type.
|
|
|
* Only currently active labels are applied. */
|
|
|
* Only currently active labels are applied.
|
|
|
*/
|
|
|
static const CargoLabel _default_refitmasks_rail[] = {
|
|
|
'PASS', 'COAL', 'MAIL', 'LVST', 'GOOD', 'GRAI', 'WHEA', 'MAIZ', 'WOOD',
|
|
|
'IORE', 'STEL', 'VALU', 'GOLD', 'DIAM', 'PAPR', 'FOOD', 'FRUT', 'CORE',
|
|
|
'WATR', 'SUGR', 'TOYS', 'BATT', 'SWET', 'TOFF', 'COLA', 'CTCD', 'BUBL',
|
|
|
'PLST', 'FZDR',
|
|
|
0 };
|
|
@@ -6930,13 +6932,14 @@ static void FinaliseCargoArray()
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* Add all new houses to the house array. House properties can be set at any
|
|
|
* time in the GRF file, so we can only add a house spec to the house array
|
|
|
* after the file has finished loading. We also need to check the dates, due to
|
|
|
* the TTDPatch behaviour described below that we need to emulate. */
|
|
|
* the TTDPatch behaviour described below that we need to emulate.
|
|
|
*/
|
|
|
static void FinaliseHouseArray()
|
|
|
{
|
|
|
/* If there are no houses with start dates before 1930, then all houses
|
|
|
* with start dates of 1930 have them reset to 0. This is in order to be
|
|
|
* compatible with TTDPatch, where if no houses have start dates before
|
|
|
* 1930 and the date is before 1930, the game pretends that this is 1930.
|
|
@@ -6995,13 +6998,14 @@ static void FinaliseHouseArray()
|
|
|
}
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* Add all new industries to the industry array. Industry properties can be set at any
|
|
|
* time in the GRF file, so we can only add a industry spec to the industry array
|
|
|
* after the file has finished loading. */
|
|
|
* after the file has finished loading.
|
|
|
*/
|
|
|
static void FinaliseIndustriesArray()
|
|
|
{
|
|
|
const GRFFile * const *end = _grf_files.End();
|
|
|
for (GRFFile **file = _grf_files.Begin(); file != end; file++) {
|
|
|
IndustrySpec **&industryspec = (*file)->industryspec;
|
|
|
IndustryTileSpec **&indtspec = (*file)->indtspec;
|