From 4dc23ea2893ad60c683e12a34c4667a5e14f5ccf Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Tue, 17 Nov 2015 23:17:20 +0100 Subject: SWORD25: Fix text rendering --- engines/sword25/gfx/text.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/sword25/gfx') diff --git a/engines/sword25/gfx/text.cpp b/engines/sword25/gfx/text.cpp index 904435fcb0..54eb02f082 100644 --- a/engines/sword25/gfx/text.cpp +++ b/engines/sword25/gfx/text.cpp @@ -99,7 +99,7 @@ void Text::setText(const Common::String &text) { } void Text::setColor(uint32 modulationColor) { - uint32 newModulationColor = (modulationColor & 0xffffff00) | (_modulationColor & 0x000000ff); + uint32 newModulationColor = (modulationColor & 0x00ffffff) | (_modulationColor & 0xff000000); if (newModulationColor != _modulationColor) { _modulationColor = newModulationColor; forceRefresh(); @@ -108,7 +108,7 @@ void Text::setColor(uint32 modulationColor) { void Text::setAlpha(int alpha) { assert(alpha >= 0 && alpha < 256); - uint32 newModulationColor = (_modulationColor & 0xffffff00) | alpha; + uint32 newModulationColor = (_modulationColor & 0xffffff) | (alpha << 24); if (newModulationColor != _modulationColor) { _modulationColor = newModulationColor; forceRefresh(); -- cgit v1.2.3