Changeset - r51:4f1ba7eb95be
[Not reviewed]
master
0 1 0
dominik - 20 years ago 2004-08-14 10:32:56
dominik@openttd.org
(svn r52) grf messages are only displayed with debug level above 0. (use -d1 parameter)
1 file changed with 3 insertions and 1 deletions:
0 comments (0 inline, 0 general)
grfspecial.c
Show inline comments
 
@@ -41,6 +41,7 @@ static void CDECL grfmsg(enum grfmsg_sev
 
	static const char * const severitystr[4] = { "Notice", "Warning", "Error", "Fatal" };
 
	va_list va;
 

	
 
	if(_debug_misc_level==0) return;
 
	va_start(va, str);
 
	fprintf(stderr, "[%s][%s] ", _cur_grffile, severitystr[severity]);
 
	vfprintf(stderr, str, va);
 
@@ -928,7 +929,8 @@ static void GRFInfo(byte *buf, int len)
 
		uint8 version = buf[1];
 
		// this is de facto big endian - grf_load_dword() unsuitable
 
		uint32 grfid = buf[2] << 24 | buf[3] << 16 | buf[4] << 8 | buf[5];
 
		printf("[%s] Loaded GRFv%d set %08lx - %s:\n%s\n", _cur_grffile, version, grfid, buf+6, buf+6+strlen(buf+6)+1);
 
		if(_debug_misc_level!=0)
 
			printf("[%s] Loaded GRFv%d set %08lx - %s:\n%s\n", _cur_grffile, version, grfid, buf+6, buf+6+strlen(buf+6)+1);
 
	}
 
}
 

	
0 comments (0 inline, 0 general)