This (zero-sizes text warning) can now actually happen if someone sets 320x240 res...
authorRudolf Polzer <divverent@xonotic.org>
Sat, 12 Oct 2013 17:18:54 +0000 (19:18 +0200)
committerRudolf Polzer <divverent@xonotic.org>
Sat, 12 Oct 2013 17:19:33 +0000 (19:19 +0200)
qcsrc/menu/draw.qc

index 9c0d032..df93daa 100644 (file)
@@ -276,8 +276,10 @@ void draw_BorderPicture(vector theOrigin, string pic, vector theSize, vector the
 }
 void draw_Text(vector theOrigin, string theText, vector theSize, vector theColor, float theAlpha, float ICanHasKallerz)
 {
-       if(theSize_x <= 0 || theSize_y <= 0)
-               error("Drawing zero size text?\n");
+       if(theSize_x <= 0 || theSize_y <= 0) {
+               dprint("Drawing zero size text?\n");
+               return;
+       }
 
        //float wi;
        //wi = draw_TextWidth(theText, ICanHasKallerz, theSize);