]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Add a magic fallback number incase scoreboard_bg_scale is 0 or lower (fixes a crash)
authorMario <mario@smbclan.net>
Thu, 24 Mar 2016 17:17:22 +0000 (03:17 +1000)
committerMario <mario@smbclan.net>
Thu, 24 Mar 2016 17:17:22 +0000 (03:17 +1000)
qcsrc/client/scoreboard.qc

index 5fc8ff60a05993874e209fbfaa272dc96ce2cbf7..7dcf9876983761fb500f562da5fd62c026c1218f 100644 (file)
@@ -1308,7 +1308,7 @@ void HUD_DrawScoreboard()
        pos.y += sb_heading_fontsize.y + hud_fontsize.y * 0.25;
 
        // Draw the scoreboard
-       vector bg_size = draw_getimagesize("gfx/scoreboard/scoreboard_bg") * autocvar_scoreboard_bg_scale;
+       vector bg_size = draw_getimagesize("gfx/scoreboard/scoreboard_bg") * ((autocvar_scoreboard_bg_scale > 0) ? autocvar_scoreboard_bg_scale : 0.25);
 
        if(teamplay)
        {