From 8e051e0a4e7647c89b4413920d3cf3dd6b74e821 Mon Sep 17 00:00:00 2001 From: havoc Date: Wed, 18 Feb 2004 14:46:06 +0000 Subject: [PATCH] improved error message for missing cubemap images, no longer complains during cubemap loading, as long as one or more sides are found git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@3907 d7cf8633-e32d-0410-b094-e92efae38249 --- r_shadow.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/r_shadow.c b/r_shadow.c index 0e8b6ccc..e57f8515 100644 --- a/r_shadow.c +++ b/r_shadow.c @@ -1906,7 +1906,7 @@ rtexture_t *R_Shadow_LoadCubemap(const char *basename) for (i = 0;i < 6;i++) { snprintf(name, sizeof(name), "%s%s", basename, suffix[j][i].suffix); - if ((image_rgba = loadimagepixels(name, true, cubemapsize, cubemapsize))) + if ((image_rgba = loadimagepixels(name, false, cubemapsize, cubemapsize))) { if (image_width == image_height) { @@ -1933,7 +1933,13 @@ rtexture_t *R_Shadow_LoadCubemap(const char *basename) Mem_Free(cubemappixels); } else - Con_Printf("Failed to load Cubemap \"%s\"\n", basename); + { + Con_Printf("Failed to load Cubemap \"%s\", tried ", basename); + for (j = 0;j < 3;j++) + for (i = 0;i < 6;i++) + Con_Printf("%s\"%s%s.tga\"", j + i > 0 ? ", " : "", basename, suffix[j][i].suffix); + Con_Printf(" and was unable to find any of them.\n"); + } return cubemaptexture; } -- 2.39.2