]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
font: fix missing text in r_speeds (etc)
authorbones_was_here <bones_was_here@xonotic.au>
Thu, 4 Jan 2024 17:39:56 +0000 (03:39 +1000)
committerbones_was_here <bones_was_here@xonotic.au>
Thu, 4 Jan 2024 17:39:56 +0000 (03:39 +1000)
This bug was introduced in 5468c81f47e6644d938e3cfedd21567b2936cd72

Signed-off-by: bones_was_here <bones_was_here@xonotic.au>
gl_draw.c

index bc4d34f17322240367eff444d64789ac50121b88..ea8798971b83c4408715ba20e12e2bb894bcd65d 100644 (file)
--- a/gl_draw.c
+++ b/gl_draw.c
@@ -339,9 +339,6 @@ void LoadFont(qbool override, const char *name, dp_font_t *fnt, float scale, flo
                strlcpy(fnt->texpath, name, sizeof(fnt->texpath));
                // load the cvars when the font is FIRST loader
                fnt->settings.scale = scale;
-               // fix bad scale
-               if (fnt->settings.scale <= 0)
-                       fnt->settings.scale = 1;
                fnt->settings.voffset = voffset;
                fnt->settings.antialias = r_font_antialias.integer;
                fnt->settings.hinting = r_font_hinting.integer;
@@ -352,6 +349,10 @@ void LoadFont(qbool override, const char *name, dp_font_t *fnt, float scale, flo
                fnt->settings.shadowz = r_font_postprocess_shadow_z.value;
        }
 
+       // fix bad scale
+       if (fnt->settings.scale <= 0)
+               fnt->settings.scale = 1;
+
        if(drawtexturepool == NULL)
                return; // before gl_draw_start, so will be loaded later