From 39d0d4e23028e876f3770402bce5390ff5ec8bb9 Mon Sep 17 00:00:00 2001 From: Juhu <5894800-Juhu_@users.noreply.gitlab.com> Date: Wed, 24 Jun 2020 03:59:59 +0200 Subject: [PATCH] strafehud: limit angle indicator height to prevent it from going too far outside of the panel area --- qcsrc/client/hud/panel/strafehud.qc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qcsrc/client/hud/panel/strafehud.qc b/qcsrc/client/hud/panel/strafehud.qc index 22afca216..6f8abeb3c 100644 --- a/qcsrc/client/hud/panel/strafehud.qc +++ b/qcsrc/client/hud/panel/strafehud.qc @@ -430,7 +430,7 @@ void HUD_StrafeHUD() { currentangle_offset = bound(-hudangle/2, angle, hudangle/2)/hudangle * panel_size.x + panel_size.x/2; } - currentangle_size.y = max(panel_size.y * autocvar_hud_panel_strafehud_angle_height, 1); + currentangle_size.y = max(panel_size.y * min(autocvar_hud_panel_strafehud_angle_height, 2), 1); // best strafe acceleration angle bestangle_offset = bestangle/hudangle * panel_size.x + panel_size.x/2; switch_bestangle_offset = -bestangle/hudangle * panel_size.x + panel_size.x/2; -- 2.39.2