From: DeaDDooMER Date: Mon, 13 Feb 2023 10:55:33 +0000 (+0300) Subject: gl: make hud fully usable on 640x400 X-Git-Url: http://deadsoftware.ru/gitweb?a=commitdiff_plain;h=21824a042f883761f39c4723ad30e4e71f289c93;p=d2df-sdl.git gl: make hud fully usable on 640x400 --- diff --git a/src/game/renders/opengl/r_render.pas b/src/game/renders/opengl/r_render.pas index 369fa88..202500d 100644 --- a/src/game/renders/opengl/r_render.pas +++ b/src/game/renders/opengl/r_render.pas @@ -286,12 +286,14 @@ implementation end; procedure r_Render_DrawHUDArea (x, y, w, h: Integer; p: TPlayer); - var s: AnsiString; + var s: AnsiString; oldy: Integer; begin r_Common_DrawTexture(hudbg, x, y, w, h, TBasePoint.BP_LEFTUP); if p <> nil then begin + oldy := y; + if h < 239 then y := y - 32; (* hack: hide nickname on 640x400 *) r_Render_DrawHUD(x + w - 196 + 2, y, p); if p.Spectator then begin @@ -301,6 +303,7 @@ implementation if p.NoRespawn then r_Common_DrawText(_lc[I_PLAYER_SPECT1S], x + 4, y + 290, 255, 255, 255, 255, stdfont, TBasePoint.BP_LEFTUP); end; + y := oldy; end; if gShowPing and g_Game_IsClient then