diff options
author | erorcun <erorcunerorcun@hotmail.com.tr> | 2020-11-29 17:19:50 +0100 |
---|---|---|
committer | erorcun <erorcunerorcun@hotmail.com.tr> | 2020-12-02 12:21:46 +0100 |
commit | bd8b907d131ac9e5b471a0a31928849b95f5d1f0 (patch) | |
tree | ab3102ea352daf603903342baf4aa696d6cacf56 /src/render/Font.cpp | |
parent | some nasty FIX_BUGS for SLIDE_OBJECT (diff) | |
download | re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.tar re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.tar.gz re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.tar.bz2 re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.tar.lz re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.tar.xz re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.tar.zst re3-bd8b907d131ac9e5b471a0a31928849b95f5d1f0.zip |
Diffstat (limited to 'src/render/Font.cpp')
-rw-r--r-- | src/render/Font.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/render/Font.cpp b/src/render/Font.cpp index 78a8599e..5a6ff94f 100644 --- a/src/render/Font.cpp +++ b/src/render/Font.cpp @@ -1437,3 +1437,21 @@ CFont::SetDropColor(CRGBA col) if (Details.alphaFade < 255.0f) Details.dropColor.a *= Details.alphaFade / 255.0f; } + +void +CFont::FilterOutTokensFromString(wchar *str) +{ + int newIdx = 0; + wchar copy[256], *c; + UnicodeStrcpy(copy, str); + + for (c = copy; *c != '\0'; c++) { + if (*c == '~') { + c++; + while (*c != '~') c++; + } else { + str[newIdx++] = *c; + } + } + str[newIdx] = '\0'; +} |