From d5df24db15b342f06239e78f313f4fbf53fbc71b Mon Sep 17 00:00:00 2001 From: Sabian Roberts <31491602+sabianroberts@users.noreply.github.com> Date: Sun, 27 Oct 2024 23:44:13 +0000 Subject: [PATCH] Fix battery drawing above health --- cl_dll/battery.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/cl_dll/battery.cpp b/cl_dll/battery.cpp index 619d725..6429db7 100644 --- a/cl_dll/battery.cpp +++ b/cl_dll/battery.cpp @@ -162,6 +162,7 @@ int CHudBattery::Draw(float flTime) int iOffset = (m_prc1->bottom - m_prc1->top)/6; y = ScreenHeight - gHUD.m_iFontHeight - gHUD.m_iFontHeight / 2; + y += (int)(gHUD.m_iFontHeight * 0.2f); int width = (m_prc1->right - m_prc1->left); // this used to just be ScreenWidth/5 but that caused real issues at higher resolutions. Instead, base it on the width of this sprite. x = 3 * width;