components/prboom/p_lights.c
//
// T_StrobeFlash()
//
// Strobe light flashing action routine, called once per tick
//
// Passed a strobe_t structure containing light levels and timing
// Returns nothing
//
T_StrobeFlash()
Strobe light flashing action routine, called once per tick

Passed a strobe_t structure containing light levels and timing
Returns nothing
T_StrobeFlash () Strobe light flashing action routine called once per tick Passed a strobe_t structure containing light levels and timing Returns nothing
void T_StrobeFlash (strobe_t*   flash)
{
  if (--flash->count)
    return;
  if (flash->sector->lightlevel == flash->minlight)
  {
    flash-> sector->lightlevel = flash->maxlight;
    flash->count = flash->brighttime;
  }
  else
  {
    flash-> sector->lightlevel = flash->minlight;
    flash->count =flash->darktime;
  }
}
void T_StrobeFlash ( strobe_t * flash ) { if ( -- flash -> count ) return ; if ( flash -> sector -> lightlevel == flash -> minlight ) { flash -> sector -> lightlevel = flash -> maxlight ; flash -> count = flash -> brighttime ; } else { flash -> sector -> lightlevel = flash -> minlight ; flash -> count = flash -> darktime ; } }
T_StrobeFlash()
Strobe light flashing action routine, called once per tick
T_StrobeFlash () Strobe light flashing action routine called once per tick