mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-14 08:30:50 +00:00
Fixed extra player translations not working in Heretic with predefined color sets
This commit is contained in:
parent
58f56bbea6
commit
ec3cd68c1f
1 changed files with 39 additions and 34 deletions
|
@ -474,21 +474,6 @@ static void R_CreatePlayerTranslation (float h, float s, float v, const FPlayerC
|
||||||
HSVtoRGB (&r, &g, &b, h, s, v);
|
HSVtoRGB (&r, &g, &b, h, s, v);
|
||||||
SetRemap(table, i, r, g, b);
|
SetRemap(table, i, r, g, b);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Build rain/lifegem translation
|
|
||||||
if (alttable)
|
|
||||||
{
|
|
||||||
bases = MIN (bases*1.3f, 1.f);
|
|
||||||
basev = MIN (basev*1.3f, 1.f);
|
|
||||||
for (i = 145; i <= 168; i++)
|
|
||||||
{
|
|
||||||
s = MIN (bases, 0.8965f - 0.0962f*(float)(i - 161));
|
|
||||||
v = MIN (1.f, (0.2102f + 0.0489f*(float)(i - 144)) * basev);
|
|
||||||
HSVtoRGB (&r, &g, &b, h, s, v);
|
|
||||||
SetRemap(alttable, i, r, g, b);
|
|
||||||
SetPillarRemap(pillartable, i, h, s, v);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else if (gameinfo.gametype == GAME_Hexen)
|
else if (gameinfo.gametype == GAME_Hexen)
|
||||||
{
|
{
|
||||||
|
@ -522,7 +507,24 @@ static void R_CreatePlayerTranslation (float h, float s, float v, const FPlayerC
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (gameinfo.gametype == GAME_Hexen && alttable != NULL)
|
|
||||||
|
if (alttable != NULL)
|
||||||
|
{
|
||||||
|
if (gameinfo.gametype == GAME_Heretic)
|
||||||
|
{
|
||||||
|
// Build rain/lifegem translation
|
||||||
|
bases = MIN(bases * 1.3f, 1.f);
|
||||||
|
basev = MIN(basev * 1.3f, 1.f);
|
||||||
|
for (i = 145; i <= 168; i++)
|
||||||
|
{
|
||||||
|
s = MIN(bases, 0.8965f - 0.0962f * (float)(i - 161));
|
||||||
|
v = MIN(1.f, (0.2102f + 0.0489f * (float)(i - 144)) * basev);
|
||||||
|
HSVtoRGB(&r, &g, &b, h, s, v);
|
||||||
|
SetRemap(alttable, i, r, g, b);
|
||||||
|
SetPillarRemap(pillartable, i, h, s, v);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (gameinfo.gametype == GAME_Hexen)
|
||||||
{
|
{
|
||||||
// Build Hexen's lifegem translation.
|
// Build Hexen's lifegem translation.
|
||||||
|
|
||||||
|
@ -548,6 +550,9 @@ static void R_CreatePlayerTranslation (float h, float s, float v, const FPlayerC
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
//----------------------------------------------------------------------------
|
//----------------------------------------------------------------------------
|
||||||
//
|
//
|
||||||
//
|
//
|
||||||
|
|
Loading…
Reference in a new issue