]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - gl_draw.c
patch from VorteX which makes r_editlights mode use different icons for
[xonotic/darkplaces.git] / gl_draw.c
index ad8e8ef74a32152703b9b33cdf42bd5ad71ccdc2..527db40d237a4f7e03ff6d917e13fb848045fa17 100644 (file)
--- a/gl_draw.c
+++ b/gl_draw.c
@@ -420,6 +420,18 @@ cachepic_t *Draw_CachePic (const char *path, qboolean persistent)
                        pic->tex = draw_generatecrosshair(5);
                if (pic->tex == NULL && !strcmp(path, "gfx/colorcontrol/ditherpattern"))
                        pic->tex = draw_generateditherpattern();
+               // default textures for light sprites
+               // todo: improve them
+               if (pic->tex == NULL && !strcmp(path, "gfx/editlights/cursor"))
+                       pic->tex = draw_generatecrosshair(0);
+               if (pic->tex == NULL && !strcmp(path, "gfx/editlights/light"))
+                       pic->tex = draw_generatecrosshair(0);
+               if (pic->tex == NULL && !strcmp(path, "gfx/editlights/noshadow"))
+                       pic->tex = draw_generatecrosshair(0);
+               if (pic->tex == NULL && !strcmp(path, "gfx/editlights/cubemap"))
+                       pic->tex = draw_generatecrosshair(0);
+               if (pic->tex == NULL && !strcmp(path, "gfx/editlights/selection"))
+                       pic->tex = draw_generatecrosshair(0);
                if (pic->tex == NULL)
                {
                        // don't complain about missing gfx/crosshair images