ref: c6af61de5e50608fc66f2041bc6e487b55cf7b3c
parent: 52c2a5ceee262e18b7e4ff7f3c117ab765c1efc8
author: Clownacy <Clownacy@users.noreply.github.com>
date: Tue Sep 15 16:49:24 EDT 2020
Chars aren't guaranteed to overflow at 256
--- a/src/Font.cpp
+++ b/src/Font.cpp
@@ -1138,7 +1138,7 @@
{
if (font != NULL && surface != NULL)
{
- RenderBackend_PrepareToDrawGlyphs(font->atlas, surface, (unsigned char)colour, (unsigned char)(colour >> 8), (unsigned char)(colour >> 16));
+ RenderBackend_PrepareToDrawGlyphs(font->atlas, surface, colour & 0xFF, (colour >> 8) & 0xFF, (colour >> 16) & 0xFF);
size_t pen_x = 0;