From df16aa1400fa9680a15664140483fb3084604a20 Mon Sep 17 00:00:00 2001 From: TimeServ Date: Wed, 22 Feb 2006 01:24:22 +0000 Subject: [PATCH] fix Sys_Error with jpeg screenshots, standardize console warning/error/notice colors git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@1984 fc73d0e0-1445-4013-8a0c-d673dee63da5 --- engine/client/cl_main.c | 6 +++--- engine/client/cl_parse.c | 4 ++-- engine/client/clq2_cin.c | 2 +- engine/client/image.c | 3 ++- engine/client/pr_csqc.c | 2 +- engine/client/renderer.c | 10 +++------- engine/client/valid.c | 12 ++++++------ engine/common/cmd.c | 2 +- engine/common/console.h | 4 ++++ engine/common/fs.c | 2 +- engine/common/gl_q2bsp.c | 2 +- engine/common/plugin.c | 2 +- engine/common/zone.c | 8 ++++---- engine/gl/gl_shader.c | 24 ++++++++++++------------ engine/gl/gl_vidnt.c | 8 ++++---- engine/gl/glmod_doom.c | 18 +++++++++--------- engine/http/ftpclient.c | 4 ++-- engine/http/iwebiface.c | 2 +- engine/server/svq3_game.c | 2 +- 19 files changed, 59 insertions(+), 58 deletions(-) diff --git a/engine/client/cl_main.c b/engine/client/cl_main.c index dc54e0c1..a7351c8e 100644 --- a/engine/client/cl_main.c +++ b/engine/client/cl_main.c @@ -1622,7 +1622,7 @@ void CL_Packet_f (void) adr.address.ip[2] = cls.netchan.remote_address.address.ip[2]; adr.address.ip[3] = cls.netchan.remote_address.address.ip[3]; adr.port = cls.netchan.remote_address.port; - Con_Printf ("^b^1Server is broken. Trying to send to server instead.\n"); + Con_Printf (S_WARNING "Server is broken. Trying to send to server instead.\n"); } @@ -2746,7 +2746,7 @@ void VARGS Host_EndGame (char *message, ...) va_end (argptr); Con_TPrintf (TL_NL); Con_TPrintf (TL_LINEBREAK_EQUALS); - Con_TPrintf (TLC_CLIENTCON_ERROR_ENDGAME,string); + Con_TPrintf (TLC_CLIENTCON_ERROR_ENDGAME, S_ERROR, string); Con_TPrintf (TL_LINEBREAK_EQUALS); Con_TPrintf (TL_NL); @@ -2781,7 +2781,7 @@ void VARGS Host_Error (char *error, ...) va_start (argptr,error); _vsnprintf (string,sizeof(string)-1, error,argptr); va_end (argptr); - Con_TPrintf (TLC_HOSTFATALERROR,string); + Con_TPrintf (TLC_HOSTFATALERROR, string); CL_Disconnect (); cls.demonum = -1; diff --git a/engine/client/cl_parse.c b/engine/client/cl_parse.c index b875dfab..76789407 100644 --- a/engine/client/cl_parse.c +++ b/engine/client/cl_parse.c @@ -1141,7 +1141,7 @@ void CL_ParseDownload (void) if (!*cls.downloadname) //huh... that's not right... { - Con_Printf("^1Warning^7: Server sending unknown file.\n"); + Con_Printf(S_WARNING "Warning: Server sending unknown file.\n"); strcpy(cls.downloadname, "unknown.txt"); strcpy(cls.downloadtempname, "unknown.tmp"); } @@ -4560,7 +4560,7 @@ void CLNQ_ParseServerMessage (void) if (cl.playernum[0] >= MAX_CLIENTS) { cl.playernum[0] = 32; //pretend it's an mvd (we have that spare slot) - Con_Printf("^1WARNING: Server put us in slot %i. We are not on the scoreboard.\n"); + Con_Printf(S_WARNING "WARNING: Server put us in slot %i. We are not on the scoreboard.\n"); } } else diff --git a/engine/client/clq2_cin.c b/engine/client/clq2_cin.c index 23027e50..6a283326 100644 --- a/engine/client/clq2_cin.c +++ b/engine/client/clq2_cin.c @@ -501,7 +501,7 @@ qboolean CIN_PlayCinematic (char *arg) CIN_FinishCinematic (); cin.cinematictime = 0; // done - Con_Printf("^1Cinematic %s not found.\n", name); + Con_Printf(S_WARNING "Cinematic %s not found.\n", name); return true; } diff --git a/engine/client/image.c b/engine/client/image.c index 234a5e3d..be4b1075 100644 --- a/engine/client/image.c +++ b/engine/client/image.c @@ -1057,7 +1057,8 @@ void screenshotJPEG(char *filename, qbyte *screendata, int screenwidth, int scre { FS_CreatePath (filename, FS_GAME); if (!(outfile = FS_OpenVFS(filename, "wb", FS_GAMEONLY))) - Sys_Error ("Error opening %s", filename); + Con_Printf("Error opening %s\n", filename); + return; } cinfo.err = jpeg_std_error(&jerr.pub); diff --git a/engine/client/pr_csqc.c b/engine/client/pr_csqc.c index 354d12c5..f153f0d1 100644 --- a/engine/client/pr_csqc.c +++ b/engine/client/pr_csqc.c @@ -1039,7 +1039,7 @@ static void PF_R_SetViewFlag(progfuncs_t *prinst, struct globalvars_s *pr_global break; case VF_CARTESIAN_ANGLES: - Con_Printf("^1WARNING: CARTESIAN ANGLES ARE NOT YET SUPPORTED!\n"); + Con_Printf(S_WARNING "WARNING: CARTESIAN ANGLES ARE NOT YET SUPPORTED!\n"); break; case VF_VIEWPORT: diff --git a/engine/client/renderer.c b/engine/client/renderer.c index 9841e8eb..63874c78 100644 --- a/engine/client/renderer.c +++ b/engine/client/renderer.c @@ -1889,22 +1889,18 @@ TRACE(("dbg: R_RestartRenderer_f\n")); if (R_ApplyRenderer(&oldr)) { TRACE(("dbg: R_RestartRenderer_f old restored\n")); - Con_Printf("^1Video mode switch failed. Old mode restored.\n"); //go back to the old mode, the new one failed. + Con_Printf(S_ERROR "Video mode switch failed. Old mode restored.\n"); //go back to the old mode, the new one failed. } else { - Con_Printf("^1Trying default refresh rate\n"); + Con_Printf(S_NOTICE "Trying default refresh rate\n"); newr.rate = 0; if (!R_ApplyRenderer(&oldr)) { if (R_ApplyRenderer(&newr)) { TRACE(("dbg: R_RestartRenderer_f going to dedicated\n")); - - - Con_Printf("\n================================\n"); - Con_Printf("^1Video mode switch failed. Old mode wasn't supported either. Console forced.\nChange vid_width, vid_height, vid_bpp, vid_displayfrequency to a compatable mode, and then use the setrenderer command.\n"); - Con_Printf("================================\n\n"); + Con_Printf(S_ERROR "Video mode switch failed. Old mode wasn't supported either. Console forced.\nChange vid_width, vid_height, vid_bpp, vid_displayfrequency to a compatable mode, and then use the setrenderer command.\n"); } else Sys_Error("Couldn't fall back to previous renderer\n"); diff --git a/engine/client/valid.c b/engine/client/valid.c index 2e1ee475..58bc4e8b 100644 --- a/engine/client/valid.c +++ b/engine/client/valid.c @@ -364,9 +364,9 @@ void Validation_CheckIfResponse(char *text) resp = Security_Verify_Response(f_query_client, crc); if (resp && resp->size && *resp->buf) - Con_Printf("Authentication Successful.\n"); + Con_Printf(S_NOTICE "Authentication Successful.\n"); else// if (!resp) - Con_Printf("^1^bAUTHENTICATION FAILED.\n"); + Con_Printf(S_ERROR "AUTHENTICATION FAILED.\n"); /* typedef signed_buffer_t *(*Security_Verify_Response_t) (int, unsigned char *); // write request @@ -382,10 +382,10 @@ void Validation_CheckIfResponse(char *text) if (auth_answer == SECURE_ANSWER_YES && auth_crc == user_crc) { - Con_Printf("Authentication Successful.\n"); + Con_Printf(S_NOTICE "Authentication Successful.\n"); } else - Con_Printf("^1^bAUTHENTICATION FAILED.\n"); + Con_Printf(S_ERROR "AUTHENTICATION FAILED.\n"); */ } } @@ -1006,10 +1006,10 @@ void Validation_CheckIfResponse(char *text) if (auth_answer == SECURE_ANSWER_YES && auth_crc == user_crc) { - Con_Printf("Authentication Successful.\n"); + Con_Printf(S_NOTICE "Authentication Successful.\n"); } else - Con_Printf("^1^bAUTHENTICATION FAILED.\n"); + Con_Printf(S_ERROR "AUTHENTICATION FAILED.\n"); } } diff --git a/engine/common/cmd.c b/engine/common/cmd.c index 9bfce817..fa0a8a75 100644 --- a/engine/common/cmd.c +++ b/engine/common/cmd.c @@ -700,7 +700,7 @@ void Cmd_Alias_f (void) s = Cbuf_GetNext(Cmd_ExecLevel); if (!*s) { - Con_Printf("^1WARNING: ^7Multiline alias was not terminated\n"); + Con_Printf(S_WARNING "WARNING: Multiline alias was not terminated\n"); break; } while (*s <= ' ' && *s) diff --git a/engine/common/console.h b/engine/common/console.h index 397df189..c0cea3a5 100644 --- a/engine/common/console.h +++ b/engine/common/console.h @@ -79,6 +79,10 @@ extern conchar_t q3codemasks[MAXQ3COLOURS]; #define S_COLOR_MAGENTA "^6" #define S_COLOR_WHITE "^7" +#define S_WARNING "^&E0" +#define S_ERROR "^&C0" +#define S_NOTICE "^&-1" + #define CON_TEXTSIZE 16384 #define isextendedcode(x) ((x >= '0' && x <= '9') || (x >= 'A' && x <= 'F') || x == '-') diff --git a/engine/common/fs.c b/engine/common/fs.c index fc2fdcac..52713542 100644 --- a/engine/common/fs.c +++ b/engine/common/fs.c @@ -1570,7 +1570,7 @@ int COM_FOpenLocationFILE(flocation_t *loc, FILE **file) int COM_FOpenFile(char *filename, FILE **file) { flocation_t loc; - Con_Printf("^1COM_FOpenFile is obsolete\n"); + Con_Printf(S_ERROR "COM_FOpenFile is obsolete\n"); FS_FLocateFile(filename, FSLFRT_LENGTH, &loc); com_filesize = -1; diff --git a/engine/common/gl_q2bsp.c b/engine/common/gl_q2bsp.c index b66c3788..4554a9b7 100644 --- a/engine/common/gl_q2bsp.c +++ b/engine/common/gl_q2bsp.c @@ -1247,7 +1247,7 @@ void CMod_LoadTexInfo (lump_t *l) //yes I know these load from the same place { out->texture = Hunk_Alloc(sizeof(texture_t) + 16*16+8*8+4*4+2*2); - Con_Printf ("^2Couldn't load %s\n", name); + Con_Printf (S_WARNING "Couldn't load %s\n", name); memcpy(out->texture, r_notexture_mip, sizeof(texture_t) + 16*16+8*8+4*4+2*2); // out->texture = r_notexture_mip; // texture not found // out->flags = 0; diff --git a/engine/common/plugin.c b/engine/common/plugin.c index 2098054f..27b3150b 100644 --- a/engine/common/plugin.c +++ b/engine/common/plugin.c @@ -988,7 +988,7 @@ int VARGS Plug_Net_SetTLSClient(void *offset, unsigned int mask, const long *arg if (ret < 0) { - Con_Printf ("^1*** TLS handshake failed\n"); + Con_Printf (S_ERROR "*** TLS handshake failed\n"); gnutls_perror (ret); stream->type = STREAM_SOCKET; //go back to regular socket diff --git a/engine/common/zone.c b/engine/common/zone.c index a5b8e786..94cbdc58 100644 --- a/engine/common/zone.c +++ b/engine/common/zone.c @@ -521,7 +521,7 @@ void Zone_Print_f(void) { if (sent[i] != sentinalkey) { - Con_Printf("^1%i %i-%s\n", zone->size, i, (char *)(zone+1) + zone->size+ZONEDEBUG*2); + Con_Printf(S_ERROR "%i %i-%s\n", zone->size, i, (char *)(zone+1) + zone->size+ZONEDEBUG*2); break; } } @@ -530,7 +530,7 @@ void Zone_Print_f(void) { if (sent[i] != sentinalkey) { - Con_Printf("^1%i %i-%s\n", zone->size, i, (char *)(zone+1) + zone->size+ZONEDEBUG*2); + Con_Printf(S_ERROR "%i %i-%s\n", zone->size, i, (char *)(zone+1) + zone->size+ZONEDEBUG*2); break; } } @@ -549,8 +549,8 @@ void Zone_Print_f(void) overhead += sizeof(zone_t)+ZONEDEBUG*2; #endif } - Con_Printf("Zone:%i bytes in %i blocks\n", allocated, blocks); - Con_Printf("Overhead %i bytes\n", overhead); + Con_Printf(S_NOTICE "Zone:%i bytes in %i blocks\n", allocated, blocks); + Con_Printf(S_NOTICE "Overhead %i bytes\n", overhead); } #else diff --git a/engine/gl/gl_shader.c b/engine/gl/gl_shader.c index 1f6bee99..217795bc 100644 --- a/engine/gl/gl_shader.c +++ b/engine/gl/gl_shader.c @@ -584,7 +584,7 @@ static void Shaderpass_Map ( shader_t *shader, shaderpass_t *pass, char **ptr ) if ( !pass->anim_frames[0] ) { pass->anim_frames[0] = 0;//FIZME: r_notexture; - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", shader->name, token ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", shader->name, token ); } } } @@ -613,7 +613,7 @@ static void Shaderpass_AnimMap ( shader_t *shader, shaderpass_t *pass, char **pt if ( !image ) { pass->anim_frames[pass->anim_numframes++] = 0;//fizme: r_notexture; - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has an animmap with no image: %s.\n", shader->name, token ); + Con_DPrintf (S_WARNING "Shader %s has an animmap with no image: %s.\n", shader->name, token ); } else { pass->anim_frames[pass->anim_numframes++] = image; } @@ -637,7 +637,7 @@ static void Shaderpass_ClampMap ( shader_t *shader, shaderpass_t *pass, char **p if ( !pass->anim_frames[0] ) { pass->anim_frames[0] = 0;//fizme:r_notexture; - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", shader->name, token ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", shader->name, token ); } } @@ -1768,7 +1768,7 @@ void Shader_DefaultBSP(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if ( !pass->anim_frames[0] ) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } @@ -1797,7 +1797,7 @@ void Shader_DefaultBSPVertex(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if ( !pass->anim_frames[0] ) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } @@ -1828,7 +1828,7 @@ void Shader_DefaultBSPFlare(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if ( !pass->anim_frames[0] ) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } @@ -1865,7 +1865,7 @@ void Shader_DefaultSkin(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if (!pass->anim_frames[0]) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } } @@ -1887,7 +1887,7 @@ void Shader_DefaultSkin(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if (!pass->anim_frames[0]) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } } @@ -1909,7 +1909,7 @@ void Shader_DefaultSkin(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if (!pass->anim_frames[0]) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } } @@ -1931,7 +1931,7 @@ void Shader_DefaultSkin(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if (!pass->anim_frames[0]) { - Con_DPrintf (S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname); pass->anim_frames[0] = 0;//fizme:r_notexture; } } @@ -1962,7 +1962,7 @@ void Shader_DefaultSkinShell(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if ( !pass->anim_frames[0] ) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } @@ -2002,7 +2002,7 @@ void Shader_Default2D(char *shortname, shader_t *s) pass->flush = R_RenderMeshGeneric; if ( !pass->anim_frames[0] ) { - Con_DPrintf ( S_COLOR_YELLOW "Shader %s has a stage with no image: %s.\n", s->name, shortname ); + Con_DPrintf (S_WARNING "Shader %s has a stage with no image: %s.\n", s->name, shortname ); pass->anim_frames[0] = 0;//fizme:r_notexture; } diff --git a/engine/gl/gl_vidnt.c b/engine/gl/gl_vidnt.c index 58243cc8..1ce960f6 100644 --- a/engine/gl/gl_vidnt.c +++ b/engine/gl/gl_vidnt.c @@ -749,7 +749,7 @@ qboolean VID_AttachGL (rendererstate_t *info) maindc = GetDC(mainwindow); - Con_Printf(S_COLOR_GREEN"OpenGL to Direct3D wrapper enabled\n"); //green to make it show. + Con_Printf(S_NOTICE "OpenGL to Direct3D wrapper enabled\n"); //green to make it show. break; } #endif @@ -791,13 +791,13 @@ qboolean VID_AttachGL (rendererstate_t *info) baseRC = qwglCreateContext( maindc ); if (!baseRC) { - Con_SafePrintf(S_COLOR_RED"Could not initialize GL (wglCreateContext failed).\n\nMake sure you in are 65535 color mode, and try running -window.\n"); //green to make it show. + Con_SafePrintf(S_ERROR "Could not initialize GL (wglCreateContext failed).\n\nMake sure you in are 65535 color mode, and try running -window.\n"); //green to make it show. return false; } TRACE(("dbg: VID_AttachGL: qwglMakeCurrent\n")); if (!qwglMakeCurrent( maindc, baseRC )) { - Con_SafePrintf(S_COLOR_RED"wglMakeCurrent failed\n"); //green to make it show. + Con_SafePrintf(S_ERROR "wglMakeCurrent failed\n"); //green to make it show. return false; } @@ -1459,7 +1459,7 @@ qboolean GLVID_Init (rendererstate_t *info, unsigned char *palette) if (!RegisterClass (&wc) ) { - Con_Printf("^1Couldn't register window class\n"); + Con_Printf(S_ERROR "Couldn't register window class\n"); return false; } diff --git a/engine/gl/glmod_doom.c b/engine/gl/glmod_doom.c index add72c64..d1cf19a6 100644 --- a/engine/gl/glmod_doom.c +++ b/engine/gl/glmod_doom.c @@ -584,7 +584,7 @@ static void Triangulate_AddLine(int v1, int v2) //order makes a difference { //close up if (polyregions[endof].numverts+1 >= MAX_POLYVERTS) { - Con_Printf("^1WARNING: Map region is too large.\n"); + Con_Printf(S_WARNING "WARNING: Map region is too large.\n"); return; } polyregions[endof].vertex[polyregions[endof].numverts] = v2; @@ -594,7 +594,7 @@ static void Triangulate_AddLine(int v1, int v2) //order makes a difference { if (polyregions[endof].numverts+polyregions[beginingof].numverts >= MAX_POLYVERTS) { - Con_Printf("^1WARNING: Map region is too large.\n"); + Con_Printf(S_WARNING "WARNING: Map region is too large.\n"); return; } memcpy(polyregions[endof].vertex + polyregions[endof].numverts, @@ -608,7 +608,7 @@ static void Triangulate_AddLine(int v1, int v2) //order makes a difference { //insert into if (polyregions[beginingof].numverts+1 >= MAX_POLYVERTS) { - Con_Printf("^1WARNING: Map region is too large.\n"); + Con_Printf(S_WARNING "WARNING: Map region is too large.\n"); return; } @@ -622,7 +622,7 @@ static void Triangulate_AddLine(int v1, int v2) //order makes a difference { //stick outselves on the end if (polyregions[endof].numverts+1 >= MAX_POLYVERTS) { - Con_Printf("^1WARNING: Map region is too large.\n"); + Con_Printf(S_WARNING "WARNING: Map region is too large.\n"); return; } polyregions[endof].vertex[polyregions[endof].numverts] = v2; @@ -635,7 +635,7 @@ static void Triangulate_AddLine(int v1, int v2) //order makes a difference freer = regions++; if (regions > MAX_REGIONS) { - Con_Printf("^1WARNING: Too many regions. Sector is too chaotic/complicated.\n"); + Con_Printf(S_WARNING "WARNING: Too many regions. Sector is too chaotic/complicated.\n"); freer = 0; regions = 1; } @@ -704,7 +704,7 @@ static unsigned short *Triangulate_Finish(int *numtris, unsigned short *old, int { //build a triangle fan. if (numindexes+3 > MAX_POLYVERTS) { - Con_Printf("^1WARNING: Sector is too big for triangulation\n"); + Con_Printf(S_WARNING "WARNING: Sector is too big for triangulation\n"); break; } v3 = polyregions[r].vertex[v]; @@ -724,7 +724,7 @@ static unsigned short *Triangulate_Finish(int *numtris, unsigned short *old, int f++; if (f >= 1000) { //infinate loop - shouldn't happen. must have got the angle stuff wrong. - Con_Printf("^1WARNING: Failed to triangulate polygon\n"); + Con_Printf(S_WARNING "WARNING: Failed to triangulate polygon\n"); break; } continue; @@ -746,7 +746,7 @@ static unsigned short *Triangulate_Finish(int *numtris, unsigned short *old, int if (!numindexes) { - Con_Printf("^1Warning: Sector is empty\n"); + Con_Printf(S_WARNING "Warning: Sector is empty\n"); *numtris = 0; regions = 0; @@ -1255,7 +1255,7 @@ static void MoveWorld(void) return; //doesn't need adjusting, live with it. if (max[0]-min[0]>=8192 || max[1]-min[1]>=8192) - Con_Printf("^1Warning: Map is too large for the network protocol\n"); + Con_Printf(S_WARNING "Warning: Map is too large for the network protocol\n"); Con_Printf("Adjusting map\n"); diff --git a/engine/http/ftpclient.c b/engine/http/ftpclient.c index e3b9efe1..01640fbd 100644 --- a/engine/http/ftpclient.c +++ b/engine/http/ftpclient.c @@ -315,7 +315,7 @@ iwboolean FTP_ClientConnThink (FTPclientconn_t *con) //true to kill con line++; if (*con->server) - IWebDPrintf("^2FTP: %s\n", COM_TrimString(msg)); + IWebDPrintf("FTP: %s\n", COM_TrimString(msg)); if (*msg < '0' || *msg > '9') //make sure it starts with number continue; @@ -618,7 +618,7 @@ usepasv: continue; } if (ret != 221) - Con_Printf("^1FTP: %i %s\n", ret, msg); + Con_Printf(S_ERROR "FTP: %i %s\n", ret, msg); return true; } diff --git a/engine/http/iwebiface.c b/engine/http/iwebiface.c index c8becd50..05f2d051 100644 --- a/engine/http/iwebiface.c +++ b/engine/http/iwebiface.c @@ -351,7 +351,7 @@ void VARGS IWebWarnPrintf(char *fmt, ...) _vsnprintf (msg,sizeof(msg)-10, fmt,argptr); //catch any nasty bugs... (this is hopefully impossible) va_end (argptr); - Con_Printf("^1%s", msg); + Con_Printf(S_WARNING "%s", msg); } void IWebInit(void) diff --git a/engine/server/svq3_game.c b/engine/server/svq3_game.c index 17244ea9..eaa80e97 100644 --- a/engine/server/svq3_game.c +++ b/engine/server/svq3_game.c @@ -2848,7 +2848,7 @@ void SVQ3_ParseClientMessage(client_t *client) if (msg_readcount != net_message.cursize) { - Con_Printf( S_COLOR_YELLOW"WARNING: Junk at end of packet for client %s\n", client->name ); + Con_Printf(S_WARNING "WARNING: Junk at end of packet for client %s\n", client->name ); } }; void SVQ3_HandleClient(void)