- a few more.

This commit is contained in:
Christoph Oelckers 2019-01-27 16:59:50 +01:00
commit 522cc855ad
7 changed files with 18 additions and 20 deletions

View file

@ -93,6 +93,7 @@ void V_AddBlend (float r, float g, float b, float a, float v_blend[4])
void V_AddPlayerBlend (player_t *CPlayer, float blend[4], float maxinvalpha, int maxpainblend)
{
int cnt;
auto Level = CPlayer->mo->Level;
// [RH] All powerups can affect the screen blending now
for (AActor *item = CPlayer->mo->Inventory; item != NULL; item = item->Inventory)
@ -175,18 +176,18 @@ void V_AddPlayerBlend (player_t *CPlayer, float blend[4], float maxinvalpha, int
{
if (CPlayer->hazardcount > 16*TICRATE || (CPlayer->hazardcount & 8))
{
float r = ((level.hazardflash & 0xff0000) >> 16) / 255.f;
float g = ((level.hazardflash & 0xff00) >> 8) / 255.f;
float b = ((level.hazardflash & 0xff)) / 255.f;
float r = ((Level->hazardflash & 0xff0000) >> 16) / 255.f;
float g = ((Level->hazardflash & 0xff00) >> 8) / 255.f;
float b = ((Level->hazardflash & 0xff)) / 255.f;
V_AddBlend (r, g, b, 0.125f, blend);
}
}
else
{
cnt= MIN(CPlayer->hazardcount/8, 64);
float r = ((level.hazardcolor & 0xff0000) >> 16) / 255.f;
float g = ((level.hazardcolor & 0xff00) >> 8) / 255.f;
float b = ((level.hazardcolor & 0xff)) / 255.f;
float r = ((Level->hazardcolor & 0xff0000) >> 16) / 255.f;
float g = ((Level->hazardcolor & 0xff00) >> 8) / 255.f;
float b = ((Level->hazardcolor & 0xff)) / 255.f;
V_AddBlend (r, g, b, cnt/93.2571428571f, blend);
}
}