hush some texture loading warnings in dedicated servers (thanks to Biomass for report...
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 5 May 2005 14:24:24 +0000 (14:24 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 5 May 2005 14:24:24 +0000 (14:24 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5228 d7cf8633-e32d-0410-b094-e92efae38249

model_alias.c
model_brush.c

index c0c7856..2fb1a35 100644 (file)
@@ -384,12 +384,14 @@ static void Mod_BuildAliasSkinsFromSkinFiles(texture_t *skin, skinfile_t *skinfi
                                                Mod_BuildAliasSkinFromSkinFrame(skin, &tempskinframe);
                                        else
                                        {
-                                               Con_Printf("mesh \"%s\": failed to load skin #%i \"%s\", falling back to mesh's internal shader name \"%s\"\n", meshname, i, skinfileitem->replacement, shadername);
+                                               if (cls.state != ca_dedicated)
+                                                       Con_Printf("mesh \"%s\": failed to load skin #%i \"%s\", falling back to mesh's internal shader name \"%s\"\n", meshname, i, skinfileitem->replacement, shadername);
                                                if (Mod_LoadSkinFrame(&tempskinframe, shadername, (r_mipskins.integer ? TEXF_MIPMAP : 0) | TEXF_ALPHA | TEXF_CLAMP | TEXF_PRECACHE | TEXF_PICMIP, true, false, true))
                                                        Mod_BuildAliasSkinFromSkinFrame(skin, &tempskinframe);
                                                else
                                                {
-                                                       Con_Printf("failed to load skin \"%s\"\n", shadername);
+                                                       if (cls.state != ca_dedicated)
+                                                               Con_Printf("failed to load skin \"%s\"\n", shadername);
                                                        Mod_BuildAliasSkinFromSkinFrame(skin, NULL);
                                                }
                                        }
@@ -404,7 +406,8 @@ static void Mod_BuildAliasSkinsFromSkinFiles(texture_t *skin, skinfile_t *skinfi
                        Mod_BuildAliasSkinFromSkinFrame(skin, &tempskinframe);
                else
                {
-                       Con_Printf("failed to load mesh \"%s\" shader \"%s\"\n", meshname, shadername);
+                       if (cls.state != ca_dedicated)
+                               Con_Printf("failed to load mesh \"%s\" shader \"%s\"\n", meshname, shadername);
                        Mod_BuildAliasSkinFromSkinFrame(skin, NULL);
                }
        }
index 89bae0d..f0ef929 100644 (file)
@@ -3920,7 +3920,8 @@ parseerror:
                }
                if (!Mod_LoadSkinFrame(&out->skin, out->name, (((out->textureflags & Q3TEXTUREFLAG_NOMIPMAPS) || (out->surfaceparms & Q3SURFACEPARM_NOMIPMAPS)) ? 0 : TEXF_MIPMAP) | TEXF_ALPHA | TEXF_PRECACHE | (out->textureflags & Q3TEXTUREFLAG_NOPICMIP ? 0 : TEXF_PICMIP), false, false, true))
                        if (!Mod_LoadSkinFrame(&out->skin, out->firstpasstexturename, (((out->textureflags & Q3TEXTUREFLAG_NOMIPMAPS) || (out->surfaceparms & Q3SURFACEPARM_NOMIPMAPS)) ? 0 : TEXF_MIPMAP) | TEXF_ALPHA | TEXF_PRECACHE | (out->textureflags & Q3TEXTUREFLAG_NOPICMIP ? 0 : TEXF_PICMIP), false, false, true))
-                               Con_Printf("%s: texture loading for shader \"%s\" failed (first layer \"%s\" not found either)\n", loadmodel->name, out->name, out->firstpasstexturename);
+                               if (cls.state != ca_dedicated)
+                                       Con_Printf("%s: texture loading for shader \"%s\" failed (first layer \"%s\" not found either)\n", loadmodel->name, out->name, out->firstpasstexturename);
                // no animation
                out->currentframe = out;
        }