From 33975a083f54391560a12bdcd76b01cb9814d241 Mon Sep 17 00:00:00 2001 From: Mitchell Richters Date: Sun, 11 Dec 2022 16:16:16 +1100 Subject: [PATCH] - Draw crosshair at 1:1 scale when `crosshairscale` is 0, just like GZDoom. * Fixes #767. --- source/core/gamecontrol.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/core/gamecontrol.cpp b/source/core/gamecontrol.cpp index 21e2f1dde..93676b815 100644 --- a/source/core/gamecontrol.cpp +++ b/source/core/gamecontrol.cpp @@ -1401,7 +1401,7 @@ void DrawCrosshair(int deftile, int health, double xdelta, double ydelta, double auto tile = tileGetTexture(deftile); if (tile) { - double crosshair_scale = crosshairscale * scale; + double crosshair_scale = crosshairscale > 0.0f ? crosshairscale * scale : 1.; DrawTexture(twod, tile, 160 + xdelta, 100 + ydelta, DTA_Color, color, DTA_Rotate, angle.Degrees(), DTA_FullscreenScale, FSMode_Fit320x200, DTA_ScaleX, crosshair_scale, DTA_ScaleY, crosshair_scale, DTA_CenterOffsetRel, true, DTA_ViewportX, viewport3d.Left(), DTA_ViewportY, viewport3d.Top(), DTA_ViewportWidth, viewport3d.Width(), DTA_ViewportHeight, viewport3d.Height(), TAG_DONE);