From 551d7d4d89e070381b974d930b52aef0ca1084d4 Mon Sep 17 00:00:00 2001 From: Alug Date: Wed, 1 Jul 2026 18:07:31 +0200 Subject: [PATCH] add V_DrawRightAlignedSmallStringAtFixed idk but might be useful --- src/v_video.c | 14 +++++++++++++- src/v_video.h | 1 + 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/v_video.c b/src/v_video.c index 0f4540216..2ac659ba6 100644 --- a/src/v_video.c +++ b/src/v_video.c @@ -2718,6 +2718,7 @@ void V_DrawSmallStringAtFixed(fixed_t x, fixed_t y, INT32 option, const char *st INT32 charflags = 0; const UINT8 *colormap = NULL; INT32 spacewidth = 2, charwidth = 0; + INT32 lowercase = (option & V_ALLOWLOWERCASE); option &= ~V_FLIP; // which is also shared with V_ALLOWLOWERCASE... @@ -2738,6 +2739,7 @@ void V_DrawSmallStringAtFixed(fixed_t x, fixed_t y, INT32 option, const char *st scrwidth *= vid.dup; charflags = (option & V_CHARCOLORMASK); + colormap = V_GetStringColormap(charflags); switch (option & V_SPACINGMASK) { @@ -2762,7 +2764,11 @@ void V_DrawSmallStringAtFixed(fixed_t x, fixed_t y, INT32 option, const char *st { // manually set flags override color codes if (!(option & V_CHARCOLORMASK)) + { charflags = ((*ch & 0x7f) << V_CHARCOLORSHIFT) & V_CHARCOLORMASK; + colormap = V_GetStringColormap(charflags); + } + continue; } @@ -2806,7 +2812,6 @@ void V_DrawSmallStringAtFixed(fixed_t x, fixed_t y, INT32 option, const char *st continue; } - colormap = V_GetStringColormap(charflags); V_DrawFixedPatch(cx + (center<