mirror of
https://github.com/TerryCavanagh/VVVVVV.git
synced 2024-12-22 09:39:43 +01:00
Modulate text sprite RGB instead of using alpha
Using actual alpha is prone to bugs with doubling alpha, etc. if there are multiple sprites on top of each other.
This commit is contained in:
parent
2ed1aac67d
commit
a7b22919ae
1 changed files with 3 additions and 1 deletions
|
@ -1048,7 +1048,9 @@ void Graphics::drawgui(void)
|
||||||
TextboxSprite* sprite = &textboxes[i].sprites[index];
|
TextboxSprite* sprite = &textboxes[i].sprites[index];
|
||||||
int y = sprite->y + yp;
|
int y = sprite->y + yp;
|
||||||
SDL_Color color = getcol(sprite->col);
|
SDL_Color color = getcol(sprite->col);
|
||||||
color.a = opacity * 255;
|
color.r *= opacity;
|
||||||
|
color.g *= opacity;
|
||||||
|
color.b *= opacity;
|
||||||
|
|
||||||
if (flipmode)
|
if (flipmode)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue