Bug 4936 - Wrong color for non-ascii symbols in console

This commit is contained in:
Thilo Schulz 2011-03-17 12:53:47 +00:00
parent 76bbd95207
commit d3f8dffe39

View file

@ -380,9 +380,9 @@ If no console is visible, the text will appear at the top of the game window
================ ================
*/ */
void CL_ConsolePrint( char *txt ) { void CL_ConsolePrint( char *txt ) {
int y; int y, l;
int c, l; unsigned char c;
int color; unsigned short color;
qboolean skipnotify = qfalse; // NERVE - SMF qboolean skipnotify = qfalse; // NERVE - SMF
int prev; // NERVE - SMF int prev; // NERVE - SMF
@ -410,7 +410,7 @@ void CL_ConsolePrint( char *txt ) {
color = ColorIndex(COLOR_WHITE); color = ColorIndex(COLOR_WHITE);
while ( (c = *txt) != 0 ) { while ( (c = *((unsigned char *) txt)) != 0 ) {
if ( Q_IsColorString( txt ) ) { if ( Q_IsColorString( txt ) ) {
color = ColorIndex( *(txt+1) ); color = ColorIndex( *(txt+1) );
txt += 2; txt += 2;