\r
#define DEFAULT_DYNTEXTURE r_texture_grey128\r
\r
-static dyntexture_t * cl_finddyntexture( const char *name ) {\r
+static dyntexture_t * cl_finddyntexture( const char *name, qboolean warnonfailure ) {\r
unsigned i;\r
dyntexture_t *dyntexture = NULL;\r
\r
// sanity checks - make sure its actually a dynamic texture path\r
if( !name || !*name || strncmp( name, CLDYNTEXTUREPREFIX, sizeof( CLDYNTEXTUREPREFIX ) - 1 ) != 0 ) {\r
// TODO: print a warning or something\r
- if( developer.integer > 0 ) {\r
+ if (warnonfailure)\r
Con_Printf( "cl_finddyntexture: Bad dynamic texture name '%s'\n", name );\r
- }\r
return NULL;\r
}\r
\r
}\r
\r
rtexture_t * CL_GetDynTexture( const char *name ) {\r
- dyntexture_t *dyntexture = cl_finddyntexture( name );\r
+ dyntexture_t *dyntexture = cl_finddyntexture( name, false );\r
if( dyntexture ) {\r
return dyntexture->texture;\r
} else {\r
cachepic_t *cachepic;\r
skinframe_t *skinframe;\r
\r
- dyntexture = cl_finddyntexture( name );\r
+ dyntexture = cl_finddyntexture( name, true );\r
if( !dyntexture ) {\r
Con_Printf( "CL_LinkDynTexture: internal error in cl_finddyntexture!\n" );\r
return;\r
if( dyntexture->texture != texture ) {\r
dyntexture->texture = texture;\r
\r
- cachepic = Draw_CachePic( name, false );\r
+ cachepic = Draw_CachePic_Flags( name, CACHEPICFLAG_NOTPERSISTENT );\r
// TODO: assert cachepic and skinframe should be valid pointers...\r
// TODO: assert cachepic->tex = dyntexture->texture\r
cachepic->tex = texture;\r