mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-10 23:01:59 +00:00
- use a sector's special sprite color to colorize decals.
This commit is contained in:
parent
9a166d894b
commit
d1e613e514
1 changed files with 8 additions and 1 deletions
|
@ -47,11 +47,18 @@
|
|||
|
||||
void HWDecal::DrawDecal(HWDrawInfo *di, FRenderState &state)
|
||||
{
|
||||
PalEntry DecalColor;
|
||||
// alpha color only has an effect when using an alpha texture.
|
||||
if (decal->RenderStyle.Flags & (STYLEF_RedIsAlpha | STYLEF_ColorIsFixed))
|
||||
{
|
||||
state.SetObjectColor(decal->AlphaColor | 0xff000000);
|
||||
DecalColor = decal->AlphaColor | 0xff000000;
|
||||
}
|
||||
else
|
||||
DecalColor = 0xffffffff;
|
||||
|
||||
if (!di->isFullbrightScene()) DecalColor = DecalColor.Modulate(frontsector->SpecialColors[sector_t::sprites]);
|
||||
|
||||
state.SetObjectColor(DecalColor);
|
||||
|
||||
state.SetLightIndex(dynlightindex);
|
||||
state.SetTextureMode(decal->RenderStyle);
|
||||
|
|
Loading…
Reference in a new issue